REGRESSION (r213584): WeChat app can not switch to next text field
authortimothy_horton@apple.com <timothy_horton@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 9 Jun 2017 22:35:01 +0000 (22:35 +0000)
committertimothy_horton@apple.com <timothy_horton@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 9 Jun 2017 22:35:01 +0000 (22:35 +0000)
https://bugs.webkit.org/show_bug.cgi?id=173183
<rdar://problem/32323478>

Reviewed by Wenson Hsieh.

* Platform/spi/ios/UIKitSPI.h:
* UIProcess/ios/InputViewUpdateDeferrer.mm:
(WebKit::InputViewUpdateDeferrer::~InputViewUpdateDeferrer):
It turns out that _endIgnoringReloadInputViews doesn't actually perform
the update if there was one ignored. It does, however, return whether
there was a change ignored, and we can force an update.

This remains untestable without sizable additional API test infrastructure
for the same reasons as the original patch.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@218023 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebKit2/ChangeLog
Source/WebKit2/Platform/spi/ios/UIKitSPI.h
Source/WebKit2/UIProcess/ios/InputViewUpdateDeferrer.mm

index 0f04e4c..8ac9505 100644 (file)
@@ -1,3 +1,21 @@
+2017-06-09  Tim Horton  <timothy_horton@apple.com>
+
+        REGRESSION (r213584): WeChat app can not switch to next text field
+        https://bugs.webkit.org/show_bug.cgi?id=173183
+        <rdar://problem/32323478>
+
+        Reviewed by Wenson Hsieh.
+
+        * Platform/spi/ios/UIKitSPI.h:
+        * UIProcess/ios/InputViewUpdateDeferrer.mm:
+        (WebKit::InputViewUpdateDeferrer::~InputViewUpdateDeferrer):
+        It turns out that _endIgnoringReloadInputViews doesn't actually perform
+        the update if there was one ignored. It does, however, return whether
+        there was a change ignored, and we can force an update.
+
+        This remains untestable without sizable additional API test infrastructure
+        for the same reasons as the original patch.
+
 2017-06-09  Chris Dumez  <cdumez@apple.com>
 
         Make sure we protect |this| in lambdas in WebResourceLoadStatisticsStore::registerSharedResourceLoadObserver()
index 7ca5f35..8cd9bc2 100644 (file)
@@ -885,7 +885,8 @@ typedef enum {
 
 @interface UIPeripheralHost (IPI)
 - (void)_beginIgnoringReloadInputViews;
-- (void)_endIgnoringReloadInputViews;
+- (int)_endIgnoringReloadInputViews;
+- (void)forceReloadInputViews;
 @end
 
 @interface UIResponder ()
index a6d8d85..96a3a86 100644 (file)
@@ -41,7 +41,8 @@ InputViewUpdateDeferrer::InputViewUpdateDeferrer()
 
 InputViewUpdateDeferrer::~InputViewUpdateDeferrer()
 {
-    [[UIPeripheralHost sharedInstance] _endIgnoringReloadInputViews];
+    if ([[UIPeripheralHost sharedInstance] _endIgnoringReloadInputViews])
+        [[UIPeripheralHost sharedInstance] forceReloadInputViews];
 }
     
 }