mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 00:37:34 +00:00
LibWeb: Rename BrowsingContextContainer => NavigableContainer
The "browsing context container" concept in the HTML spec has been replaced with "navigable container". Renaming this is the first step of many towards implementing the new world. Co-authored-by: Aliaksandr Kalenik <kalenik.aliaksandr@gmail.com>
This commit is contained in:
parent
0f9f6aef81
commit
d8ccc2d54e
17 changed files with 61 additions and 60 deletions
|
@ -12,12 +12,12 @@
|
|||
#include <LibWeb/DOM/Range.h>
|
||||
#include <LibWeb/Fetch/Infrastructure/HTTP/Requests.h>
|
||||
#include <LibWeb/HTML/BrowsingContext.h>
|
||||
#include <LibWeb/HTML/BrowsingContextContainer.h>
|
||||
#include <LibWeb/HTML/BrowsingContextGroup.h>
|
||||
#include <LibWeb/HTML/CrossOrigin/CrossOriginOpenerPolicy.h>
|
||||
#include <LibWeb/HTML/EventLoop/EventLoop.h>
|
||||
#include <LibWeb/HTML/HTMLAnchorElement.h>
|
||||
#include <LibWeb/HTML/HTMLInputElement.h>
|
||||
#include <LibWeb/HTML/NavigableContainer.h>
|
||||
#include <LibWeb/HTML/RemoteBrowsingContext.h>
|
||||
#include <LibWeb/HTML/SandboxingFlagSet.h>
|
||||
#include <LibWeb/HTML/Scripting/WindowEnvironmentSettingsObject.h>
|
||||
|
@ -87,7 +87,7 @@ JS::NonnullGCPtr<BrowsingContext> BrowsingContext::create_a_new_top_level_browsi
|
|||
JS::NonnullGCPtr<BrowsingContext> BrowsingContext::create_a_new_browsing_context(Page& page, JS::GCPtr<DOM::Document> creator, JS::GCPtr<DOM::Element> embedder, BrowsingContextGroup&)
|
||||
{
|
||||
// 1. Let browsingContext be a new browsing context.
|
||||
BrowsingContextContainer* container = (embedder && is<BrowsingContextContainer>(*embedder)) ? static_cast<BrowsingContextContainer*>(embedder.ptr()) : nullptr;
|
||||
NavigableContainer* container = (embedder && is<NavigableContainer>(*embedder)) ? static_cast<NavigableContainer*>(embedder.ptr()) : nullptr;
|
||||
auto browsing_context = Bindings::main_thread_vm().heap().allocate_without_realm<BrowsingContext>(page, container);
|
||||
|
||||
// 2. Let unsafeContextCreationTime be the unsafe shared current time.
|
||||
|
@ -226,7 +226,7 @@ JS::NonnullGCPtr<BrowsingContext> BrowsingContext::create_a_new_browsing_context
|
|||
return *browsing_context;
|
||||
}
|
||||
|
||||
BrowsingContext::BrowsingContext(Page& page, HTML::BrowsingContextContainer* container)
|
||||
BrowsingContext::BrowsingContext(Page& page, HTML::NavigableContainer* container)
|
||||
: m_page(page)
|
||||
, m_loader(*this)
|
||||
, m_event_handler({}, *this)
|
||||
|
@ -604,9 +604,9 @@ JS::GCPtr<DOM::Node> BrowsingContext::currently_focused_area()
|
|||
// 3. While candidate's focused area is a browsing context container with a non-null nested browsing context:
|
||||
// set candidate to the active document of that browsing context container's nested browsing context.
|
||||
while (candidate->focused_element()
|
||||
&& is<HTML::BrowsingContextContainer>(candidate->focused_element())
|
||||
&& static_cast<HTML::BrowsingContextContainer&>(*candidate->focused_element()).nested_browsing_context()) {
|
||||
candidate = static_cast<HTML::BrowsingContextContainer&>(*candidate->focused_element()).nested_browsing_context()->active_document();
|
||||
&& is<HTML::NavigableContainer>(candidate->focused_element())
|
||||
&& static_cast<HTML::NavigableContainer&>(*candidate->focused_element()).nested_browsing_context()) {
|
||||
candidate = static_cast<HTML::NavigableContainer&>(*candidate->focused_element()).nested_browsing_context()->active_document();
|
||||
}
|
||||
|
||||
// 4. If candidate's focused area is non-null, set candidate to candidate's focused area.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue