Title: [109854] tags/Safari-536.2.1/Source
- Revision
- 109854
- Author
- lforsch...@apple.com
- Date
- 2012-03-05 21:20:32 -0800 (Mon, 05 Mar 2012)
Log Message
Merged r109801.
Modified Paths
Diff
Modified: tags/Safari-536.2.1/Source/WebCore/ChangeLog (109853 => 109854)
--- tags/Safari-536.2.1/Source/WebCore/ChangeLog 2012-03-06 05:19:00 UTC (rev 109853)
+++ tags/Safari-536.2.1/Source/WebCore/ChangeLog 2012-03-06 05:20:32 UTC (rev 109854)
@@ -1,5 +1,27 @@
2011-03-05 Lucas Forschler <lforsch...@apple.com>
+ Merge 109801
+
+ 2012-03-05 Anders Carlsson <ander...@apple.com>
+
+ Always update the scroll layer position on the main thread when we have an overlay
+ https://bugs.webkit.org/show_bug.cgi?id=80324
+
+ Reviewed by Sam Weinig.
+
+ Add a way to ensure that scroll layer position updates happen on the main thread.
+
+ * WebCore.exp.in:
+ * page/scrolling/ScrollingCoordinator.cpp:
+ (WebCore::ScrollingCoordinator::ScrollingCoordinator):
+ (WebCore::ScrollingCoordinator::updateShouldUpdateScrollLayerPositionOnMainThread):
+ (WebCore):
+ (WebCore::ScrollingCoordinator::setForceMainThreadScrollLayerPositionUpdates):
+ * page/scrolling/ScrollingCoordinator.h:
+ (ScrollingCoordinator):
+
+2011-03-05 Lucas Forschler <lforsch...@apple.com>
+
Merge 109788
2012-03-05 Anders Carlsson <ander...@apple.com>
Modified: tags/Safari-536.2.1/Source/WebCore/WebCore.exp.in (109853 => 109854)
--- tags/Safari-536.2.1/Source/WebCore/WebCore.exp.in 2012-03-06 05:19:00 UTC (rev 109853)
+++ tags/Safari-536.2.1/Source/WebCore/WebCore.exp.in 2012-03-06 05:20:32 UTC (rev 109854)
@@ -2100,6 +2100,7 @@
__ZN7WebCore13ScrollingTree22updateBackForwardStateEbb
__ZN7WebCore13ScrollingTreeD1Ev
__ZN7WebCore15ScrollingThread8dispatchERKN3WTF8FunctionIFvvEEE
+__ZN7WebCore20ScrollingCoordinator44setForceMainThreadScrollLayerPositionUpdatesEb
__ZN7WebCore4Page20scrollingCoordinatorEv
__ZNK7WebCore20ScrollingCoordinator13scrollingTreeEv
#endif
Modified: tags/Safari-536.2.1/Source/WebCore/page/scrolling/ScrollingCoordinator.cpp (109853 => 109854)
--- tags/Safari-536.2.1/Source/WebCore/page/scrolling/ScrollingCoordinator.cpp 2012-03-06 05:19:00 UTC (rev 109853)
+++ tags/Safari-536.2.1/Source/WebCore/page/scrolling/ScrollingCoordinator.cpp 2012-03-06 05:20:32 UTC (rev 109854)
@@ -53,6 +53,7 @@
ScrollingCoordinator::ScrollingCoordinator(Page* page)
: m_page(page)
+ , m_forceMainThreadScrollLayerPositionUpdates(false)
#if ENABLE(THREADED_SCROLLING)
, m_scrollingTreeState(ScrollingTreeState::create())
, m_scrollingTree(ScrollingTree::create(this))
@@ -310,9 +311,18 @@
FrameView* frameView = m_page->mainFrame()->view();
// FIXME: Having fixed objects on the page should not trigger the slow path.
- setShouldUpdateScrollLayerPositionOnMainThread(frameView->hasSlowRepaintObjects() || frameView->hasFixedObjects());
+ setShouldUpdateScrollLayerPositionOnMainThread(m_forceMainThreadScrollLayerPositionUpdates || frameView->hasSlowRepaintObjects() || frameView->hasFixedObjects());
}
+void ScrollingCoordinator::setForceMainThreadScrollLayerPositionUpdates(bool forceMainThreadScrollLayerPositionUpdates)
+{
+ if (m_forceMainThreadScrollLayerPositionUpdates == forceMainThreadScrollLayerPositionUpdates)
+ return;
+
+ m_forceMainThreadScrollLayerPositionUpdates = forceMainThreadScrollLayerPositionUpdates;
+ updateShouldUpdateScrollLayerPositionOnMainThread();
+}
+
#if ENABLE(THREADED_SCROLLING)
void ScrollingCoordinator::setScrollLayer(GraphicsLayer* scrollLayer)
{
Modified: tags/Safari-536.2.1/Source/WebCore/page/scrolling/ScrollingCoordinator.h (109853 => 109854)
--- tags/Safari-536.2.1/Source/WebCore/page/scrolling/ScrollingCoordinator.h 2012-03-06 05:19:00 UTC (rev 109853)
+++ tags/Safari-536.2.1/Source/WebCore/page/scrolling/ScrollingCoordinator.h 2012-03-06 05:20:32 UTC (rev 109854)
@@ -112,6 +112,9 @@
void handleWheelEventPhase(PlatformWheelEventPhase);
#endif
+ // Force all scroll layer position updates to happen on the main thread.
+ void setForceMainThreadScrollLayerPositionUpdates(bool);
+
private:
explicit ScrollingCoordinator(Page*);
@@ -128,6 +131,8 @@
Page* m_page;
+ bool m_forceMainThreadScrollLayerPositionUpdates;
+
#if ENABLE(THREADED_SCROLLING)
void scheduleTreeStateCommit();
Modified: tags/Safari-536.2.1/Source/WebKit2/ChangeLog (109853 => 109854)
--- tags/Safari-536.2.1/Source/WebKit2/ChangeLog 2012-03-06 05:19:00 UTC (rev 109853)
+++ tags/Safari-536.2.1/Source/WebKit2/ChangeLog 2012-03-06 05:20:32 UTC (rev 109854)
@@ -1,3 +1,21 @@
+2011-03-05 Lucas Forschler <lforsch...@apple.com>
+
+ Merge 109801
+
+ 2012-03-05 Anders Carlsson <ander...@apple.com>
+
+ Always update the scroll layer position on the main thread when we have an overlay
+ https://bugs.webkit.org/show_bug.cgi?id=80324
+
+ Reviewed by Sam Weinig.
+
+ Call setForceMainThreadScrollLayerPositionUpdates when installing and uninstalling page overlays,
+ so we'll be able to synchronize painting between the tile cache and the page overlays.
+
+ * WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm:
+ (WebKit::TiledCoreAnimationDrawingArea::didInstallPageOverlay):
+ (WebKit::TiledCoreAnimationDrawingArea::didUninstallPageOverlay):
+
2011-03-02 Lucas Forschler <lforsch...@apple.com>
Merge 109340
Modified: tags/Safari-536.2.1/Source/WebKit2/WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm (109853 => 109854)
--- tags/Safari-536.2.1/Source/WebKit2/WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm 2012-03-06 05:19:00 UTC (rev 109853)
+++ tags/Safari-536.2.1/Source/WebKit2/WebProcess/WebPage/mac/TiledCoreAnimationDrawingArea.mm 2012-03-06 05:20:32 UTC (rev 109854)
@@ -146,12 +146,20 @@
void TiledCoreAnimationDrawingArea::didInstallPageOverlay()
{
+#if ENABLE(THREADED_SCROLLING)
+ m_webPage->corePage()->scrollingCoordinator()->setForceMainThreadScrollLayerPositionUpdates(true);
+#endif
+
createPageOverlayLayer();
scheduleCompositingLayerSync();
}
void TiledCoreAnimationDrawingArea::didUninstallPageOverlay()
{
+#if ENABLE(THREADED_SCROLLING)
+ m_webPage->corePage()->scrollingCoordinator()->setForceMainThreadScrollLayerPositionUpdates(false);
+#endif
+
destroyPageOverlayLayer();
scheduleCompositingLayerSync();
}
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes