Title: [205487] trunk/Source

Diff

Modified: trunk/Source/WebCore/ChangeLog (205486 => 205487)


--- trunk/Source/WebCore/ChangeLog	2016-09-06 16:45:38 UTC (rev 205486)
+++ trunk/Source/WebCore/ChangeLog	2016-09-06 16:55:13 UTC (rev 205487)
@@ -1,3 +1,16 @@
+2016-09-06  Ryan Haddad  <[email protected]>
+
+        Unreviewed, rolling out r205407.
+
+        Not the correct way to implement this functionality
+
+        Reverted changeset:
+
+        "Consult with the FrameLoaderClient about whether or not
+        content extensions should be enabled when loading this URL."
+        https://bugs.webkit.org/show_bug.cgi?id=161441
+        http://trac.webkit.org/changeset/205407
+
 2016-09-06  Youenn Fablet  <[email protected]>
 
         http/tests/security/contentSecurityPolicy/worker-csp-blocks-xhr-redirect-cross-origin.html is flaky

Modified: trunk/Source/WebCore/loader/DocumentLoader.cpp (205486 => 205487)


--- trunk/Source/WebCore/loader/DocumentLoader.cpp	2016-09-06 16:45:38 UTC (rev 205486)
+++ trunk/Source/WebCore/loader/DocumentLoader.cpp	2016-09-06 16:55:13 UTC (rev 205487)
@@ -1478,11 +1478,6 @@
     m_contentFilter = !m_substituteData.isValid() ? ContentFilter::create(*this) : nullptr;
 #endif
 
-#if ENABLE(CONTENT_EXTENSIONS)
-    if (m_userContentExtensionsEnabled)
-        m_userContentExtensionsEnabled = frameLoader()->client().shouldUseContentExtensionsForURL(m_request.url());
-#endif
-
     // FIXME: Is there any way the extra fields could have not been added by now?
     // If not, it would be great to remove this line of code.
     // Note that currently, some requests may have incorrect extra fields even if this function has been called,

Modified: trunk/Source/WebCore/loader/EmptyClients.h (205486 => 205487)


--- trunk/Source/WebCore/loader/EmptyClients.h	2016-09-06 16:45:38 UTC (rev 205486)
+++ trunk/Source/WebCore/loader/EmptyClients.h	2016-09-06 16:55:13 UTC (rev 205487)
@@ -303,10 +303,6 @@
     void dispatchDidFinishLoad() override { }
     void dispatchDidReachLayoutMilestone(LayoutMilestones) override { }
 
-#if ENABLE(CONTENT_EXTENSIONS)
-    bool shouldUseContentExtensionsForURL(const URL&) override { return true; }
-#endif
-
     Frame* dispatchCreatePage(const NavigationAction&) override { return nullptr; }
     void dispatchShow() override { }
 

Modified: trunk/Source/WebCore/loader/FrameLoaderClient.h (205486 => 205487)


--- trunk/Source/WebCore/loader/FrameLoaderClient.h	2016-09-06 16:45:38 UTC (rev 205486)
+++ trunk/Source/WebCore/loader/FrameLoaderClient.h	2016-09-06 16:55:13 UTC (rev 205487)
@@ -173,10 +173,6 @@
         virtual void dispatchDidFinishDataDetection(NSArray *detectionResults) = 0;
 #endif
 
-#if ENABLE(CONTENT_EXTENSIONS)
-        virtual bool shouldUseContentExtensionsForURL(const URL&) = 0;
-#endif
-
         virtual void dispatchDidLayout() { }
         virtual void dispatchDidReachLayoutMilestone(LayoutMilestones) { }
 

Modified: trunk/Source/WebKit/mac/ChangeLog (205486 => 205487)


--- trunk/Source/WebKit/mac/ChangeLog	2016-09-06 16:45:38 UTC (rev 205486)
+++ trunk/Source/WebKit/mac/ChangeLog	2016-09-06 16:55:13 UTC (rev 205487)
@@ -1,3 +1,16 @@
+2016-09-06  Ryan Haddad  <[email protected]>
+
+        Unreviewed, rolling out r205407.
+
+        Not the correct way to implement this functionality
+
+        Reverted changeset:
+
+        "Consult with the FrameLoaderClient about whether or not
+        content extensions should be enabled when loading this URL."
+        https://bugs.webkit.org/show_bug.cgi?id=161441
+        http://trac.webkit.org/changeset/205407
+
 2016-09-05  Darin Adler  <[email protected]>
 
         More bindings improvements, particularly things not needed for _javascript_ bindings

Modified: trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.h (205486 => 205487)


--- trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.h	2016-09-06 16:45:38 UTC (rev 205486)
+++ trunk/Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.h	2016-09-06 16:55:13 UTC (rev 205487)
@@ -118,10 +118,6 @@
     void dispatchDidFinishLoad() override;
     void dispatchDidReachLayoutMilestone(WebCore::LayoutMilestones) override;
 
-#if ENABLE(CONTENT_EXTENSIONS)
-    bool shouldUseContentExtensionsForURL(const WebCore::URL&) override { return true; }
-#endif
-
     WebCore::Frame* dispatchCreatePage(const WebCore::NavigationAction&) override;
     void dispatchShow() override;
 

Modified: trunk/Source/WebKit2/ChangeLog (205486 => 205487)


--- trunk/Source/WebKit2/ChangeLog	2016-09-06 16:45:38 UTC (rev 205486)
+++ trunk/Source/WebKit2/ChangeLog	2016-09-06 16:55:13 UTC (rev 205487)
@@ -1,3 +1,16 @@
+2016-09-06  Ryan Haddad  <[email protected]>
+
+        Unreviewed, rolling out r205407.
+
+        Not the correct way to implement this functionality
+
+        Reverted changeset:
+
+        "Consult with the FrameLoaderClient about whether or not
+        content extensions should be enabled when loading this URL."
+        https://bugs.webkit.org/show_bug.cgi?id=161441
+        http://trac.webkit.org/changeset/205407
+
 2016-09-06  Carlos Garcia Campos  <[email protected]>
 
         [GTK][Wayland] evince-browser-plugin prevents viewing PDFs

Modified: trunk/Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundlePageLoaderClient.h (205486 => 205487)


--- trunk/Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundlePageLoaderClient.h	2016-09-06 16:45:38 UTC (rev 205486)
+++ trunk/Source/WebKit2/WebProcess/InjectedBundle/API/c/WKBundlePageLoaderClient.h	2016-09-06 16:55:13 UTC (rev 205487)
@@ -62,7 +62,6 @@
 typedef void (*WKBundlePageWillLoadURLRequestCallback)(WKBundlePageRef page, WKURLRequestRef request, WKTypeRef userData, const void *clientInfo);
 typedef void (*WKBundlePageWillLoadDataRequestCallback)(WKBundlePageRef page, WKURLRequestRef request, WKDataRef data, WKStringRef MIMEType, WKStringRef encodingName, WKURLRef unreachableURL, WKTypeRef userData, const void *clientInfo);
 typedef WKStringRef (*WKBundlePageUserAgentForURLCallback)(WKBundleFrameRef frame, WKURLRef url, const void *clientInfo);
-typedef bool (*WKBundlePageShouldUseContentExtensionsForURLCallback)(WKBundlePageRef page, WKURLRef url, const void *clientInfo);
 
 typedef struct WKBundlePageLoaderClientBase {
     int                                                                     version;
@@ -465,66 +464,4 @@
     WKBundlePageUserAgentForURLCallback                                     userAgentForURL;
 } WKBundlePageLoaderClientV8;
 
-typedef struct WKBundlePageLoaderClientV9 {
-    WKBundlePageLoaderClientBase                                            base;
-    
-    // Version 0.
-    WKBundlePageDidStartProvisionalLoadForFrameCallback                     didStartProvisionalLoadForFrame;
-    WKBundlePageDidReceiveServerRedirectForProvisionalLoadForFrameCallback  didReceiveServerRedirectForProvisionalLoadForFrame;
-    WKBundlePageDidFailProvisionalLoadWithErrorForFrameCallback             didFailProvisionalLoadWithErrorForFrame;
-    WKBundlePageDidCommitLoadForFrameCallback                               didCommitLoadForFrame;
-    WKBundlePageDidFinishDocumentLoadForFrameCallback                       didFinishDocumentLoadForFrame;
-    WKBundlePageDidFinishLoadForFrameCallback                               didFinishLoadForFrame;
-    WKBundlePageDidFailLoadWithErrorForFrameCallback                        didFailLoadWithErrorForFrame;
-    WKBundlePageDidSameDocumentNavigationForFrameCallback                   didSameDocumentNavigationForFrame;
-    WKBundlePageDidReceiveTitleForFrameCallback                             didReceiveTitleForFrame;
-    WKBundlePageDidFirstLayoutForFrameCallback                              didFirstLayoutForFrame;
-    WKBundlePageDidFirstVisuallyNonEmptyLayoutForFrameCallback              didFirstVisuallyNonEmptyLayoutForFrame;
-    WKBundlePageDidRemoveFrameFromHierarchyCallback                         didRemoveFrameFromHierarchy;
-    WKBundlePageDidDisplayInsecureContentForFrameCallback                   didDisplayInsecureContentForFrame;
-    WKBundlePageDidRunInsecureContentForFrameCallback                       didRunInsecureContentForFrame;
-    WKBundlePageDidClearWindowObjectForFrameCallback                        didClearWindowObjectForFrame;
-    WKBundlePageDidCancelClientRedirectForFrameCallback                     didCancelClientRedirectForFrame;
-    WKBundlePageWillPerformClientRedirectForFrameCallback                   willPerformClientRedirectForFrame;
-    WKBundlePageDidHandleOnloadEventsForFrameCallback                       didHandleOnloadEventsForFrame;
-    
-    // Version 1.
-    WKBundlePageDidLayoutForFrameCallback                                   didLayoutForFrame;
-    void *                                                                  didNewFirstVisuallyNonEmptyLayout_unavailable;
-    WKBundlePageDidDetectXSSForFrameCallback                                didDetectXSSForFrame;
-    WKBundlePageShouldGoToBackForwardListItemCallback                       shouldGoToBackForwardListItem;
-    WKBundlePageGlobalObjectIsAvailableForFrameCallback                     globalObjectIsAvailableForFrame;
-    WKBundlePageWillDisconnectDOMWindowExtensionFromGlobalObjectCallback    willDisconnectDOMWindowExtensionFromGlobalObject;
-    WKBundlePageDidReconnectDOMWindowExtensionToGlobalObjectCallback        didReconnectDOMWindowExtensionToGlobalObject;
-    WKBundlePageWillDestroyGlobalObjectForDOMWindowExtensionCallback        willDestroyGlobalObjectForDOMWindowExtension;
-    
-    // Version 2
-    WKBundlePageDidFinishProgressCallback                                   didFinishProgress;
-    WKBundlePageShouldForceUniversalAccessFromLocalURLCallback              shouldForceUniversalAccessFromLocalURL;
-    
-    // Version 3
-    void *                                                                  didReceiveIntentForFrame_unavailable;
-    void *                                                                  registerIntentServiceForFrame_unavailable;
-    
-    // Version 4
-    WKBundlePageDidLayoutCallback                                           didLayout;
-    
-    // Version 5
-    WKBundlePageFeaturesUsedInPageCallback                                  featuresUsedInPage;
-    
-    // Version 6
-    WKBundlePageWillLoadURLRequestCallback                                  willLoadURLRequest;
-    WKBundlePageWillLoadDataRequestCallback                                 willLoadDataRequest;
-    
-    // Version 7
-    void *                                                                  willDestroyFrame_unavailable;
-    
-    // Version 8
-    WKBundlePageUserAgentForURLCallback                                     userAgentForURL;
-
-    // Version 9
-    WKBundlePageShouldUseContentExtensionsForURLCallback                    shouldUseContentExtensionsForURL;
-} WKBundlePageLoaderClientV9;
-
-
 #endif // WKBundlePageLoaderClient_h

Modified: trunk/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp (205486 => 205487)


