Unreviewed, rolling out r135819.
authorossy@webkit.org <ossy@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 27 Nov 2012 11:31:45 +0000 (11:31 +0000)
committerossy@webkit.org <ossy@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 27 Nov 2012 11:31:45 +0000 (11:31 +0000)
http://trac.webkit.org/changeset/135819
https://bugs.webkit.org/show_bug.cgi?id=103388

It broke many tests on Qt and EFL WK2 platforms (Requested by
Ossy on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2012-11-27

* Shared/WebPageCreationParameters.cpp:
(WebKit::WebPageCreationParameters::encode):
(WebKit::WebPageCreationParameters::decode):
* Shared/WebPageCreationParameters.h:
(WebPageCreationParameters):
* UIProcess/API/C/WKPage.cpp:
(WKPageCopyRelatedPages):
* UIProcess/API/C/WKPagePrivate.h:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::WebPageProxy):
(WebKit::WebPageProxy::creationParameters):
* UIProcess/WebPageProxy.h:
(WebPageProxy):
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::WebPage):
(WebKit::WebPage::setIsInWindow):
* WebProcess/WebPage/WebPage.h:
(WebPage):
* WebProcess/WebPage/WebPage.messages.in:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@135844 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebKit2/ChangeLog
Source/WebKit2/Shared/WebPageCreationParameters.cpp
Source/WebKit2/Shared/WebPageCreationParameters.h
Source/WebKit2/UIProcess/API/C/WKPage.cpp
Source/WebKit2/UIProcess/API/C/WKPagePrivate.h
Source/WebKit2/UIProcess/WebPageProxy.cpp
Source/WebKit2/UIProcess/WebPageProxy.h
Source/WebKit2/WebProcess/WebPage/WebPage.cpp
Source/WebKit2/WebProcess/WebPage/WebPage.h
Source/WebKit2/WebProcess/WebPage/WebPage.messages.in

index 46034bf2819c7c1db5d373cf68efe8dbece35f8d..c0df159162afc787d7bb3cc3485762897cab04ae 100644 (file)
@@ -1,3 +1,32 @@
+2012-11-27  Sheriff Bot  <webkit.review.bot@gmail.com>
+
+        Unreviewed, rolling out r135819.
+        http://trac.webkit.org/changeset/135819
+        https://bugs.webkit.org/show_bug.cgi?id=103388
+
+        It broke many tests on Qt and EFL WK2 platforms (Requested by
+        Ossy on #webkit).
+
+        * Shared/WebPageCreationParameters.cpp:
+        (WebKit::WebPageCreationParameters::encode):
+        (WebKit::WebPageCreationParameters::decode):
+        * Shared/WebPageCreationParameters.h:
+        (WebPageCreationParameters):
+        * UIProcess/API/C/WKPage.cpp:
+        (WKPageCopyRelatedPages):
+        * UIProcess/API/C/WKPagePrivate.h:
+        * UIProcess/WebPageProxy.cpp:
+        (WebKit::WebPageProxy::WebPageProxy):
+        (WebKit::WebPageProxy::creationParameters):
+        * UIProcess/WebPageProxy.h:
+        (WebPageProxy):
+        * WebProcess/WebPage/WebPage.cpp:
+        (WebKit::WebPage::WebPage):
+        (WebKit::WebPage::setIsInWindow):
+        * WebProcess/WebPage/WebPage.h:
+        (WebPage):
+        * WebProcess/WebPage/WebPage.messages.in:
+
 2012-11-27  Kyungjin Kim  <gen.kim@samsung.com>
 
         [WK2] Expose Accelerated2dCanvas flag set and get in WebKit2
index 22e28849c4b88baeafa890b72e8fda94f8f4b5cc..2a4afd938c6d5172bacfa6201d4a52bc4383e2d2 100644 (file)
@@ -57,7 +57,6 @@ void WebPageCreationParameters::encode(CoreIPC::ArgumentEncoder& encoder) const
     encoder << canRunModal;
     encoder << deviceScaleFactor;
     encoder << mediaVolume;
-    encoder << mayStartMediaWhenInWindow;
 
 #if PLATFORM(MAC)
     encoder << isSmartInsertDeleteEnabled;
@@ -120,8 +119,6 @@ bool WebPageCreationParameters::decode(CoreIPC::ArgumentDecoder* decoder, WebPag
         return false;
     if (!decoder->decode(parameters.mediaVolume))
         return false;
-    if (!decoder->decode(parameters.mayStartMediaWhenInWindow))
-        return false;
 
 #if PLATFORM(MAC)
     if (!decoder->decode(parameters.isSmartInsertDeleteEnabled))
index 7a580f3e38e6a21a5134dd3dc3688283ef5256cd..214c04c50482eca8905c3d19d717af0f8991e86e 100644 (file)
@@ -85,7 +85,6 @@ struct WebPageCreationParameters {
     float deviceScaleFactor;
     
     float mediaVolume;
-    bool mayStartMediaWhenInWindow;
 
 #if PLATFORM(MAC)
     bool isSmartInsertDeleteEnabled;
index ef871bb4c6ad185f2f751bf980228f8ea3f1d224..259bca727eeee3e93025add0c22d4d5bdbd73ebf 100644 (file)
@@ -764,8 +764,3 @@ WKArrayRef WKPageCopyRelatedPages(WKPageRef pageRef)
 {
     return toAPI(toImpl(pageRef)->relatedPages().leakRef());
 }
-
-void WKPageSetMayStartMediaWhenInWindow(WKPageRef pageRef, bool mayStartMedia)
-{
-    toImpl(pageRef)->setMayStartMediaWhenInWindow(mayStartMedia);
-}
index 4f0e85ba56dbec7a677acfc1e41815fd2ebdd304..3a9de69afd6359abc06f527cf524e39afc6d7ec9 100644 (file)
@@ -93,7 +93,6 @@ WK_EXPORT WKImageRef WKPageCreateSnapshotOfVisibleContent(WKPageRef page);
 WK_EXPORT void WKPageSetShouldSendEventsSynchronously(WKPageRef page, bool sync);
 
 WK_EXPORT void WKPageSetMediaVolume(WKPageRef page, float volume);
-WK_EXPORT void WKPageSetMayStartMediaWhenInWindow(WKPageRef page, bool mayStartMedia);
 
 WK_EXPORT WKArrayRef WKPageCopyRelatedPages(WKPageRef page);
 
index 734cad3be0a94831c828af02216e2ef4fb5b90f3..192c5cb7bb7a39560b0a0b61b7483b8dd3980617 100644 (file)
@@ -234,7 +234,6 @@ WebPageProxy::WebPageProxy(PageClient* pageClient, PassRefPtr<WebProcessProxy> p
     , m_shouldSendEventsSynchronously(false)
     , m_suppressVisibilityUpdates(false)
     , m_mediaVolume(1)
-    , m_mayStartMediaWhenInWindow(true)
 #if ENABLE(PAGE_VISIBILITY_API)
     , m_visibilityState(PageVisibilityStateVisible)
 #endif
@@ -2783,19 +2782,6 @@ void WebPageProxy::setMediaVolume(float volume)
     m_process->send(Messages::WebPage::SetMediaVolume(volume), m_pageID);    
 }
 
-void WebPageProxy::setMayStartMediaWhenInWindow(bool mayStartMedia)
-{
-    if (mayStartMedia == m_mayStartMediaWhenInWindow)
-        return;
-
-    m_mayStartMediaWhenInWindow = mayStartMedia;
-
-    if (!isValid())
-        return;
-
-    process()->send(Messages::WebPage::SetMayStartMediaWhenInWindow(mayStartMedia), m_pageID);
-}
-
 #if PLATFORM(QT) || PLATFORM(EFL) || PLATFORM(GTK)
 void WebPageProxy::handleDownloadRequest(DownloadProxy* download)
 {
@@ -3777,7 +3763,6 @@ WebPageCreationParameters WebPageProxy::creationParameters() const
     parameters.canRunModal = m_canRunModal;
     parameters.deviceScaleFactor = m_intrinsicDeviceScaleFactor;
     parameters.mediaVolume = m_mediaVolume;
-    parameters.mayStartMediaWhenInWindow = m_mayStartMediaWhenInWindow;
 
 #if PLATFORM(MAC)
     parameters.isSmartInsertDeleteEnabled = m_isSmartInsertDeleteEnabled;
index 98fa8a4f126a00c478f2eb76a386e52e7ca07de4..91fad303e166758e1f46eaa560aa57a933b8dae0 100644 (file)
@@ -736,7 +736,6 @@ public:
     void printMainFrame();
     
     void setMediaVolume(float);
-    void setMayStartMediaWhenInWindow(bool);
 
     // WebPopupMenuProxy::Client
     virtual NativeWebMouseEvent* currentlyProcessedMouseDownEvent();
@@ -1239,7 +1238,6 @@ private:
     bool m_suppressVisibilityUpdates;
 
     float m_mediaVolume;
-    bool m_mayStartMediaWhenInWindow;
 
 #if PLATFORM(QT)
     WTF::HashSet<RefPtr<QtRefCountedNetworkRequestData> > m_applicationSchemeRequests;
index ecf3dd1955ef770e61bba69d81185b8dc1d1838d..154458bc74aa764f7fd4448a291de01395d276d8 100644 (file)
@@ -364,7 +364,6 @@ WebPage::WebPage(uint64_t pageID, const WebPageCreationParameters& parameters)
     m_drawingArea->setPaintingEnabled(true);
     
     setMediaVolume(parameters.mediaVolume);
-    m_mayStartMediaWhenInWindow = parameters.mayStartMediaWhenInWindow;
 
     WebProcess::shared().addMessageReceiver(Messages::WebPage::messageReceiverName(), m_pageID, this);
 
@@ -1894,9 +1893,7 @@ void WebPage::setIsInWindow(bool isInWindow)
         // Defer the call to Page::setCanStartMedia() since it ends up sending a syncrhonous messages to the UI process
         // in order to get plug-in connections, and the UI process will be waiting for the Web process to update the backing
         // store after moving the view into a window, until it times out and paints white. See <rdar://problem/9242771>.
-        if (m_mayStartMediaWhenInWindow)
-            m_setCanStartMediaTimer.startOneShot(0);
-
+        m_setCanStartMediaTimer.startOneShot(0);
         m_page->didMoveOnscreen();
     }
 }
@@ -3321,16 +3318,6 @@ void WebPage::setMediaVolume(float volume)
     m_page->setMediaVolume(volume);
 }
 
-void WebPage::setMayStartMediaWhenInWindow(bool mayStartMedia)
-{
-    if (mayStartMedia == m_mayStartMediaWhenInWindow)
-        return;
-
-    m_mayStartMediaWhenInWindow = mayStartMedia;
-    if (m_mayStartMediaWhenInWindow && m_page->isOnscreen())
-        m_setCanStartMediaTimer.startOneShot(0);
-}
-
 void WebPage::runModal()
 {
     if (m_isClosed)
index 00ea81c8cbefed9a6b41ab0568f9fcf5b4fecab6..19af39c6ee714d66b000070f20b37410a1b51426 100644 (file)
@@ -525,7 +525,6 @@ public:
 #endif
 
     void setMediaVolume(float);
-    void setMayStartMediaWhenInWindow(bool);
 
     bool mainFrameHasCustomRepresentation() const;
 
@@ -852,7 +851,6 @@ private:
 #endif
     
     WebCore::RunLoop::Timer<WebPage> m_setCanStartMediaTimer;
-    bool m_mayStartMediaWhenInWindow;
 
     HashMap<uint64_t, RefPtr<WebUndoStep> > m_undoStepMap;
 
index ad4292b4beebb2c198c1167336d5b7e4951eb054..bbf6a686cecf15a7ebe362c14a5d2a93e4836f76 100644 (file)
@@ -226,7 +226,6 @@ messages -> WebPage {
 
     # Media
     SetMediaVolume(float volume)
-    SetMayStartMediaWhenInWindow(bool mayStartMedia)
 
     SetMemoryCacheMessagesEnabled(bool memoryCacheMessagesEnabled)