mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-20 00:08:55 +00:00
LibWeb: Update Document::is_active() for navigables
This commit is contained in:
parent
e5302e0f56
commit
bd119b92f1
Notes:
sideshowbarker
2024-07-17 20:19:08 +09:00
Author: https://github.com/kalenikaliaksandr
Commit: bd119b92f1
Pull-request: https://github.com/SerenityOS/serenity/pull/18219
1 changed files with 1 additions and 3 deletions
|
@ -2025,11 +2025,9 @@ bool Document::is_fully_active() const
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
// https://html.spec.whatwg.org/multipage/browsers.html#active-document
|
|
||||||
bool Document::is_active() const
|
bool Document::is_active() const
|
||||||
{
|
{
|
||||||
// A browsing context's active document is its active window's associated Document.
|
return navigable() && navigable()->active_document() == this;
|
||||||
return browsing_context() && browsing_context()->active_document() == this;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// https://html.spec.whatwg.org/multipage/history.html#dom-document-location
|
// https://html.spec.whatwg.org/multipage/history.html#dom-document-location
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue