Enable a compositing trigger for filters

https://bugs.webkit.org/show_bug.cgi?id=75658

This will enable forcing the compositing code path when filters exist for a RenderObject.

Reviewed by Simon Fraser.

No new functionality so no new tests.

* page/ChromeClient.h:
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::requiresCompositingLayer):
(WebCore::RenderLayerCompositor::requiresCompositingForFilters):
* rendering/RenderLayerCompositor.h:


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@104347 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent bc3238b8
2012-01-06 No'am Rosenthal <noam.rosenthal@nokia.com>
Enable a compositing trigger for filters
https://bugs.webkit.org/show_bug.cgi?id=75658
This will enable forcing the compositing code path when filters exist for a RenderObject.
Reviewed by Simon Fraser.
No new functionality so no new tests.
* page/ChromeClient.h:
* rendering/RenderLayerCompositor.cpp:
(WebCore::RenderLayerCompositor::requiresCompositingLayer):
(WebCore::RenderLayerCompositor::requiresCompositingForFilters):
* rendering/RenderLayerCompositor.h:
2012-01-06 Anders Carlsson <andersca@apple.com>
Add and use ScrollElasticityControllerClient::absoluteScrollPosition
......@@ -258,6 +258,7 @@ namespace WebCore {
PluginTrigger = 1 << 2,
CanvasTrigger = 1 << 3,
AnimationTrigger = 1 << 4,
FilterTrigger = 1 << 5,
AllTriggers = 0xFFFFFFFF
};
typedef unsigned CompositingTriggerFlags;
......
......@@ -1331,6 +1331,7 @@ bool RenderLayerCompositor::requiresCompositingLayer(const RenderLayer* layer) c
|| clipsCompositingDescendants(layer)
|| requiresCompositingForAnimation(renderer)
|| requiresCompositingForFullScreen(renderer)
|| requiresCompositingForFilters(renderer)
|| requiresCompositingForPosition(renderer, layer);
}
......@@ -1516,6 +1517,19 @@ bool RenderLayerCompositor::requiresCompositingForFullScreen(RenderObject* rende
#endif
}
bool RenderLayerCompositor::requiresCompositingForFilters(RenderObject* renderer) const
{
#if ENABLE(CSS_FILTERS)
if (!(m_compositingTriggers & ChromeClient::FilterTrigger))
return false;
return renderer->hasFilter();
#else
UNUSED_PARAM(renderer);
return false;
#endif
}
bool RenderLayerCompositor::requiresCompositingForPosition(RenderObject* renderer, const RenderLayer* layer) const
{
// position:fixed elements that create their own stacking context (e.g. have an explicit z-index,
......
......@@ -285,6 +285,7 @@ private:
bool requiresCompositingForFrame(RenderObject*) const;
bool requiresCompositingWhenDescendantsAreCompositing(RenderObject*) const;
bool requiresCompositingForFullScreen(RenderObject*) const;
bool requiresCompositingForFilters(RenderObject*) const;
bool requiresCompositingForScrollableFrame() const;
bool requiresCompositingForPosition(RenderObject*, const RenderLayer*) const;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment