mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-29 04:09:13 +00:00
LibWeb/HTML: Check associated document is fully active, not the window
This is a spec change, but we already implemented the correct version.
Corresponds to aa39b6b6b0
This commit is contained in:
parent
343df5d00f
commit
5b57856eae
Notes:
github-actions[bot]
2025-04-18 09:08:21 +00:00
Author: https://github.com/AtkinsSJ
Commit: 5b57856eae
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4324
1 changed files with 2 additions and 5 deletions
|
@ -1160,9 +1160,7 @@ bool Navigation::inner_navigate_event_firing_algorithm(
|
||||||
// 4. Wait for all of promisesList, with the following success steps:
|
// 4. Wait for all of promisesList, with the following success steps:
|
||||||
WebIDL::wait_for_all(
|
WebIDL::wait_for_all(
|
||||||
realm, promises_list, [event, this, api_method_tracker](auto const&) -> void {
|
realm, promises_list, [event, this, api_method_tracker](auto const&) -> void {
|
||||||
|
// 1. If event's relevant global object's associated Document is not fully active, then abort these steps.
|
||||||
// FIXME: Spec issue: Event's relevant global objects' *associated document*
|
|
||||||
// 1. If event's relevant global object is not fully active, then abort these steps.
|
|
||||||
auto& relevant_global_object = as<HTML::Window>(HTML::relevant_global_object(*event));
|
auto& relevant_global_object = as<HTML::Window>(HTML::relevant_global_object(*event));
|
||||||
auto& realm = event->realm();
|
auto& realm = event->realm();
|
||||||
if (!relevant_global_object.associated_document().is_fully_active())
|
if (!relevant_global_object.associated_document().is_fully_active())
|
||||||
|
@ -1197,8 +1195,7 @@ bool Navigation::inner_navigate_event_firing_algorithm(
|
||||||
m_transition = nullptr; },
|
m_transition = nullptr; },
|
||||||
// and the following failure steps given reason rejectionReason:
|
// and the following failure steps given reason rejectionReason:
|
||||||
[event, this, api_method_tracker](JS::Value rejection_reason) -> void {
|
[event, this, api_method_tracker](JS::Value rejection_reason) -> void {
|
||||||
// FIXME: Spec issue: Event's relevant global objects' *associated document*
|
// 1. If event's relevant global object's associated Document is not fully active, then abort these steps.
|
||||||
// 1. If event's relevant global object is not fully active, then abort these steps.
|
|
||||||
auto& relevant_global_object = as<HTML::Window>(HTML::relevant_global_object(*event));
|
auto& relevant_global_object = as<HTML::Window>(HTML::relevant_global_object(*event));
|
||||||
auto& realm = event->realm();
|
auto& realm = event->realm();
|
||||||
if (!relevant_global_object.associated_document().is_fully_active())
|
if (!relevant_global_object.associated_document().is_fully_active())
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue