Title: [188693] trunk/Source
Revision
188693
Author
[email protected]
Date
2015-08-20 11:46:19 -0700 (Thu, 20 Aug 2015)

Log Message

Standalone image documents should send their size to the UIClient just like 
standalone media documents
https://bugs.webkit.org/show_bug.cgi?id=148195
-and corresponding-
rdar://problem/21951253

Reviewed by Tim Horton.

This patch re-names mediaDocumentNaturalSizeChanged() to 
imageOrMediaDocumentSizeChanged(), and, as the new name implies, uses the 
function for both media documents and images.

Source/WebCore:

* html/ImageDocument.cpp:
(WebCore::ImageDocument::imageUpdated):
* html/MediaDocument.cpp:
(WebCore::MediaDocument::mediaElementNaturalSizeChanged):
* page/ChromeClient.h:

Source/WebKit2:

* UIProcess/API/APIUIClient.h:
(API::UIClient::didClickAutoFillButton):
(API::UIClient::imageOrMediaDocumentSizeChanged):
(API::UIClient::mediaDocumentNaturalSizeChanged): Deleted.
* UIProcess/API/Cocoa/WKUIDelegatePrivate.h:

The WKWebView and PageClient implementations of this function were actually 
not being used, so this patch removes them and just keeps the UIClient stuff.
* UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView performDragOperation:]):
(-[WKWebView _mediaDocumentNaturalSizeChanged:]): Deleted.
* UIProcess/API/Cocoa/WKWebViewInternal.h:

More re-naming.
* UIProcess/Cocoa/UIDelegate.h:
* UIProcess/Cocoa/UIDelegate.mm:
(WebKit::UIDelegate::setDelegate):
(WebKit::UIDelegate::UIClient::UIClient):
(WebKit::UIDelegate::UIClient::didNotHandleTapAsClick):
(WebKit::UIDelegate::UIClient::imageOrMediaDocumentSizeChanged):
(WebKit::UIDelegate::UIClient::mediaDocumentNaturalSizeChanged): Deleted.
* UIProcess/PageClient.h:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::installViewStateChangeCompletionHandler):
(WebKit::WebPageProxy::imageOrMediaDocumentSizeChanged):
(WebKit::WebPageProxy::setShouldDispatchFakeMouseMoveEvents):
(WebKit::WebPageProxy::mediaDocumentNaturalSizeChanged): Deleted.
* UIProcess/WebPageProxy.h:
(WebKit::WebPageProxy::useFixedLayoutDidChange):
(WebKit::WebPageProxy::fixedLayoutSizeDidChange):
* UIProcess/WebPageProxy.messages.in:

The WKWebView and PageClient implementations of this function were actually 
not being used, so this patch removes them and just keeps the UIClient stuff.
* UIProcess/ios/PageClientImplIOS.h:
* UIProcess/ios/PageClientImplIOS.mm:
(WebKit::PageClientImpl::mediaDocumentNaturalSizeChanged): Deleted.
* UIProcess/mac/PageClientImpl.h:
* UIProcess/mac/PageClientImpl.mm:
(WebKit::PageClientImpl::mediaDocumentNaturalSizeChanged): Deleted.

More re-naming.
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::imageOrMediaDocumentSizeChanged):
(WebKit::WebChromeClient::mediaDocumentNaturalSizeChanged): Deleted.
* WebProcess/WebCoreSupport/WebChromeClient.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::imageOrMediaDocumentSizeChanged):
(WebKit::WebPage::mediaDocumentNaturalSizeChanged): Deleted.
* WebProcess/WebPage/WebPage.h:

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (188692 => 188693)


--- trunk/Source/WebCore/ChangeLog	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebCore/ChangeLog	2015-08-20 18:46:19 UTC (rev 188693)
@@ -1,3 +1,23 @@
+2015-08-20  Beth Dakin  <[email protected]>
+
+        Standalone image documents should send their size to the UIClient just like 
+        standalone media documents
+        https://bugs.webkit.org/show_bug.cgi?id=148195
+        -and corresponding-
+        rdar://problem/21951253
+
+        Reviewed by Tim Horton.
+
+        This patch re-names mediaDocumentNaturalSizeChanged() to 
+        imageOrMediaDocumentSizeChanged(), and, as the new name implies, uses the 
+        function for both media documents and images.
+
+        * html/ImageDocument.cpp:
+        (WebCore::ImageDocument::imageUpdated):
+        * html/MediaDocument.cpp:
+        (WebCore::MediaDocument::mediaElementNaturalSizeChanged):
+        * page/ChromeClient.h:
+
 2015-08-20  Simon Fraser  <[email protected]>
 
         Add myself as the will-change contact.

Modified: trunk/Source/WebCore/html/ImageDocument.cpp (188692 => 188693)


--- trunk/Source/WebCore/html/ImageDocument.cpp	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebCore/html/ImageDocument.cpp	2015-08-20 18:46:19 UTC (rev 188693)
@@ -27,6 +27,7 @@
 
 #include "CachedImage.h"
 #include "Chrome.h"
+#include "ChromeClient.h"
 #include "DocumentLoader.h"
 #include "EventListener.h"
 #include "EventNames.h"
@@ -264,6 +265,8 @@
         FloatSize screenSize = page()->chrome().screenSize();
         if (imageSize.width() > screenSize.width())
             processViewport(String::format("width=%u", static_cast<unsigned>(imageSize.width().toInt())), ViewportArguments::ImageDocument);
+        if (page())
+            page()->chrome().client().imageOrMediaDocumentSizeChanged(IntSize(imageSize.width(), imageSize.height()));
 #else
         // Call windowSizeChanged for its side effect of sizing the image.
         windowSizeChanged();

Modified: trunk/Source/WebCore/html/MediaDocument.cpp (188692 => 188693)


--- trunk/Source/WebCore/html/MediaDocument.cpp	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebCore/html/MediaDocument.cpp	2015-08-20 18:46:19 UTC (rev 188693)
@@ -270,7 +270,7 @@
         return;
 
     if (page())
-        page()->chrome().client().mediaDocumentNaturalSizeChanged(newSize);
+        page()->chrome().client().imageOrMediaDocumentSizeChanged(newSize);
 }
 
 }

Modified: trunk/Source/WebCore/page/ChromeClient.h (188692 => 188693)


--- trunk/Source/WebCore/page/ChromeClient.h	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebCore/page/ChromeClient.h	2015-08-20 18:46:19 UTC (rev 188693)
@@ -456,7 +456,7 @@
 #endif
 
 #if ENABLE(VIDEO)
-    virtual void mediaDocumentNaturalSizeChanged(const WebCore::IntSize&) { }
+    virtual void imageOrMediaDocumentSizeChanged(const WebCore::IntSize&) { }
 #if USE(GSTREAMER)
     virtual void requestInstallMissingMediaPlugins(const String& /*details*/, const String& /*description*/, MediaPlayerRequestInstallMissingPluginsCallback&) { };
 #endif

Modified: trunk/Source/WebKit2/ChangeLog (188692 => 188693)


--- trunk/Source/WebKit2/ChangeLog	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/ChangeLog	2015-08-20 18:46:19 UTC (rev 188693)
@@ -1,3 +1,68 @@
+2015-08-20  Beth Dakin  <[email protected]>
+
+        Standalone image documents should send their size to the UIClient just like 
+        standalone media documents
+        https://bugs.webkit.org/show_bug.cgi?id=148195
+        -and corresponding-
+        rdar://problem/21951253
+
+        Reviewed by Tim Horton.
+
+        This patch re-names mediaDocumentNaturalSizeChanged() to 
+        imageOrMediaDocumentSizeChanged(), and, as the new name implies, uses the 
+        function for both media documents and images.
+
+        * UIProcess/API/APIUIClient.h:
+        (API::UIClient::didClickAutoFillButton):
+        (API::UIClient::imageOrMediaDocumentSizeChanged):
+        (API::UIClient::mediaDocumentNaturalSizeChanged): Deleted.
+        * UIProcess/API/Cocoa/WKUIDelegatePrivate.h:
+
+        The WKWebView and PageClient implementations of this function were actually 
+        not being used, so this patch removes them and just keeps the UIClient stuff.
+        * UIProcess/API/Cocoa/WKWebView.mm:
+        (-[WKWebView performDragOperation:]):
+        (-[WKWebView _mediaDocumentNaturalSizeChanged:]): Deleted.
+        * UIProcess/API/Cocoa/WKWebViewInternal.h:
+
+        More re-naming.
+        * UIProcess/Cocoa/UIDelegate.h:
+        * UIProcess/Cocoa/UIDelegate.mm:
+        (WebKit::UIDelegate::setDelegate):
+        (WebKit::UIDelegate::UIClient::UIClient):
+        (WebKit::UIDelegate::UIClient::didNotHandleTapAsClick):
+        (WebKit::UIDelegate::UIClient::imageOrMediaDocumentSizeChanged):
+        (WebKit::UIDelegate::UIClient::mediaDocumentNaturalSizeChanged): Deleted.
+        * UIProcess/PageClient.h:
+        * UIProcess/WebPageProxy.cpp:
+        (WebKit::WebPageProxy::installViewStateChangeCompletionHandler):
+        (WebKit::WebPageProxy::imageOrMediaDocumentSizeChanged):
+        (WebKit::WebPageProxy::setShouldDispatchFakeMouseMoveEvents):
+        (WebKit::WebPageProxy::mediaDocumentNaturalSizeChanged): Deleted.
+        * UIProcess/WebPageProxy.h:
+        (WebKit::WebPageProxy::useFixedLayoutDidChange):
+        (WebKit::WebPageProxy::fixedLayoutSizeDidChange):
+        * UIProcess/WebPageProxy.messages.in:
+
+        The WKWebView and PageClient implementations of this function were actually 
+        not being used, so this patch removes them and just keeps the UIClient stuff.
+        * UIProcess/ios/PageClientImplIOS.h:
+        * UIProcess/ios/PageClientImplIOS.mm:
+        (WebKit::PageClientImpl::mediaDocumentNaturalSizeChanged): Deleted.
+        * UIProcess/mac/PageClientImpl.h:
+        * UIProcess/mac/PageClientImpl.mm:
+        (WebKit::PageClientImpl::mediaDocumentNaturalSizeChanged): Deleted.
+
+        More re-naming.
+        * WebProcess/WebCoreSupport/WebChromeClient.cpp:
+        (WebKit::WebChromeClient::imageOrMediaDocumentSizeChanged):
+        (WebKit::WebChromeClient::mediaDocumentNaturalSizeChanged): Deleted.
+        * WebProcess/WebCoreSupport/WebChromeClient.h:
+        * WebProcess/WebPage/WebPage.cpp:
+        (WebKit::WebPage::imageOrMediaDocumentSizeChanged):
+        (WebKit::WebPage::mediaDocumentNaturalSizeChanged): Deleted.
+        * WebProcess/WebPage/WebPage.h:
+
 2015-08-19  Eric Carlson  <[email protected]>
 
         Remove ENABLE_WEBVTT_REGIONS

Modified: trunk/Source/WebKit2/UIProcess/API/APIUIClient.h (188692 => 188693)


--- trunk/Source/WebKit2/UIProcess/API/APIUIClient.h	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/API/APIUIClient.h	2015-08-20 18:46:19 UTC (rev 188693)
@@ -168,9 +168,7 @@
 
     virtual void didClickAutoFillButton(WebKit::WebPageProxy&, API::Object*) { }
 
-#if ENABLE(VIDEO)
-    virtual void mediaDocumentNaturalSizeChanged(const WebCore::IntSize&) { }
-#endif
+    virtual void imageOrMediaDocumentSizeChanged(const WebCore::IntSize&) { }
 };
 
 } // namespace API

Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKUIDelegatePrivate.h (188692 => 188693)


--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKUIDelegatePrivate.h	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKUIDelegatePrivate.h	2015-08-20 18:46:19 UTC (rev 188693)
@@ -54,8 +54,9 @@
 - (void)_webViewFullscreenMayReturnToInline:(WKWebView *)webView;
 - (void)_webViewDidEnterFullscreen:(WKWebView *)webView WK_AVAILABLE(WK_MAC_TBA, 8_3);
 - (void)_webViewDidExitFullscreen:(WKWebView *)webView WK_AVAILABLE(WK_MAC_TBA, 8_3);
-- (void)_webView:(WKWebView *)webView mediaDocumentNaturalSizeChanged:(CGSize)size;
 
+- (void)_webView:(WKWebView *)webView imageOrMediaDocumentSizeChanged:(CGSize)size WK_AVAILABLE(WK_MAC_TBA, WK_IOS_TBA);
+
 #if TARGET_OS_IPHONE
 - (BOOL)_webView:(WKWebView *)webView shouldIncludeAppLinkActionsForElement:(_WKActivatedElementInfo *)element WK_AVAILABLE(NA, WK_IOS_TBA);
 - (NSArray *)_webView:(WKWebView *)webView actionsForElement:(_WKActivatedElementInfo *)element defaultActions:(WK_ARRAY(_WKElementAction *) *)defaultActions;

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


--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebView.mm	2015-08-20 18:46:19 UTC (rev 188693)
@@ -1897,15 +1897,6 @@
 }
 #endif // PLATFORM(MAC)
 
-#if ENABLE(VIDEO)
-- (void)_mediaDocumentNaturalSizeChanged:(NSSize)newSize
-{
-    id <WKUIDelegatePrivate> uiDelegate = static_cast<id <WKUIDelegatePrivate>>([self UIDelegate]);
-    if ([uiDelegate respondsToSelector:@selector(_webView:mediaDocumentNaturalSizeChanged:)])
-        [uiDelegate _webView:self mediaDocumentNaturalSizeChanged:newSize];
-}
-#endif
-
 @end
 
 @implementation WKWebView (WKPrivate)

Modified: trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewInternal.h (188692 => 188693)


--- trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewInternal.h	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/API/Cocoa/WKWebViewInternal.h	2015-08-20 18:46:19 UTC (rev 188693)
@@ -116,10 +116,6 @@
 
 - (WKPageRef)_pageForTesting;
 
-#if ENABLE(VIDEO)
-- (void)_mediaDocumentNaturalSizeChanged:(CGSize)newSize;
-#endif
-
 @end
 
 WKWebView* fromWebPageProxy(WebKit::WebPageProxy&);

Modified: trunk/Source/WebKit2/UIProcess/Cocoa/UIDelegate.h (188692 => 188693)


--- trunk/Source/WebKit2/UIProcess/Cocoa/UIDelegate.h	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/Cocoa/UIDelegate.h	2015-08-20 18:46:19 UTC (rev 188693)
@@ -76,9 +76,7 @@
         virtual RetainPtr<NSArray> actionsForElement(_WKActivatedElementInfo *, RetainPtr<NSArray> defaultActions) override;
         virtual void didNotHandleTapAsClick(const WebCore::IntPoint&) override;
 #endif
-#if ENABLE(VIDEO)
-        virtual void mediaDocumentNaturalSizeChanged(const WebCore::IntSize&) override;
-#endif
+        virtual void imageOrMediaDocumentSizeChanged(const WebCore::IntSize&) override;
 
         UIDelegate& m_uiDelegate;
     };
@@ -106,9 +104,7 @@
         bool webViewActionsForElementDefaultActions : 1;
         bool webViewDidNotHandleTapAsClickAtPoint : 1;
 #endif
-#if ENABLE(VIDEO)
-        bool webViewMediaDocumentNaturalSizeChanged : 1;
-#endif
+        bool webViewImageOrMediaDocumentSizeChanged : 1;
     } m_delegateMethods;
 };
 

Modified: trunk/Source/WebKit2/UIProcess/Cocoa/UIDelegate.mm (188692 => 188693)


--- trunk/Source/WebKit2/UIProcess/Cocoa/UIDelegate.mm	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/Cocoa/UIDelegate.mm	2015-08-20 18:46:19 UTC (rev 188693)
@@ -85,9 +85,7 @@
     m_delegateMethods.webViewActionsForElementDefaultActions = [delegate respondsToSelector:@selector(_webView:actionsForElement:defaultActions:)];
     m_delegateMethods.webViewDidNotHandleTapAsClickAtPoint = [delegate respondsToSelector:@selector(_webView:didNotHandleTapAsClickAtPoint:)];
 #endif
-#if ENABLE(VIDEO)
-    m_delegateMethods.webViewMediaDocumentNaturalSizeChanged = [delegate respondsToSelector:@selector(_webView:mediaDocumentNaturalSizeChanged:)];
-#endif
+    m_delegateMethods.webViewImageOrMediaDocumentSizeChanged = [delegate respondsToSelector:@selector(_webView:imageOrMediaDocumentSizeChanged:)];
 }
 
 UIDelegate::UIClient::UIClient(UIDelegate& uiDelegate)
@@ -343,19 +341,17 @@
 }
 #endif
 
-#if ENABLE(VIDEO)
-void UIDelegate::UIClient::mediaDocumentNaturalSizeChanged(const WebCore::IntSize& newSize)
+void UIDelegate::UIClient::imageOrMediaDocumentSizeChanged(const WebCore::IntSize& newSize)
 {
-    if (!m_uiDelegate.m_delegateMethods.webViewMediaDocumentNaturalSizeChanged)
+    if (!m_uiDelegate.m_delegateMethods.webViewImageOrMediaDocumentSizeChanged)
         return;
 
     auto delegate = m_uiDelegate.m_delegate.get();
     if (!delegate)
         return;
 
-    [static_cast<id <WKUIDelegatePrivate>>(delegate) _webView:m_uiDelegate.m_webView mediaDocumentNaturalSizeChanged:newSize];
+    [static_cast<id <WKUIDelegatePrivate>>(delegate) _webView:m_uiDelegate.m_webView imageOrMediaDocumentSizeChanged:newSize];
 }
-#endif
 
 } // namespace WebKit
 

Modified: trunk/Source/WebKit2/UIProcess/PageClient.h (188692 => 188693)


--- trunk/Source/WebKit2/UIProcess/PageClient.h	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/PageClient.h	2015-08-20 18:46:19 UTC (rev 188693)
@@ -337,10 +337,6 @@
     virtual WebCore::WebMediaSessionManager& mediaSessionManager() = 0;
 #endif
 
-#if ENABLE(VIDEO)
-    virtual void mediaDocumentNaturalSizeChanged(const WebCore::IntSize&) = 0;
-#endif
-
     virtual void refView() = 0;
     virtual void derefView() = 0;
 

Modified: trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp (188692 => 188693)


--- trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp	2015-08-20 18:46:19 UTC (rev 188693)
@@ -6046,12 +6046,10 @@
 }
 #endif
 
-#if ENABLE(VIDEO)
-void WebPageProxy::mediaDocumentNaturalSizeChanged(const WebCore::IntSize& newSize)
+void WebPageProxy::imageOrMediaDocumentSizeChanged(const WebCore::IntSize& newSize)
 {
-    m_uiClient->mediaDocumentNaturalSizeChanged(newSize);
+    m_uiClient->imageOrMediaDocumentSizeChanged(newSize);
 }
-#endif
 
 void WebPageProxy::setShouldDispatchFakeMouseMoveEvents(bool shouldDispatchFakeMouseMoveEvents)
 {

Modified: trunk/Source/WebKit2/UIProcess/WebPageProxy.h (188692 => 188693)


--- trunk/Source/WebKit2/UIProcess/WebPageProxy.h	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/WebPageProxy.h	2015-08-20 18:46:19 UTC (rev 188693)
@@ -1455,8 +1455,8 @@
     void useFixedLayoutDidChange(bool useFixedLayout) { m_useFixedLayout = useFixedLayout; }
     void fixedLayoutSizeDidChange(WebCore::IntSize fixedLayoutSize) { m_fixedLayoutSize = fixedLayoutSize; }
 
+    void imageOrMediaDocumentSizeChanged(const WebCore::IntSize&);
 #if ENABLE(VIDEO)
-    void mediaDocumentNaturalSizeChanged(const WebCore::IntSize&);
 #if USE(GSTREAMER)
     void requestInstallMissingMediaPlugins(const String& details, const String& description);
 #endif

Modified: trunk/Source/WebKit2/UIProcess/WebPageProxy.messages.in (188692 => 188693)


--- trunk/Source/WebKit2/UIProcess/WebPageProxy.messages.in	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/WebPageProxy.messages.in	2015-08-20 18:46:19 UTC (rev 188693)
@@ -445,9 +445,7 @@
     PlaybackTargetPickerClientStateDidChange(uint64_t contextId, unsigned mediaState)
 #endif
 
-#if ENABLE(VIDEO)
-    MediaDocumentNaturalSizeChanged(WebCore::IntSize newSize)
-#endif
+    ImageOrMediaDocumentSizeChanged(WebCore::IntSize newSize)
 
     UseFixedLayoutDidChange(bool useFixedLayout)
     FixedLayoutSizeDidChange(WebCore::IntSize fixedLayoutSize)

Modified: trunk/Source/WebKit2/UIProcess/ios/PageClientImplIOS.h (188692 => 188693)


--- trunk/Source/WebKit2/UIProcess/ios/PageClientImplIOS.h	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/ios/PageClientImplIOS.h	2015-08-20 18:46:19 UTC (rev 188693)
@@ -186,10 +186,6 @@
 
     virtual void didChangeBackgroundColor() override;
 
-#if ENABLE(VIDEO)
-    virtual void mediaDocumentNaturalSizeChanged(const WebCore::IntSize&) override;
-#endif
-
     virtual void refView() override;
     virtual void derefView() override;
 

Modified: trunk/Source/WebKit2/UIProcess/ios/PageClientImplIOS.mm (188692 => 188693)


--- trunk/Source/WebKit2/UIProcess/ios/PageClientImplIOS.mm	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/ios/PageClientImplIOS.mm	2015-08-20 18:46:19 UTC (rev 188693)
@@ -739,14 +739,6 @@
     [m_webView _updateScrollViewBackground];
 }
 
-#if ENABLE(VIDEO)
-void PageClientImpl::mediaDocumentNaturalSizeChanged(const IntSize& newSize)
-{
-    [m_webView _mediaDocumentNaturalSizeChanged:newSize];
-}
-#endif
-
-
 void PageClientImpl::refView()
 {
     [m_contentView retain];

Modified: trunk/Source/WebKit2/UIProcess/mac/PageClientImpl.h (188692 => 188693)


--- trunk/Source/WebKit2/UIProcess/mac/PageClientImpl.h	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/mac/PageClientImpl.h	2015-08-20 18:46:19 UTC (rev 188693)
@@ -203,10 +203,6 @@
 
     virtual void didChangeBackgroundColor() override;
 
-#if ENABLE(VIDEO)
-    virtual void mediaDocumentNaturalSizeChanged(const WebCore::IntSize&) override;
-#endif
-
     WKView *m_wkView;
     WKWebView *m_webView;
     RetainPtr<WKEditorUndoTargetObjC> m_undoTarget;

Modified: trunk/Source/WebKit2/UIProcess/mac/PageClientImpl.mm (188692 => 188693)


--- trunk/Source/WebKit2/UIProcess/mac/PageClientImpl.mm	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/UIProcess/mac/PageClientImpl.mm	2015-08-20 18:46:19 UTC (rev 188693)
@@ -845,15 +845,6 @@
 }
 #endif
 
-#if ENABLE(VIDEO)
-void PageClientImpl::mediaDocumentNaturalSizeChanged(const IntSize& newSize)
-{
-#if WK_API_ENABLED
-    [m_webView _mediaDocumentNaturalSizeChanged:newSize];
-#endif
-}
-#endif
-
 void PageClientImpl::refView()
 {
     CFRetain(m_wkView);

Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp (188692 => 188693)


--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp	2015-08-20 18:46:19 UTC (rev 188693)
@@ -1163,12 +1163,12 @@
 }
 #endif
 
-#if ENABLE(VIDEO)
-void WebChromeClient::mediaDocumentNaturalSizeChanged(const WebCore::IntSize& newSize)
+void WebChromeClient::imageOrMediaDocumentSizeChanged(const WebCore::IntSize& newSize)
 {
-    m_page->mediaDocumentNaturalSizeChanged(newSize);
+    m_page->imageOrMediaDocumentSizeChanged(newSize);
 }
 
+#if ENABLE(VIDEO)
 #if USE(GSTREAMER)
 void WebChromeClient::requestInstallMissingMediaPlugins(const String& details, const String& description, WebCore::MediaPlayerRequestInstallMissingPluginsCallback& callback)
 {

Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h (188692 => 188693)


--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h	2015-08-20 18:46:19 UTC (rev 188693)
@@ -325,8 +325,8 @@
     virtual void playbackTargetPickerClientStateDidChange(uint64_t, WebCore::MediaProducer::MediaStateFlags) override;
 #endif
 
+    virtual void imageOrMediaDocumentSizeChanged(const WebCore::IntSize&) override;
 #if ENABLE(VIDEO)
-    virtual void mediaDocumentNaturalSizeChanged(const WebCore::IntSize&) override;
 #if USE(GSTREAMER)
     virtual void requestInstallMissingMediaPlugins(const String& /*details*/, const String& /*description*/, WebCore::MediaPlayerRequestInstallMissingPluginsCallback&) override;
 #endif

Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp (188692 => 188693)


--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp	2015-08-20 18:46:19 UTC (rev 188693)
@@ -5052,11 +5052,9 @@
     m_page->setUserContentExtensionsEnabled(userContentExtensionsEnabled);
 }
 
-#if ENABLE(VIDEO)
-void WebPage::mediaDocumentNaturalSizeChanged(const IntSize& newSize)
+void WebPage::imageOrMediaDocumentSizeChanged(const IntSize& newSize)
 {
-    send(Messages::WebPageProxy::MediaDocumentNaturalSizeChanged(newSize));
+    send(Messages::WebPageProxy::ImageOrMediaDocumentSizeChanged(newSize));
 }
-#endif
 
 } // namespace WebKit

Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h (188692 => 188693)


--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h	2015-08-20 18:43:49 UTC (rev 188692)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h	2015-08-20 18:46:19 UTC (rev 188693)
@@ -906,8 +906,8 @@
     void setInputMethodState(bool);
 #endif
 
+    void imageOrMediaDocumentSizeChanged(const WebCore::IntSize&);
 #if ENABLE(VIDEO)
-    void mediaDocumentNaturalSizeChanged(const WebCore::IntSize&);
 #if USE(GSTREAMER)
     void requestInstallMissingMediaPlugins(const String& details, const String& description, WebCore::MediaPlayerRequestInstallMissingPluginsCallback&);
 #endif
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to