[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
simon.fraser at apple.com
simon.fraser at apple.com
Wed Dec 22 13:59:30 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit c44600cc02f3c664d3e7902a88f7bfb4c6aab4d6
Author: simon.fraser at apple.com <simon.fraser at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Thu Sep 30 23:18:57 2010 +0000
2010-09-30 Simon Fraser <simon.fraser at apple.com>
Reviewed by Darin Adler.
Background doesn't draw when entering accelerated compositing
https://bugs.webkit.org/show_bug.cgi?id=45848
LayerBackedDrawingArea::setSize() is normally called in response
to a message from the UI process, so this can come some time after
LayerBackedDrawingArea creation. Depending on the timing, we could
end up being at size 0x0 for the first invalidate and paint, resulting
in missing content.
The fix is to size the backing layer on creation, using the WebView's size.
Also changed various calls to syncCompositingStateForThisLayerOnly()
to do lazy updates via scheduleCompositingLayerSync().
Also add the fix for https://bugs.webkit.org/show_bug.cgi?id=46226 (r68028)
to the WebKit2 code, in scheduleUpdateLayoutRunLoopObserver().
* WebProcess/WebPage/LayerBackedDrawingArea.cpp:
(WebKit::LayerBackedDrawingArea::LayerBackedDrawingArea):
(WebKit::LayerBackedDrawingArea::setNeedsDisplay):
(WebKit::LayerBackedDrawingArea::setSize):
* WebProcess/WebPage/mac/LayerBackedDrawingAreaMac.mm:
(WebKit::LayerBackedDrawingArea::platformInit):
(WebKit::LayerBackedDrawingArea::attachCompositingContext):
(WebKit::LayerBackedDrawingArea::detachCompositingContext):
(WebKit::LayerBackedDrawingArea::setRootCompositingLayer):
(WebKit::LayerBackedDrawingArea::syncCompositingLayers):
(WebKit::LayerBackedDrawingArea::scheduleUpdateLayoutRunLoopObserver):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@68851 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit2/ChangeLog b/WebKit2/ChangeLog
index d777e5f..ca84e1e 100644
--- a/WebKit2/ChangeLog
+++ b/WebKit2/ChangeLog
@@ -1,3 +1,36 @@
+2010-09-30 Simon Fraser <simon.fraser at apple.com>
+
+ Reviewed by Darin Adler.
+
+ Background doesn't draw when entering accelerated compositing
+ https://bugs.webkit.org/show_bug.cgi?id=45848
+
+ LayerBackedDrawingArea::setSize() is normally called in response
+ to a message from the UI process, so this can come some time after
+ LayerBackedDrawingArea creation. Depending on the timing, we could
+ end up being at size 0x0 for the first invalidate and paint, resulting
+ in missing content.
+
+ The fix is to size the backing layer on creation, using the WebView's size.
+
+ Also changed various calls to syncCompositingStateForThisLayerOnly()
+ to do lazy updates via scheduleCompositingLayerSync().
+
+ Also add the fix for https://bugs.webkit.org/show_bug.cgi?id=46226 (r68028)
+ to the WebKit2 code, in scheduleUpdateLayoutRunLoopObserver().
+
+ * WebProcess/WebPage/LayerBackedDrawingArea.cpp:
+ (WebKit::LayerBackedDrawingArea::LayerBackedDrawingArea):
+ (WebKit::LayerBackedDrawingArea::setNeedsDisplay):
+ (WebKit::LayerBackedDrawingArea::setSize):
+ * WebProcess/WebPage/mac/LayerBackedDrawingAreaMac.mm:
+ (WebKit::LayerBackedDrawingArea::platformInit):
+ (WebKit::LayerBackedDrawingArea::attachCompositingContext):
+ (WebKit::LayerBackedDrawingArea::detachCompositingContext):
+ (WebKit::LayerBackedDrawingArea::setRootCompositingLayer):
+ (WebKit::LayerBackedDrawingArea::syncCompositingLayers):
+ (WebKit::LayerBackedDrawingArea::scheduleUpdateLayoutRunLoopObserver):
+
2010-09-29 Jon Honeycutt <jhoneycutt at apple.com>
WebKit2 on Windows should use Windows fonts for the various standard
diff --git a/WebKit2/WebProcess/WebPage/LayerBackedDrawingArea.cpp b/WebKit2/WebProcess/WebPage/LayerBackedDrawingArea.cpp
index 96a1615..163af0a 100644
--- a/WebKit2/WebProcess/WebPage/LayerBackedDrawingArea.cpp
+++ b/WebKit2/WebProcess/WebPage/LayerBackedDrawingArea.cpp
@@ -53,8 +53,7 @@ LayerBackedDrawingArea::LayerBackedDrawingArea(DrawingAreaID identifier, WebPage
#ifndef NDEBUG
m_backingLayer->setName("DrawingArea backing layer");
#endif
- m_backingLayer->syncCompositingStateForThisLayerOnly();
-
+ m_backingLayer->setSize(webPage->size());
platformInit();
}
@@ -87,11 +86,7 @@ void LayerBackedDrawingArea::scroll(const IntSize& scrollDelta, const IntRect& r
void LayerBackedDrawingArea::setNeedsDisplay(const IntRect& rect)
{
m_backingLayer->setNeedsDisplayInRect(rect);
- m_backingLayer->syncCompositingStateForThisLayerOnly();
-
-#if PLATFORM(MAC)
- scheduleUpdateLayoutRunLoopObserver();
-#endif
+ scheduleCompositingLayerSync();
}
void LayerBackedDrawingArea::display()
@@ -110,7 +105,7 @@ void LayerBackedDrawingArea::setSize(const IntSize& viewSize)
ASSERT_ARG(viewSize, !viewSize.isEmpty());
m_backingLayer->setSize(viewSize);
- m_backingLayer->syncCompositingStateForThisLayerOnly();
+ scheduleCompositingLayerSync();
m_webPage->setSize(viewSize);
diff --git a/WebKit2/WebProcess/WebPage/mac/LayerBackedDrawingAreaMac.mm b/WebKit2/WebProcess/WebPage/mac/LayerBackedDrawingAreaMac.mm
index b271a13..abe9ee1 100644
--- a/WebKit2/WebProcess/WebPage/mac/LayerBackedDrawingAreaMac.mm
+++ b/WebKit2/WebProcess/WebPage/mac/LayerBackedDrawingAreaMac.mm
@@ -42,12 +42,14 @@ namespace WebKit {
void LayerBackedDrawingArea::platformInit()
{
+ setUpUpdateLayoutRunLoopObserver();
+
[m_backingLayer->platformLayer() setGeometryFlipped:YES];
#if HAVE(HOSTED_CORE_ANIMATION)
attachCompositingContext();
#endif
- setUpUpdateLayoutRunLoopObserver();
+ scheduleCompositingLayerSync();
}
void LayerBackedDrawingArea::platformClear()
@@ -70,8 +72,6 @@ void LayerBackedDrawingArea::attachCompositingContext()
if (m_attached)
return;
- m_backingLayer->syncCompositingStateForThisLayerOnly();
-
m_attached = true;
#if HAVE(HOSTED_CORE_ANIMATION)
@@ -87,7 +87,8 @@ void LayerBackedDrawingArea::attachCompositingContext()
void LayerBackedDrawingArea::detachCompositingContext()
{
m_backingLayer->removeAllChildren();
- m_backingLayer->syncCompositingStateForThisLayerOnly();
+
+ scheduleCompositingLayerSync();
}
void LayerBackedDrawingArea::setRootCompositingLayer(WebCore::GraphicsLayer* layer)
@@ -95,7 +96,8 @@ void LayerBackedDrawingArea::setRootCompositingLayer(WebCore::GraphicsLayer* lay
m_backingLayer->removeAllChildren();
if (layer)
m_backingLayer->addChild(layer);
- m_backingLayer->syncCompositingStateForThisLayerOnly();
+
+ scheduleCompositingLayerSync();
}
void LayerBackedDrawingArea::scheduleCompositingLayerSync()
@@ -110,6 +112,8 @@ void LayerBackedDrawingArea::scheduleCompositingLayerSync()
void LayerBackedDrawingArea::syncCompositingLayers()
{
+ m_backingLayer->syncCompositingStateForThisLayerOnly();
+
bool didSync = m_webPage->corePage()->mainFrame()->view()->syncCompositingStateRecursive();
if (!didSync) {
@@ -132,6 +136,8 @@ void LayerBackedDrawingArea::setUpUpdateLayoutRunLoopObserver()
void LayerBackedDrawingArea::scheduleUpdateLayoutRunLoopObserver()
{
CFRunLoopRef currentRunLoop = CFRunLoopGetCurrent();
+ CFRunLoopWakeUp(currentRunLoop);
+
if (CFRunLoopContainsObserver(currentRunLoop, m_updateLayoutRunLoopObserver.get(), kCFRunLoopCommonModes))
return;
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list