mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-09-20 17:58:18 +03:00
LibWeb: Add Element::did_remove_attribute() virtual
This allows subclasses to react to DOM attributes being removed.
This commit is contained in:
parent
e91b2c57c1
commit
bdf0254b16
Notes:
sideshowbarker
2024-07-17 20:19:08 +09:00
Author: https://github.com/awesomekling Commit: https://github.com/SerenityOS/serenity/commit/bdf0254b16
@ -161,6 +161,8 @@ void Element::remove_attribute(const FlyString& name)
|
||||
{
|
||||
m_attributes->remove_attribute(name);
|
||||
|
||||
did_remove_attribute(name);
|
||||
|
||||
// FIXME: Invalidate less.
|
||||
document().invalidate_style();
|
||||
}
|
||||
|
@ -83,6 +83,7 @@ public:
|
||||
|
||||
virtual void apply_presentational_hints(CSS::StyleProperties&) const { }
|
||||
virtual void parse_attribute(const FlyString& name, const String& value);
|
||||
virtual void did_remove_attribute(FlyString const&) { }
|
||||
|
||||
void recompute_style();
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user