Title: [87768] trunk/Source
Revision
87768
Author
[email protected]
Date
2011-05-31 18:48:53 -0700 (Tue, 31 May 2011)

Log Message

2011-05-31  Jer Noble  <[email protected]>

        Reviewed by Darin Adler.

        Flash of black at the end of full screen transition at apple.com product videos
        https://bugs.webkit.org/show_bug.cgi?id=61756

        Added two new entries to the WebCore exports list.

        * WebCore.exp.in:
2011-05-31  Jer Noble  <[email protected]>

        Reviewed by Darin Adler.

        Flash of black at the end of full screen transition at apple.com product videos
        https://bugs.webkit.org/show_bug.cgi?id=61756

        The @"WebKitLayerHostChanged" notification is causing the QTMovie to tear down its layer
        (which is good) at the wrong time (which is bad).  Send this notification only after
        the dragImage snapshot is taken.  This exposed another problem, that the snapshot has
        a white background.  Set the default background color and transparency for the view (making
        sure to reset them afterwards) to transparent.

        * WebProcess/FullScreen/mac/WebFullScreenManagerMac.mm:
        (WebKit::WebFullScreenManagerMac::setRootFullScreenLayer):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (87767 => 87768)


--- trunk/Source/WebCore/ChangeLog	2011-06-01 01:47:23 UTC (rev 87767)
+++ trunk/Source/WebCore/ChangeLog	2011-06-01 01:48:53 UTC (rev 87768)
@@ -1,3 +1,14 @@
+2011-05-31  Jer Noble  <[email protected]>
+
+        Reviewed by Darin Adler.
+
+        Flash of black at the end of full screen transition at apple.com product videos
+        https://bugs.webkit.org/show_bug.cgi?id=61756
+
+        Added two new entries to the WebCore exports list.
+
+        * WebCore.exp.in:
+
 2011-05-31  Rafael Brandao  <[email protected]>
 
         Reviewed by Andreas Kling.

Modified: trunk/Source/WebCore/WebCore.exp.in (87767 => 87768)


--- trunk/Source/WebCore/WebCore.exp.in	2011-06-01 01:47:23 UTC (rev 87767)
+++ trunk/Source/WebCore/WebCore.exp.in	2011-06-01 01:48:53 UTC (rev 87768)
@@ -930,6 +930,7 @@
 __ZN7WebCore9FrameView14setMarginWidthEi
 __ZN7WebCore9FrameView14setNeedsLayoutEv
 __ZN7WebCore9FrameView14setTransparentEb
+__ZNK7WebCore9FrameView13isTransparentEv
 __ZN7WebCore9FrameView15setMarginHeightEi
 __ZN7WebCore9FrameView16setPaintBehaviorEj
 __ZN7WebCore9FrameView17setScrollPositionERKNS_8IntPointE
@@ -937,6 +938,7 @@
 __ZN7WebCore9FrameView20enterCompositingModeEv
 __ZN7WebCore9FrameView21flushDeferredRepaintsEv
 __ZN7WebCore9FrameView22setBaseBackgroundColorERKNS_5ColorE
+__ZNK7WebCore9FrameView19baseBackgroundColorEv
 __ZN7WebCore9FrameView23updateCanHaveScrollbarsEv
 __ZN7WebCore9FrameView24forceLayoutForPaginationERKNS_9FloatSizeEfNS_19AdjustViewSizeOrNotE
 __ZN7WebCore9FrameView26adjustPageHeightDeprecatedEPffff

Modified: trunk/Source/WebKit2/ChangeLog (87767 => 87768)


--- trunk/Source/WebKit2/ChangeLog	2011-06-01 01:47:23 UTC (rev 87767)
+++ trunk/Source/WebKit2/ChangeLog	2011-06-01 01:48:53 UTC (rev 87768)
@@ -1,3 +1,19 @@
+2011-05-31  Jer Noble  <[email protected]>
+
+        Reviewed by Darin Adler.
+
+        Flash of black at the end of full screen transition at apple.com product videos
+        https://bugs.webkit.org/show_bug.cgi?id=61756
+
+        The @"WebKitLayerHostChanged" notification is causing the QTMovie to tear down its layer
+        (which is good) at the wrong time (which is bad).  Send this notification only after 
+        the dragImage snapshot is taken.  This exposed another problem, that the snapshot has
+        a white background.  Set the default background color and transparency for the view (making
+        sure to reset them afterwards) to transparent.
+
+        * WebProcess/FullScreen/mac/WebFullScreenManagerMac.mm:
+        (WebKit::WebFullScreenManagerMac::setRootFullScreenLayer):
+
 2011-03-30  Martin Robinson  <[email protected]>
 
         Reviewed by Adam Roben.

Modified: trunk/Source/WebKit2/WebProcess/FullScreen/mac/WebFullScreenManagerMac.mm (87767 => 87768)


--- trunk/Source/WebKit2/WebProcess/FullScreen/mac/WebFullScreenManagerMac.mm	2011-06-01 01:47:23 UTC (rev 87767)
+++ trunk/Source/WebKit2/WebProcess/FullScreen/mac/WebFullScreenManagerMac.mm	2011-06-01 01:48:53 UTC (rev 87768)
@@ -139,20 +139,29 @@
 
     if (!layer) {
         m_page->send(Messages::WebFullScreenManagerProxy::ExitAcceleratedCompositingMode());
-        [[NSNotificationCenter defaultCenter] postNotificationName:@"WebKitLayerHostChanged" object:m_rootLayer->platformLayer() userInfo:nil];
 
         Frame* frame = m_element->document()->frame();
-        DragImageRef dragImage = frame ? frame->nodeImage(m_element.get()) : 0;
+        FrameView* view = frame ? frame->view() : 0;
+        DragImageRef dragImage = 0;
+        if (view) {
+            Color savedBackgroundColor = view->baseBackgroundColor();
+            bool savedIsTransparent = view->isTransparent();
+            view->setBaseBackgroundColor(Color::transparent);
+            view->setTransparent(true);
+            dragImage = frame->nodeImage(m_element.get());
+            view->setBaseBackgroundColor(savedBackgroundColor);
+            view->setTransparent(savedIsTransparent);
+        }
 
-        if (m_rootLayer) {
-            [CATransaction begin];
-            PlatformLayer* rootPlatformLayer = m_rootLayer->platformLayer();
-            m_rootLayer->removeAllChildren();
-            m_rootLayer->syncCompositingStateForThisLayerOnly();
-            m_rootLayer = nullptr;
-            [rootPlatformLayer setContents:dragImage.get()];
-            [CATransaction commit];
-        }
+        [CATransaction begin];
+        PlatformLayer* rootPlatformLayer = m_rootLayer->platformLayer();
+        [[NSNotificationCenter defaultCenter] postNotificationName:@"WebKitLayerHostChanged" object:rootPlatformLayer userInfo:nil];
+
+        m_rootLayer->removeAllChildren();
+        m_rootLayer->syncCompositingStateForThisLayerOnly();
+        m_rootLayer = nullptr;
+        [rootPlatformLayer setContents:dragImage.get()];
+        [CATransaction commit];
         
         return;
     }
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to