Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 5a8c79c681d0746bed562b6551e1644b5f0cb69a
https://github.com/WebKit/WebKit/commit/5a8c79c681d0746bed562b6551e1644b5f0cb69a
Author: Aditya Keerthi <[email protected]>
Date: 2026-02-12 (Thu, 12 Feb 2026)
Changed paths:
M Source/WebKit/UIProcess/PDF/WKPDFPageNumberIndicator.mm
M Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm
Log Message:
-----------
[iOS] PDF display mode should be toggleable via context menu
https://bugs.webkit.org/show_bug.cgi?id=307638
rdar://170202790
Reviewed by Abrar Rahman Protyasha.
Rollback changes to make the display mode toggleable via the page number
indicator. Instead, the display mode can be changed via context menu.
* Source/WebKit/UIProcess/PDF/WKPDFPageNumberIndicator.mm:
(-[WKPDFPageNumberIndicator initWithFrame:view:pageCount:]):
(-[WKPDFPageNumberIndicator hide:]):
(-[WKPDFPageNumberIndicatorButton
contextMenuInteraction:willDisplayMenuForConfiguration:animator:]): Deleted.
(-[WKPDFPageNumberIndicatorButton
contextMenuInteraction:willEndForConfiguration:animator:]): Deleted.
(-[WKPDFPageNumberIndicator _isSinglePage]): Deleted.
(-[WKPDFPageNumberIndicator pdfPageNumberIndicatorButtonWillDisplayMenu:]):
Deleted.
(-[WKPDFPageNumberIndicator pdfPageNumberIndicatorButtonDidDismissMenu:]):
Deleted.
* Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView contextMenuInteraction:configurationForMenuAtLocation:]):
(-[WKContentView
_internalContextMenuInteraction:configurationForMenuAtLocation:completion:]):
(-[WKContentView continueContextMenuInteraction:completion:]):
The context menu containing PDF display options should only be shown if no other
menu would be presented. That is, a link or image is not context clicked.
Check the menu appearance style to prevent the menu from being accessible
via long press. The current intent is that the menu is only accessible using a
cursor.
(-[WKContentView shouldShowPDFDisplayOptions]):
(-[WKContentView continueContextMenuInteractionWithPDFDisplayOptions:]):
(-[WKContentView continueContextMenuInteraction:]): Deleted.
Canonical link: https://commits.webkit.org/307381@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications