mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-29 04:37:55 +00:00
@@ -48,7 +48,7 @@ Optional<String> NavigationHistoryEntry::url() const
|
||||
{
|
||||
// The url getter steps are:
|
||||
// 1. Let document be this's relevant global object's associated Document.
|
||||
auto& document = verify_cast<HTML::Window>(relevant_global_object(*this)).associated_document();
|
||||
auto& document = as<HTML::Window>(relevant_global_object(*this)).associated_document();
|
||||
|
||||
// 2. If document is not fully active, then return the empty string.
|
||||
if (!document.is_fully_active())
|
||||
@@ -73,7 +73,7 @@ String NavigationHistoryEntry::key() const
|
||||
{
|
||||
// The key of a NavigationHistoryEntry nhe is given by the return value of the following algorithm:
|
||||
// 1. If nhe's relevant global object's associated Document is not fully active, then return the empty string.
|
||||
auto& associated_document = verify_cast<HTML::Window>(relevant_global_object(*this)).associated_document();
|
||||
auto& associated_document = as<HTML::Window>(relevant_global_object(*this)).associated_document();
|
||||
if (!associated_document.is_fully_active())
|
||||
return {};
|
||||
|
||||
@@ -86,7 +86,7 @@ String NavigationHistoryEntry::id() const
|
||||
{
|
||||
// The ID of a NavigationHistoryEntry nhe is given by the return value of the following algorithm:
|
||||
// 1. If nhe's relevant global object's associated Document is not fully active, then return the empty string.
|
||||
auto& associated_document = verify_cast<HTML::Window>(relevant_global_object(*this)).associated_document();
|
||||
auto& associated_document = as<HTML::Window>(relevant_global_object(*this)).associated_document();
|
||||
if (!associated_document.is_fully_active())
|
||||
return {};
|
||||
|
||||
@@ -99,7 +99,7 @@ i64 NavigationHistoryEntry::index() const
|
||||
{
|
||||
// The index of a NavigationHistoryEntry nhe is given by the return value of the following algorithm:
|
||||
// 1. If nhe's relevant global object's associated Document is not fully active, then return −1.
|
||||
auto& this_relevant_global_object = verify_cast<HTML::Window>(relevant_global_object(*this));
|
||||
auto& this_relevant_global_object = as<HTML::Window>(relevant_global_object(*this));
|
||||
if (!this_relevant_global_object.associated_document().is_fully_active())
|
||||
return -1;
|
||||
|
||||
@@ -113,7 +113,7 @@ bool NavigationHistoryEntry::same_document() const
|
||||
{
|
||||
// The sameDocument getter steps are:
|
||||
// 1. Let document be this's relevant global object's associated Document.
|
||||
auto& document = verify_cast<HTML::Window>(relevant_global_object(*this)).associated_document();
|
||||
auto& document = as<HTML::Window>(relevant_global_object(*this)).associated_document();
|
||||
|
||||
// 2. If document is not fully active, then return false.
|
||||
if (!document.is_fully_active())
|
||||
@@ -128,7 +128,7 @@ WebIDL::ExceptionOr<JS::Value> NavigationHistoryEntry::get_state()
|
||||
{
|
||||
// The getState() method steps are:
|
||||
// 1. If this's relevant global object's associated Document is not fully active, then return undefined.
|
||||
auto& associated_document = verify_cast<HTML::Window>(relevant_global_object(*this)).associated_document();
|
||||
auto& associated_document = as<HTML::Window>(relevant_global_object(*this)).associated_document();
|
||||
if (!associated_document.is_fully_active())
|
||||
return JS::js_undefined();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user