summaryrefslogtreecommitdiff
path: root/Userland/Applications
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2021-10-24 16:01:24 +0200
committerAndreas Kling <kling@serenityos.org>2021-10-24 17:18:07 +0200
commit398c181c799f728739c1ee2184b8638554b3353c (patch)
treef3359393325fc8da02ecb78981a1f87c458246f2 /Userland/Applications
parent715e7fada8ed00a7680bb8f4ed65afd3026d3d59 (diff)
downloadserenity-398c181c799f728739c1ee2184b8638554b3353c.zip
LibJS: Rename PropertyName to PropertyKey
Let's use the same name as the spec. :^)
Diffstat (limited to 'Userland/Applications')
-rw-r--r--Userland/Applications/Spreadsheet/JSIntegration.cpp6
-rw-r--r--Userland/Applications/Spreadsheet/JSIntegration.h6
-rw-r--r--Userland/Applications/Spreadsheet/Spreadsheet.cpp2
3 files changed, 7 insertions, 7 deletions
diff --git a/Userland/Applications/Spreadsheet/JSIntegration.cpp b/Userland/Applications/Spreadsheet/JSIntegration.cpp
index 13982e5142..24ab6c4fc2 100644
--- a/Userland/Applications/Spreadsheet/JSIntegration.cpp
+++ b/Userland/Applications/Spreadsheet/JSIntegration.cpp
@@ -101,7 +101,7 @@ SheetGlobalObject::~SheetGlobalObject()
{
}
-JS::ThrowCompletionOr<bool> SheetGlobalObject::internal_has_property(JS::PropertyName const& name) const
+JS::ThrowCompletionOr<bool> SheetGlobalObject::internal_has_property(JS::PropertyKey const& name) const
{
if (name.is_string()) {
if (name.as_string() == "value")
@@ -112,7 +112,7 @@ JS::ThrowCompletionOr<bool> SheetGlobalObject::internal_has_property(JS::Propert
return Object::internal_has_property(name);
}
-JS::ThrowCompletionOr<JS::Value> SheetGlobalObject::internal_get(const JS::PropertyName& property_name, JS::Value receiver) const
+JS::ThrowCompletionOr<JS::Value> SheetGlobalObject::internal_get(const JS::PropertyKey& property_name, JS::Value receiver) const
{
if (property_name.is_string()) {
if (property_name.as_string() == "value") {
@@ -131,7 +131,7 @@ JS::ThrowCompletionOr<JS::Value> SheetGlobalObject::internal_get(const JS::Prope
return Base::internal_get(property_name, receiver);
}
-JS::ThrowCompletionOr<bool> SheetGlobalObject::internal_set(const JS::PropertyName& property_name, JS::Value value, JS::Value receiver)
+JS::ThrowCompletionOr<bool> SheetGlobalObject::internal_set(const JS::PropertyKey& property_name, JS::Value value, JS::Value receiver)
{
if (property_name.is_string()) {
if (auto pos = m_sheet.parse_cell_name(property_name.as_string()); pos.has_value()) {
diff --git a/Userland/Applications/Spreadsheet/JSIntegration.h b/Userland/Applications/Spreadsheet/JSIntegration.h
index 264fb7af01..4519f22f88 100644
--- a/Userland/Applications/Spreadsheet/JSIntegration.h
+++ b/Userland/Applications/Spreadsheet/JSIntegration.h
@@ -27,9 +27,9 @@ public:
virtual ~SheetGlobalObject() override;
- virtual JS::ThrowCompletionOr<bool> internal_has_property(JS::PropertyName const& name) const override;
- virtual JS::ThrowCompletionOr<JS::Value> internal_get(JS::PropertyName const&, JS::Value receiver) const override;
- virtual JS::ThrowCompletionOr<bool> internal_set(JS::PropertyName const&, JS::Value value, JS::Value receiver) override;
+ virtual JS::ThrowCompletionOr<bool> internal_has_property(JS::PropertyKey const& name) const override;
+ virtual JS::ThrowCompletionOr<JS::Value> internal_get(JS::PropertyKey const&, JS::Value receiver) const override;
+ virtual JS::ThrowCompletionOr<bool> internal_set(JS::PropertyKey const&, JS::Value value, JS::Value receiver) override;
virtual void initialize_global_object() override;
JS_DECLARE_OLD_NATIVE_FUNCTION(get_real_cell_contents);
diff --git a/Userland/Applications/Spreadsheet/Spreadsheet.cpp b/Userland/Applications/Spreadsheet/Spreadsheet.cpp
index 84900d3b66..539c953d6e 100644
--- a/Userland/Applications/Spreadsheet/Spreadsheet.cpp
+++ b/Userland/Applications/Spreadsheet/Spreadsheet.cpp
@@ -648,7 +648,7 @@ RefPtr<Sheet> Sheet::from_xsv(const Reader::XSV& xsv, Workbook& workbook)
JsonObject Sheet::gather_documentation() const
{
JsonObject object;
- const JS::PropertyName doc_name { "__documentation" };
+ const JS::PropertyKey doc_name { "__documentation" };
auto add_docs_from = [&](auto& it, auto& global_object) {
auto value = global_object.get(it.key).release_value();