Avoid virtual method calls in the GraphicsLayer destructor
https://bugs.webkit.org/show_bug.cgi?id=83067
Reviewed by James Robinson.
Code cleanup to avoid calling virtual methods in the GraphicsLayer
destructor. Factor teardown code into a willBeDestroyed() method
that is called from the most dervied class. willBeDestroyed()
calls have to be chained. Fix the various ports' GraphicsLayer
implementations.
* platform/graphics/GraphicsLayer.cpp:
(WebCore::GraphicsLayer::~GraphicsLayer):
(WebCore):
(WebCore::GraphicsLayer::willBeDestroyed):
* platform/graphics/GraphicsLayer.h:
(GraphicsLayer):
* platform/graphics/blackberry/GraphicsLayerBlackBerry.cpp:
(WebCore::GraphicsLayerBlackBerry::~GraphicsLayerBlackBerry):
(WebCore):
(WebCore::GraphicsLayerBlackBerry::willBeDestroyed):
* platform/graphics/blackberry/GraphicsLayerBlackBerry.h:
(GraphicsLayerBlackBerry):
* platform/graphics/ca/GraphicsLayerCA.cpp:
(WebCore::GraphicsLayerCA::~GraphicsLayerCA):
(WebCore):
(WebCore::GraphicsLayerCA::willBeDestroyed):
* platform/graphics/ca/GraphicsLayerCA.h:
(GraphicsLayerCA):
* platform/graphics/chromium/GraphicsLayerChromium.cpp:
(WebCore::GraphicsLayerChromium::~GraphicsLayerChromium):
(WebCore):
(WebCore::GraphicsLayerChromium::willBeDestroyed):
* platform/graphics/chromium/GraphicsLayerChromium.h:
(GraphicsLayerChromium):
* platform/graphics/clutter/GraphicsLayerClutter.cpp:
(WebCore::GraphicsLayerClutter::~GraphicsLayerClutter):
* platform/graphics/efl/GraphicsLayerEfl.cpp:
(WebCore::GraphicsLayerEfl::~GraphicsLayerEfl):
* platform/graphics/qt/GraphicsLayerQt.cpp:
(WebCore::GraphicsLayerQt::~GraphicsLayerQt):
(WebCore):
(WebCore::GraphicsLayerQt::willBeDestroyed):
* platform/graphics/qt/GraphicsLayerQt.h:
(GraphicsLayerQt):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@113090
268f45cc-cd09-0410-ab3c-
d52691b4dbfc