Skip to content
Permalink
Browse files
[Extra zoom mode] Delegate scrolling from the content view to input v…
…iew controllers

https://bugs.webkit.org/show_bug.cgi?id=182534
<rdar://problem/37276625>

Reviewed by Tim Horton.

Override -_wheelChangedWithEvent: on the content view, and give extra zoomed input view controllers a chance to
handle the event.

* Platform/spi/ios/UIKitSPI.h:
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _wheelChangedWithEvent:]):


Canonical link: https://commits.webkit.org/198383@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@228246 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
whsieh committed Feb 7, 2018
1 parent dba3fdd commit 86d7d4865ec80edcdf26292b7c66130b93396133
Showing with 34 additions and 0 deletions.
  1. +15 −0 Source/WebKit/ChangeLog
  2. +1 −0 Source/WebKit/Platform/spi/ios/UIKitSPI.h
  3. +18 −0 Source/WebKit/UIProcess/ios/WKContentViewInteraction.mm
@@ -1,3 +1,18 @@
2018-02-07 Wenson Hsieh <wenson_hsieh@apple.com>

[Extra zoom mode] Delegate scrolling from the content view to input view controllers
https://bugs.webkit.org/show_bug.cgi?id=182534
<rdar://problem/37276625>

Reviewed by Tim Horton.

Override -_wheelChangedWithEvent: on the content view, and give extra zoomed input view controllers a chance to
handle the event.

* Platform/spi/ios/UIKitSPI.h:
* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _wheelChangedWithEvent:]):

2018-02-07 Wenson Hsieh <wenson_hsieh@apple.com>

[Extra zoom mode] Implement multiple and single select menus
@@ -307,6 +307,7 @@ typedef enum {

@interface UIResponder ()
- (void)_handleKeyUIEvent:(UIEvent *)event;
- (void)_wheelChangedWithEvent:(UIEvent *)event;
@end

@class CADisplay;
@@ -4359,6 +4359,24 @@ - (NSUInteger)startingIndexForSelectMenu:(WKSelectMenuViewController *)selectMen

#endif // ENABLE(EXTRA_ZOOM_MODE)

- (void)_wheelChangedWithEvent:(UIEvent *)event
{
#if ENABLE(EXTRA_ZOOM_MODE)
if ([_numberPadViewController handleWheelEvent:event])
return;

if ([_textInputViewController handleWheelEvent:event])
return;

if ([_selectMenuViewController handleWheelEvent:event])
return;

if ([_focusedFormControlViewController handleWheelEvent:event])
return;
#endif
[super _wheelChangedWithEvent:event];
}

- (void)_selectionChanged
{
_selectionNeedsUpdate = YES;

0 comments on commit 86d7d48

Please sign in to comment.