[CoordGraphics] CompositingCoordinator should hande root compositing and view overlay...
authorzandobersek@gmail.com <zandobersek@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 4 May 2016 07:39:23 +0000 (07:39 +0000)
committerzandobersek@gmail.com <zandobersek@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 4 May 2016 07:39:23 +0000 (07:39 +0000)
commitd370a0db735d166b275690c715c35c93a219c934
treef3c6294eab81f4b521ba75ecdc8927141c11eb56
parentb2158c13454c9b946ed342b50ab98ee08e10ae78
[CoordGraphics] CompositingCoordinator should hande root compositing and view overlay layers separately
https://bugs.webkit.org/show_bug.cgi?id=157305

Reviewed by Carlos Garcia Campos.

Source/WebCore:

Split out handling of the root compositing and the view overlay layers
into two separate methods. Both do nothing if the passed-in layer is
the same as the current one. Otherwise, the current one is removed
from the tree and the new one added to it.

No change in behavior is expected.

* platform/graphics/texmap/coordinated/CompositingCoordinator.cpp:
(WebCore::CompositingCoordinator::setRootCompositingLayer):
(WebCore::CompositingCoordinator::setViewOverlayRootLayer):
* platform/graphics/texmap/coordinated/CompositingCoordinator.h:

Source/WebKit2:

Update CoordinatedLayerTreeHost and ThreadCoordinatedLayerTreeHost to
correctly use setRootCompositingLayer() and setViewOverlayRootLayer()
methods on the CompositingCoordinator object.

CoordinatedLayerTreeHost doesn't have to keep a pointer to the root
compositing layer anymore. updateRootLayers() can be removed.

ThreadCoordinatedLayerTreeHost doen't have to keep a pointer to both
the root compositing and the view overlay layers anymore. Similarly,
updateRootLayers() can be removed.

* WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp:
(WebKit::CoordinatedLayerTreeHost::setViewOverlayRootLayer):
(WebKit::CoordinatedLayerTreeHost::setRootCompositingLayer):
(WebKit::CoordinatedLayerTreeHost::CoordinatedLayerTreeHost): Deleted.
(WebKit::CoordinatedLayerTreeHost::updateRootLayers): Deleted.
* WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h:
* WebProcess/WebPage/CoordinatedGraphics/ThreadedCoordinatedLayerTreeHost.cpp:
(WebKit::ThreadedCoordinatedLayerTreeHost::setRootCompositingLayer):
(WebKit::ThreadedCoordinatedLayerTreeHost::setViewOverlayRootLayer):
(WebKit::ThreadedCoordinatedLayerTreeHost::ThreadedCoordinatedLayerTreeHost): Deleted.
(WebKit::ThreadedCoordinatedLayerTreeHost::updateRootLayers): Deleted.
* WebProcess/WebPage/CoordinatedGraphics/ThreadedCoordinatedLayerTreeHost.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@200408 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/texmap/coordinated/CompositingCoordinator.cpp
Source/WebCore/platform/graphics/texmap/coordinated/CompositingCoordinator.h
Source/WebKit2/ChangeLog
Source/WebKit2/WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.cpp
Source/WebKit2/WebProcess/WebPage/CoordinatedGraphics/CoordinatedLayerTreeHost.h
Source/WebKit2/WebProcess/WebPage/CoordinatedGraphics/ThreadedCoordinatedLayerTreeHost.cpp
Source/WebKit2/WebProcess/WebPage/CoordinatedGraphics/ThreadedCoordinatedLayerTreeHost.h