Changeset 256378 in webkit
- Timestamp:
- Feb 11, 2020 2:57:39 PM (4 years ago)
- Location:
- trunk/Source/WebKit
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit/ChangeLog
r256376 r256378 1 2020-02-11 Daniel Bates <dabates@apple.com> 2 3 Should not allow zooming to reveal focused element when suppressing selection assistant 4 https://bugs.webkit.org/show_bug.cgi?id=207575 5 6 Reviewed by Wenson Hsieh. 7 8 Do not tell the UIScrollView to scroll and zoom to reveal the focused element when the 9 selection assistant is being suppressed as it does not make sense to do so: the primary 10 motivation for zooming to reveal the focused (aka the editable) element is make it easier 11 to edit it. 12 13 This fixes a bug where previewing a partially offscreen link inside an editable element 14 would cause the page content to scroll and zoom to reveal the editable element. Previewing 15 a link is not considered an editing operation and selection assistance is prevented, but 16 "zoom to reveal" was inadvertently allowed. Now it is not. 17 18 * UIProcess/ios/WKContentViewInteraction.h: 19 * UIProcess/ios/WKContentViewInteraction.mm: 20 (-[WKContentView _zoomToRevealFocusedElement]): Bail out if selection is being suppressed 21 for any reason. Note that pre-r245882 there was reason SuppressSelectionAssistantReason::DropAnimationIsRunning 22 that was used to suppress selection assistance AND allow "zoom to reveal". But this 23 reason was removed and there are no suppression reasons as of the time of writing where 24 it makes sense to have behavior like SuppressSelectionAssistantReason::DropAnimationIsRunning. 25 1 26 2020-02-11 Alex Christensen <achristensen@webkit.org> 2 27 -
trunk/Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm
r256105 r256378 1937 1937 - (void)_zoomToRevealFocusedElement 1938 1938 { 1939 if (_suppressSelectionAssistantReasons .contains(WebKit::EditableRootIsTransparentOrFullyClipped) || _suppressSelectionAssistantReasons.contains(WebKit::FocusedElementIsTooSmall))1939 if (_suppressSelectionAssistantReasons) 1940 1940 return; 1941 1941
Note: See TracChangeset
for help on using the changeset viewer.