Title: [160197] trunk/Source/WebKit2
Revision
160197
Author
[email protected]
Date
2013-12-05 15:33:10 -0800 (Thu, 05 Dec 2013)

Log Message

AX: Seed: safari extension installation crashes safari under voice over and freezes voice over
https://bugs.webkit.org/show_bug.cgi?id=125308

Reviewed by Anders Carlsson.

Much like _javascript_ alerts, we need to allow accessibility clients to continue to interact with the WebProcess thread
when using dispatchDecidePolicyResponses.

* Platform/CoreIPC/MessageSender.h:
(CoreIPC::MessageSender::sendSync):
* WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
(WebKit::WebFrameLoaderClient::dispatchDecidePolicyForResponse):

Modified Paths

Diff

Modified: trunk/Source/WebKit2/ChangeLog (160196 => 160197)


--- trunk/Source/WebKit2/ChangeLog	2013-12-05 23:12:47 UTC (rev 160196)
+++ trunk/Source/WebKit2/ChangeLog	2013-12-05 23:33:10 UTC (rev 160197)
@@ -1,3 +1,18 @@
+2013-12-05  Chris Fleizach  <[email protected]>
+
+        AX: Seed: safari extension installation crashes safari under voice over and freezes voice over
+        https://bugs.webkit.org/show_bug.cgi?id=125308
+
+        Reviewed by Anders Carlsson.
+
+        Much like _javascript_ alerts, we need to allow accessibility clients to continue to interact with the WebProcess thread
+        when using dispatchDecidePolicyResponses.
+
+        * Platform/CoreIPC/MessageSender.h:
+        (CoreIPC::MessageSender::sendSync):
+        * WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp:
+        (WebKit::WebFrameLoaderClient::dispatchDecidePolicyForResponse):
+
 2013-12-05  Anders Carlsson  <[email protected]>
 
         "Use Selection for Find" doesn't work in PDF viewed in Safari

Modified: trunk/Source/WebKit2/Platform/CoreIPC/MessageSender.h (160196 => 160197)


--- trunk/Source/WebKit2/Platform/CoreIPC/MessageSender.h	2013-12-05 23:12:47 UTC (rev 160196)
+++ trunk/Source/WebKit2/Platform/CoreIPC/MessageSender.h	2013-12-05 23:33:10 UTC (rev 160197)
@@ -51,19 +51,19 @@
     }
 
     template<typename T>
-    bool sendSync(T&& message, typename T::Reply&& reply, double timeout = Connection::NoTimeout)
+    bool sendSync(T&& message, typename T::Reply&& reply, double timeout = Connection::NoTimeout, unsigned syncSendFlags = 0)
     {
         static_assert(T::isSync, "Message is not sync!");
 
-        return sendSync(std::forward<T>(message), std::move(reply), messageSenderDestinationID(), timeout);
+        return sendSync(std::forward<T>(message), std::move(reply), messageSenderDestinationID(), timeout, syncSendFlags);
     }
 
     template<typename T>
-    bool sendSync(T&& message, typename T::Reply&& reply, uint64_t destinationID, double timeout = Connection::NoTimeout)
+    bool sendSync(T&& message, typename T::Reply&& reply, uint64_t destinationID, double timeout = Connection::NoTimeout, unsigned syncSendFlags = 0)
     {
         ASSERT(messageSenderConnection());
 
-        return messageSenderConnection()->sendSync(std::move(message), std::move(reply), destinationID, timeout);
+        return messageSenderConnection()->sendSync(std::move(message), std::move(reply), destinationID, timeout, syncSendFlags);
     }
 
     bool sendMessage(std::unique_ptr<MessageEncoder>);

Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp (160196 => 160197)


--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp	2013-12-05 23:12:47 UTC (rev 160196)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp	2013-12-05 23:33:10 UTC (rev 160197)
@@ -51,6 +51,7 @@
 #include "WebProcessProxyMessages.h"
 #include <_javascript_Core/APICast.h>
 #include <_javascript_Core/JSObject.h>
+#include <WebCore/AXObjectCache.h>
 #include <WebCore/Chrome.h>
 #include <WebCore/DOMWrapperWorld.h>
 #include <WebCore/DocumentLoader.h>
@@ -646,7 +647,8 @@
     uint64_t downloadID;
 
     // Notify the UIProcess.
-    if (!webPage->sendSync(Messages::WebPageProxy::DecidePolicyForResponseSync(m_frame->frameID(), response, request, canShowMIMEType, listenerID, InjectedBundleUserMessageEncoder(userData.get())), Messages::WebPageProxy::DecidePolicyForResponseSync::Reply(receivedPolicyAction, policyAction, downloadID)))
+    unsigned syncSendFlags = (WebCore::AXObjectCache::accessibilityEnabled()) ? CoreIPC::SpinRunLoopWhileWaitingForReply : 0;
+    if (!webPage->sendSync(Messages::WebPageProxy::DecidePolicyForResponseSync(m_frame->frameID(), response, request, canShowMIMEType, listenerID, InjectedBundleUserMessageEncoder(userData.get())), Messages::WebPageProxy::DecidePolicyForResponseSync::Reply(receivedPolicyAction, policyAction, downloadID), CoreIPC::Connection::NoTimeout, syncSendFlags))
         return;
 
     // We call this synchronously because CFNetwork can only convert a loading connection to a download from its didReceiveResponse callback.
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to