Title: [188162] trunk/Source
Revision
188162
Author
wenson_hs...@apple.com
Date
2015-08-07 14:12:47 -0700 (Fri, 07 Aug 2015)

Log Message

Temporarily allow programmatic input assistance for adding Gmail account
https://bugs.webkit.org/show_bug.cgi?id=147792

Reviewed by Enrica Casucci.
<rdar://problem/22126518>

Temporary fix for keyboard input sliding out and immediately back in upon user interaction
in the Gmail 2-factor authentication page.

Source/WebCore:

* platform/RuntimeApplicationChecksIOS.h:
* platform/RuntimeApplicationChecksIOS.mm:
(WebCore::applicationIsGmailAddAccountOnIOS): Added bundle ID for Gmail settings.

Source/WebKit2:

* UIProcess/ios/WKContentViewInteraction.mm:
(-[WKContentView _startAssistingNode:userIsInteracting:blurPreviousNode:userObject:]): Early
    return no longer triggers due to lack of user interaction when adding a new Gmail account
    through Settings.

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (188161 => 188162)


--- trunk/Source/WebCore/ChangeLog	2015-08-07 21:12:16 UTC (rev 188161)
+++ trunk/Source/WebCore/ChangeLog	2015-08-07 21:12:47 UTC (rev 188162)
@@ -1,3 +1,18 @@
+2015-08-07  Wenson Hsieh  <wenson_hs...@apple.com>
+
+        Temporarily allow programmatic input assistance for adding Gmail account
+        https://bugs.webkit.org/show_bug.cgi?id=147792
+
+        Reviewed by Enrica Casucci.
+        <rdar://problem/22126518>
+
+        Temporary fix for keyboard input sliding out and immediately back in upon user interaction
+        in the Gmail 2-factor authentication page.
+
+        * platform/RuntimeApplicationChecksIOS.h:
+        * platform/RuntimeApplicationChecksIOS.mm:
+        (WebCore::applicationIsGmailAddAccountOnIOS): Added bundle ID for Gmail settings.
+
 2015-08-07  Andy Estes  <aes...@apple.com>
 
         Crash when following a Google search link to Twitter with Limit Adult Content enabled

Modified: trunk/Source/WebCore/platform/RuntimeApplicationChecksIOS.h (188161 => 188162)


--- trunk/Source/WebCore/platform/RuntimeApplicationChecksIOS.h	2015-08-07 21:12:16 UTC (rev 188161)
+++ trunk/Source/WebCore/platform/RuntimeApplicationChecksIOS.h	2015-08-07 21:12:47 UTC (rev 188162)
@@ -43,6 +43,7 @@
 WEBCORE_EXPORT bool applicationIsTheEconomistOnIPhone();
 bool applicationIsWebProcess();
 bool applicationIsIBooksOnIOS();
+WEBCORE_EXPORT bool applicationIsGmailAddAccountOnIOS();
 
 } // namespace WebCore
 

Modified: trunk/Source/WebCore/platform/RuntimeApplicationChecksIOS.mm (188161 => 188162)


--- trunk/Source/WebCore/platform/RuntimeApplicationChecksIOS.mm	2015-08-07 21:12:16 UTC (rev 188161)
+++ trunk/Source/WebCore/platform/RuntimeApplicationChecksIOS.mm	2015-08-07 21:12:47 UTC (rev 188162)
@@ -122,6 +122,12 @@
     return isIBooksOnIOS;
 }
 
+bool applicationIsGmailAddAccountOnIOS()
+{
+    static const bool isGmailAddAccountOnIOS = [[[NSBundle mainBundle] bundleIdentifier] isEqualToString:@"com.apple.social.SLGoogleAuth.SLGoogleAuthService"];
+    return isGmailAddAccountOnIOS;
+}
+
 } // namespace WebCore
 
 #endif // PLATFORM(IOS)

Modified: trunk/Source/WebKit2/ChangeLog (188161 => 188162)


--- trunk/Source/WebKit2/ChangeLog	2015-08-07 21:12:16 UTC (rev 188161)
+++ trunk/Source/WebKit2/ChangeLog	2015-08-07 21:12:47 UTC (rev 188162)
@@ -1,3 +1,19 @@
+2015-08-07  Wenson Hsieh  <wenson_hs...@apple.com>
+
+        Temporarily allow programmatic input assistance for adding Gmail account
+        https://bugs.webkit.org/show_bug.cgi?id=147792
+
+        Reviewed by Enrica Casucci.
+        <rdar://problem/22126518>
+
+        Temporary fix for keyboard input sliding out and immediately back in upon user interaction
+        in the Gmail 2-factor authentication page.
+
+        * UIProcess/ios/WKContentViewInteraction.mm:
+        (-[WKContentView _startAssistingNode:userIsInteracting:blurPreviousNode:userObject:]): Early
+            return no longer triggers due to lack of user interaction when adding a new Gmail account
+            through Settings.
+
 2015-08-07  Brady Eidson  <beid...@apple.com>
 
         Move concrete KeyedDecoder/Encoder implementations to WebCore.

Modified: trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm (188161 => 188162)


--- trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm	2015-08-07 21:12:16 UTC (rev 188161)
+++ trunk/Source/WebKit2/UIProcess/ios/WKContentViewInteraction.mm	2015-08-07 21:12:47 UTC (rev 188162)
@@ -64,6 +64,7 @@
 #import <WebCore/Pasteboard.h>
 #import <WebCore/Path.h>
 #import <WebCore/PathUtilities.h>
+#import <WebCore/RuntimeApplicationChecksIOS.h>
 #import <WebCore/Scrollbar.h>
 #import <WebCore/SoftLinking.h>
 #import <WebCore/TextIndicator.h>
@@ -3018,7 +3019,9 @@
 
 - (void)_startAssistingNode:(const AssistedNodeInformation&)information userIsInteracting:(BOOL)userIsInteracting blurPreviousNode:(BOOL)blurPreviousNode userObject:(NSObject <NSSecureCoding> *)userObject
 {
-    if (!userIsInteracting && !_textSelectionAssistant)
+    // FIXME: This is a temporary workaround for <rdar://problem/22126518>. The real fix will involve refactoring
+    // the way we assist programmatically focused nodes.
+    if (!applicationIsGmailAddAccountOnIOS() && !userIsInteracting && !_textSelectionAssistant)
         return;
 
     if (blurPreviousNode)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to