mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 23:37:35 +00:00
LibWeb: Make CSS ParsingContext's Document* be const
The only reason it wasn't const before (and why we had a const_cast hack) was to support ImageStyleValue's constructor taking it, which no longer applies. `hack_count--;` :^)
This commit is contained in:
parent
0f393771b7
commit
f645ed199e
2 changed files with 5 additions and 6 deletions
|
@ -36,18 +36,18 @@ enum class PropertyID;
|
|||
class ParsingContext {
|
||||
public:
|
||||
ParsingContext() = default;
|
||||
explicit ParsingContext(DOM::Document&);
|
||||
explicit ParsingContext(DOM::Document const&);
|
||||
explicit ParsingContext(DOM::ParentNode&);
|
||||
|
||||
bool in_quirks_mode() const;
|
||||
DOM::Document* document() const { return m_document; }
|
||||
DOM::Document const* document() const { return m_document; }
|
||||
AK::URL complete_url(String const&) const;
|
||||
|
||||
PropertyID current_property_id() const { return m_current_property_id; }
|
||||
void set_current_property_id(PropertyID property_id) { m_current_property_id = property_id; }
|
||||
|
||||
private:
|
||||
DOM::Document* m_document { nullptr };
|
||||
DOM::Document const* m_document { nullptr };
|
||||
PropertyID m_current_property_id { PropertyID::Invalid };
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue