mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-28 11:49:44 +00:00
LibWeb: Set inertness of HTMLElement when inert attribute is changed
This commit is contained in:
parent
893e9e3eac
commit
a9ffc6359a
Notes:
github-actions[bot]
2025-02-21 12:43:40 +00:00
Author: https://github.com/tcl3
Commit: a9ffc6359a
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/3475
Reviewed-by: https://github.com/AtkinsSJ ✅
4 changed files with 49 additions and 0 deletions
|
@ -149,6 +149,8 @@ public:
|
|||
static void hide_all_popovers_until(Variant<GC::Ptr<HTMLElement>, GC::Ptr<DOM::Document>> endpoint, FocusPreviousElement focus_previous_element, FireEvents fire_events);
|
||||
static GC::Ptr<HTMLElement> topmost_popover_ancestor(GC::Ptr<DOM::Node> new_popover_or_top_layer_element, Vector<GC::Ref<HTMLElement>> const& popover_list, GC::Ptr<HTMLElement> invoker, IsPopover is_popover);
|
||||
|
||||
bool is_inert() const { return m_inert; }
|
||||
|
||||
protected:
|
||||
HTMLElement(DOM::Document&, DOM::QualifiedName);
|
||||
|
||||
|
@ -169,6 +171,9 @@ protected:
|
|||
// https://html.spec.whatwg.org/multipage/urls-and-fetching.html#implicitly-potentially-render-blocking
|
||||
virtual bool is_implicitly_potentially_render_blocking() const { return false; }
|
||||
|
||||
void set_inert(bool inert) { m_inert = inert; }
|
||||
void set_subtree_inertness(bool is_inert);
|
||||
|
||||
private:
|
||||
virtual bool is_html_element() const final { return true; }
|
||||
|
||||
|
@ -200,6 +205,8 @@ private:
|
|||
// https://html.spec.whatwg.org/multipage/interaction.html#click-in-progress-flag
|
||||
bool m_click_in_progress { false };
|
||||
|
||||
bool m_inert { false };
|
||||
|
||||
// Popover API
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/popover.html#popover-visibility-state
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue