[EFL][WebGL] WebGL content is not painted after resizing the viewport.
https://bugs.webkit.org/show_bug.cgi?id=106358
Patch by Viatcheslav Ostapenko <sl.ostapenko@samsung.com> on 2013-02-11
Reviewed by Noam Rosenthal.
Source/WebCore:
When page size changes and layer parameters get updated LayerTreeRenderer::setLayerState
clears the layer backing store and detaches the canvas surface from the layer. If the layer
size is not changed then the canvas is not recreated. This leaves the canvas detached from
the layer, but still referenced from m_surfaceBackingStores.
Don't assign layer backing store to layer in assignImageBackingToLayer if there is a canvas
surface already attached to the layer.
Test: fast/canvas/webgl/webgl-layer-update.html
* platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
(WebCore::CoordinatedGraphicsScene::setLayerState):
(WebCore::CoordinatedGraphicsScene::assignImageBackingToLayer):
* platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.h:
LayoutTests:
Add test checking that canvas painting is correct if layer parameters were changed,
but webgl canvas didn't change.
* fast/canvas/webgl/webgl-layer-update-expected.png: Added.
* fast/canvas/webgl/webgl-layer-update-expected.txt: Added.
* fast/canvas/webgl/webgl-layer-update.html: Added.
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@142586
268f45cc-cd09-0410-ab3c-
d52691b4dbfc