1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 04:47:34 +00:00

LibWeb+LibIDL: Fix (or paper over) various const-correctness issues

There's definitely stuff to iterate on here, but this takes care of
making the libraries compile with stricter RP and NNRP.
This commit is contained in:
Andreas Kling 2023-02-20 18:56:08 +01:00
parent 68b5df6bf1
commit f11899f885
22 changed files with 210 additions and 186 deletions

View file

@ -1,5 +1,5 @@
/*
* Copyright (c) 2018-2022, Andreas Kling <kling@serenityos.org>
* Copyright (c) 2018-2023, Andreas Kling <kling@serenityos.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
@ -21,7 +21,7 @@ enum class Important {
struct StyleProperty {
Important important { Important::No };
CSS::PropertyID property_id;
NonnullRefPtr<StyleValue> value;
NonnullRefPtr<StyleValue const> value;
DeprecatedString custom_name {};
};
@ -92,7 +92,7 @@ protected:
void set_the_declarations(Vector<StyleProperty> properties, HashMap<DeprecatedString, StyleProperty> custom_properties);
private:
bool set_a_css_declaration(PropertyID, NonnullRefPtr<StyleValue>, Important);
bool set_a_css_declaration(PropertyID, NonnullRefPtr<StyleValue const>, Important);
Vector<StyleProperty> m_properties;
HashMap<DeprecatedString, StyleProperty> m_custom_properties;