Title: [171129] trunk/Source/WebKit2
Revision
171129
Author
m...@apple.com
Date
2014-07-15 18:29:18 -0700 (Tue, 15 Jul 2014)

Log Message

WKWebView’s FormClient::willSubmitForm should use CompletionHandlerCallChecker
https://bugs.webkit.org/show_bug.cgi?id=134951

Reviewed by Tim Horton.

* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _setFormDelegate:]):

Modified Paths

Diff

Modified: trunk/Source/WebKit2/ChangeLog (171128 => 171129)


--- trunk/Source/WebKit2/ChangeLog	2014-07-16 00:53:24 UTC (rev 171128)
+++ trunk/Source/WebKit2/ChangeLog	2014-07-16 01:29:18 UTC (rev 171129)
@@ -1,3 +1,13 @@
+2014-07-15  Dan Bernstein  <m...@apple.com>
+
+        WKWebView’s FormClient::willSubmitForm should use CompletionHandlerCallChecker
+        https://bugs.webkit.org/show_bug.cgi?id=134951
+
+        Reviewed by Tim Horton.
+
+        * UIProcess/API/Cocoa/WKWebView.mm:
+        (-[WKWebView _setFormDelegate:]):
+
 2014-07-15  Benjamin Poulain  <benja...@webkit.org>
 
         [iOS][WK2] Scrolling request from the scrolling tree must be limited to offsets in the document

Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm (171128 => 171129)


--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm	2014-07-16 00:53:24 UTC (rev 171128)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm	2014-07-16 01:29:18 UTC (rev 171129)
@@ -29,6 +29,7 @@
 #if WK_API_ENABLED
 
 #import "APIFormClient.h"
+#import "CompletionHandlerCallChecker.h"
 #import "FindClient.h"
 #import "LegacySessionStateCoding.h"
 #import "NavigationState.h"
@@ -1976,7 +1977,9 @@
                 }
             }
 
-            [formDelegate _webView:m_webView willSubmitFormValues:valueMap.get() userObject:userObject submissionHandler:^{
+            RefPtr<WebKit::CompletionHandlerCallChecker> checker = WebKit::CompletionHandlerCallChecker::create(formDelegate.get(), @selector(_webView:willSubmitFormValues:userObject:submissionHandler:));
+            [formDelegate _webView:m_webView willSubmitFormValues:valueMap.get() userObject:userObject submissionHandler:[listener, checker] {
+                checker->didCallCompletionHandler();
                 listener->continueSubmission();
             }];
             return true;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to