--- trunk/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp	2016-09-06 16:45:38 UTC (rev 205486)
+++ trunk/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.cpp	2016-09-06 16:55:13 UTC (rev 205487)
@@ -356,15 +356,5 @@
     WKStringRef userAgent = m_client.userAgentForURL(toAPI(frame), toAPI(url), m_client.base.clientInfo);
     return toImpl(userAgent);
 }
-
-#if ENABLE(CONTENT_EXTENSIONS)
-bool InjectedBundlePageLoaderClient::shouldUseContentExtensionsForURL(WebPage* page, API::URL* url) const
-{
-    if (!m_client.shouldUseContentExtensionsForURL)
-        return true;
-
-    return m_client.shouldUseContentExtensionsForURL(toAPI(page), toAPI(url), m_client.base.clientInfo);
-}
-#endif
-
+    
 } // namespace WebKit

Modified: trunk/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h (205486 => 205487)


--- trunk/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h	2016-09-06 16:45:38 UTC (rev 205486)
+++ trunk/Source/WebKit2/WebProcess/InjectedBundle/InjectedBundlePageLoaderClient.h	2016-09-06 16:55:13 UTC (rev 205487)
@@ -40,7 +40,7 @@
 class Object;
 
 template<> struct ClientTraits<WKBundlePageLoaderClientBase> {
-    typedef std::tuple<WKBundlePageLoaderClientV0, WKBundlePageLoaderClientV1, WKBundlePageLoaderClientV2, WKBundlePageLoaderClientV3, WKBundlePageLoaderClientV4, WKBundlePageLoaderClientV5, WKBundlePageLoaderClientV6, WKBundlePageLoaderClientV7, WKBundlePageLoaderClientV8, WKBundlePageLoaderClientV9> Versions;
+    typedef std::tuple<WKBundlePageLoaderClientV0, WKBundlePageLoaderClientV1, WKBundlePageLoaderClientV2, WKBundlePageLoaderClientV3, WKBundlePageLoaderClientV4, WKBundlePageLoaderClientV5, WKBundlePageLoaderClientV6, WKBundlePageLoaderClientV7, WKBundlePageLoaderClientV8> Versions;
 };
 }
 
@@ -102,10 +102,6 @@
 
     void willDestroyFrame(WebPage*, WebFrame*);
     API::String* userAgentForURL(WebFrame*, API::URL*) const;
-
-#if ENABLE(CONTENT_EXTENSIONS)
-    bool shouldUseContentExtensionsForURL(WebPage*, API::URL*) const;
-#endif
 };
 
 } // namespace WebKit

Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp (205486 => 205487)


--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp	2016-09-06 16:45:38 UTC (rev 205486)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.cpp	2016-09-06 16:55:13 UTC (rev 205487)
@@ -635,18 +635,6 @@
     }
 }
 
-#if ENABLE(CONTENT_EXTENSIONS)
-bool WebFrameLoaderClient::shouldUseContentExtensionsForURL(const URL& url)
-{
-    WebPage* webPage = m_frame->page();
-    if (!webPage)
-        return true;
-
-    // Just send the request to the injected bundle client because we don't have time to wait for a response from the UI Process.
-    return webPage->injectedBundleLoaderClient().shouldUseContentExtensionsForURL(webPage, API::URL::create(url.string()).ptr());
-}
-#endif
-
 Frame* WebFrameLoaderClient::dispatchCreatePage(const NavigationAction& navigationAction)
 {
     WebPage* webPage = m_frame->page();

Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.h (205486 => 205487)


--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.h	2016-09-06 16:45:38 UTC (rev 205486)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebFrameLoaderClient.h	2016-09-06 16:55:13 UTC (rev 205487)
@@ -105,10 +105,6 @@
     void dispatchDidReachLayoutMilestone(WebCore::LayoutMilestones) override;
     void dispatchDidLayout() override;
 
-#if ENABLE(CONTENT_EXTENSIONS)
-    bool shouldUseContentExtensionsForURL(const WebCore::URL&) override;
-#endif
-
     WebCore::Frame* dispatchCreatePage(const WebCore::NavigationAction&) override;
     void dispatchShow() override;
     
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to