Branch: refs/heads/main Home: https://github.com/WebKit/WebKit Commit: 443a65a4c3a25485b3083c8a92f3be46e71102f2 https://github.com/WebKit/WebKit/commit/443a65a4c3a25485b3083c8a92f3be46e71102f2 Author: Brady Eidson <beid...@apple.com> Date: 2024-06-07 (Fri, 07 Jun 2024)
Changed paths: M LayoutTests/loader/stateobjects/pushstate-size-expected.txt M LayoutTests/loader/stateobjects/pushstate-size-iframe-expected.txt M LayoutTests/loader/stateobjects/pushstate-size-iframe.html M LayoutTests/loader/stateobjects/pushstate-size.html M LayoutTests/loader/stateobjects/resources/pushstate-iframe.html M Source/WebCore/history/HistoryItem.cpp M Source/WebCore/history/HistoryItem.h M Source/WebCore/loader/FrameLoader.cpp M Source/WebCore/loader/HistoryController.cpp M Source/WebCore/loader/HistoryController.h M Source/WebKit/Shared/WebBackForwardListItem.h M Source/WebKit/UIProcess/API/C/WKBackForwardListItemRef.cpp M Source/WebKit/UIProcess/API/C/WKBackForwardListItemRef.h M Source/WebKit/UIProcess/API/Cocoa/WKBackForwardListItem.h M Source/WebKit/UIProcess/API/Cocoa/WKBackForwardListItem.mm M Source/WebKit/WebProcess/WebCoreSupport/SessionStateConversion.cpp M Source/WebKitLegacy/mac/History/HistoryPropertyList.mm M Source/WebKitLegacy/mac/History/WebHistory.mm M Source/WebKitLegacy/mac/History/WebHistoryItem.mm M Source/WebKitLegacy/mac/History/WebHistoryItemInternal.h M Source/WebKitLegacy/mac/WebCoreSupport/WebFrameLoaderClient.mm M Tools/TestWebKitAPI/Tests/WebKit/WKBackForwardListTests.mm Log Message: ----------- REGRESSION (273650@main): Back forward list doesn’t have any webpage titles rdar://128448221 https://bugs.webkit.org/show_bug.cgi?id=275280 Reviewed by Alex Christensen. 273650@main was an update to the web APIs "pushState" and "replaceState" to remove their ability to change the title on a back/forward list item. That ability had left the other browsers and left the spec, so it was a fine removal to make. Unfortunately that change incorrectly assumed that no back/forward list item ever has a title. They do have titles - populated by WebKit itself from document titles - and they do show up in both the native WebKit API and inside WebKit based browsers. document.title population of the back/forward list entries happens in other browsers, as well. This change is a partial revert of 273650@main, leaving the web API changes in tact but restoring the WKBackForwardListItem.title functionality. * LayoutTests/loader/stateobjects/pushstate-size-expected.txt: * LayoutTests/loader/stateobjects/pushstate-size-iframe-expected.txt: * LayoutTests/loader/stateobjects/pushstate-size-iframe.html: * LayoutTests/loader/stateobjects/pushstate-size.html: * LayoutTests/loader/stateobjects/resources/pushstate-iframe.html: * Source/WebCore/history/HistoryItem.cpp: (WebCore::HistoryItem::HistoryItem): (WebCore::HistoryItem::reset): (WebCore::HistoryItem::title const): (WebCore::HistoryItem::alternateTitle const): (WebCore::HistoryItem::setAlternateTitle): (WebCore::HistoryItem::setTitle): * Source/WebCore/history/HistoryItem.h: (WebCore::HistoryItem::create): * Source/WebCore/loader/FrameLoader.cpp: (WebCore::FrameLoader::didChangeTitle): * Source/WebCore/loader/HistoryController.cpp: (WebCore::HistoryController::setCurrentItemTitle): (WebCore::HistoryController::initializeItem): * Source/WebCore/loader/HistoryController.h: * Source/WebKit/Shared/WebBackForwardListItem.h: (WebKit::WebBackForwardListItem::title const): * Source/WebKit/UIProcess/API/C/WKBackForwardListItemRef.cpp: (WKBackForwardListItemCopyTitle): * Source/WebKit/UIProcess/API/C/WKBackForwardListItemRef.h: * Source/WebKit/UIProcess/API/Cocoa/WKBackForwardListItem.h: * Source/WebKit/UIProcess/API/Cocoa/WKBackForwardListItem.mm: (-[WKBackForwardListItem title]): * Source/WebKit/WebProcess/WebCoreSupport/SessionStateConversion.cpp: (WebKit::toBackForwardListItemState): (WebKit::applyFrameState): (WebKit::toHistoryItem): * Source/WebKitLegacy/mac/History/HistoryPropertyList.mm: (HistoryPropertyListWriter::writeHistoryItem): * Source/WebKitLegacy/mac/History/WebHistory.mm: (-[WebHistoryPrivate visitedURL:withTitle:]): * Source/WebKitLegacy/mac/History/WebHistoryItem.mm: (-[WebHistoryItem initWithURLString:title:lastVisitedTimeInterval:]): (-[WebHistoryItem title]): (-[WebHistoryItem setAlternateTitle:]): (-[WebHistoryItem alternateTitle]): (-[WebHistoryItem initWithURLString:title:displayTitle:lastVisitedTimeInterval:]): (-[WebHistoryItem setTitle:]): (-[WebHistoryItem _visitedWithTitle:]): (-[WebHistoryItem _visited]): Deleted. * Source/WebKitLegacy/mac/History/WebHistoryItemInternal.h: * Source/WebKitLegacy/mac/WebCoreSupport/WebFrameLoaderClient.mm: (WebFrameLoaderClient::setTitle): * Tools/TestWebKitAPI/Tests/WebKit/WKBackForwardListTests.mm: (TEST(WKBackForwardList, SessionStateTitleTruncation)): Canonical link: https://commits.webkit.org/279844@main To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications _______________________________________________ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes