mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-05-11 09:27:00 +02:00
LibWeb: Move element state style invalidation into a helper
Several HTML element state changes directly selected style invalidation reasons from their element implementations. Move those mappings into a new CSS::Invalidation::ElementStateInvalidator helper. This keeps details, dialog, option, and select code focused on their own state changes while CSS invalidation owns the style work those changes require. The existing invalidation breadth is preserved.
This commit is contained in:
committed by
Alexander Kalenik
parent
79c32f88d2
commit
c93dad7600
Notes:
github-actions[bot]
2026-04-29 13:49:00 +00:00
Author: https://github.com/awesomekling Commit: https://github.com/LadybirdBrowser/ladybird/commit/c93dad76009 Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/9160
@@ -11,6 +11,7 @@
|
||||
#include <LibWeb/Bindings/Intrinsics.h>
|
||||
#include <LibWeb/CSS/CSSStyleProperties.h>
|
||||
#include <LibWeb/CSS/ComputedProperties.h>
|
||||
#include <LibWeb/CSS/Invalidation/ElementStateInvalidator.h>
|
||||
#include <LibWeb/CSS/StyleValues/DisplayStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/KeywordStyleValue.h>
|
||||
#include <LibWeb/DOM/Document.h>
|
||||
@@ -521,7 +522,7 @@ void HTMLSelectElement::set_is_open(bool open)
|
||||
return;
|
||||
|
||||
m_is_open = open;
|
||||
invalidate_style(DOM::StyleInvalidationReason::HTMLSelectElementSetIsOpen);
|
||||
CSS::Invalidation::invalidate_style_after_select_open_state_change(*this);
|
||||
}
|
||||
|
||||
bool HTMLSelectElement::has_activation_behavior() const
|
||||
|
||||
Reference in New Issue
Block a user