[webkit-changes] [WebKit/WebKit] 4d2088: [Navigation] Implement the initialize the navigati...

Rob Buis noreply at github.com
Thu Jan 25 12:50:39 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 4d20880a9333b70b8444b5305d52035589e893ba
      https://github.com/WebKit/WebKit/commit/4d20880a9333b70b8444b5305d52035589e893ba
  Author: Rob Buis <rbuis at igalia.com>
  Date:   2024-01-25 (Thu, 25 Jan 2024)

  Changed paths:
    M Source/WebCore/loader/FrameLoader.cpp
    M Source/WebCore/loader/FrameLoader.h
    M Source/WebCore/page/LocalDOMWindow.cpp
    M Source/WebCore/page/LocalDOMWindow.h
    M Source/WebCore/page/Navigation.cpp
    M Source/WebCore/page/Navigation.h
    M Source/WebCore/page/NavigationHistoryEntry.cpp
    M Source/WebCore/page/NavigationHistoryEntry.h

  Log Message:
  -----------
  [Navigation] Implement the initialize the navigation API entries algorithm
https://bugs.webkit.org/show_bug.cgi?id=267636

Reviewed by Alex Christensen and Chris Dumez.

Implement the initialize the navigation API entries algorithm [1] by calling it in FrameLoader
when a new document is starting to be loaded.

Also add a minimal implementation of the has entries and events disabled algorithm [2]
in order to not regress existing navigation API tests.

[1] https://html.spec.whatwg.org/multipage/nav-history-apis.html#initialize-the-navigation-api-entries-for-a-new-document
[2] https://html.spec.whatwg.org/multipage/nav-history-apis.html#has-entries-and-events-disabled

* Source/WebCore/loader/FrameLoader.cpp:
(WebCore::FrameLoader::didBeginDocument):
(WebCore::FrameLoader::updateNavigationAPIEntries):
* Source/WebCore/loader/FrameLoader.h:
* Source/WebCore/page/LocalDOMWindow.cpp:
(WebCore::LocalDOMWindow::navigation):
(WebCore::LocalDOMWindow::protectedNavigation):
* Source/WebCore/page/LocalDOMWindow.h:
* Source/WebCore/page/Navigation.cpp:
(WebCore::Navigation::Navigation):
(WebCore::Navigation::initializeEntries):
(WebCore::Navigation::entries const):
(WebCore::Navigation::currentEntry const):
(WebCore::Navigation::navigate):
(WebCore::Navigation::reload):
(WebCore::Navigation::traverseTo):
(WebCore::Navigation::back):
(WebCore::Navigation::forward):
(WebCore::Navigation::hasEntriesAndEventsDisabled const):
* Source/WebCore/page/Navigation.h:
* Source/WebCore/page/NavigationHistoryEntry.cpp:
(WebCore::NavigationHistoryEntry::NavigationHistoryEntry):
* Source/WebCore/page/NavigationHistoryEntry.h:

Canonical link: https://commits.webkit.org/273532@main




More information about the webkit-changes mailing list