Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1297)

Unified Diff: Source/core/rendering/compositing/CompositingReasonFinder.cpp

Issue 317013005: Make CompositingReasonFinder::requiresCompositingForAnimation take RenderStyle* (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/rendering/compositing/CompositingReasonFinder.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/rendering/compositing/CompositingReasonFinder.cpp
diff --git a/Source/core/rendering/compositing/CompositingReasonFinder.cpp b/Source/core/rendering/compositing/CompositingReasonFinder.cpp
index 4eeca79afea82c6e1f5012f1bcd92344da58e867..3c87a3eda72aeeb599e7d049ce52d802f8c361f5 100644
--- a/Source/core/rendering/compositing/CompositingReasonFinder.cpp
+++ b/Source/core/rendering/compositing/CompositingReasonFinder.cpp
@@ -110,7 +110,7 @@ CompositingReasons CompositingReasonFinder::styleDeterminedReasons(RenderObject*
if (style->backfaceVisibility() == BackfaceVisibilityHidden)
directReasons |= CompositingReasonBackfaceVisibilityHidden;
- if (requiresCompositingForAnimation(renderer))
+ if (requiresCompositingForAnimation(renderer->style()))
abarth-chromium 2014/06/06 18:10:53 There's already a |style| local variable in this f
ajuma 2014/06/06 18:13:31 Done.
directReasons |= CompositingReasonActiveAnimation;
if (style->hasWillChangeCompositingHint() && !style->subtreeWillChangeContents())
@@ -166,12 +166,12 @@ CompositingReasons CompositingReasonFinder::nonStyleDeterminedDirectReasons(cons
return directReasons;
}
-bool CompositingReasonFinder::requiresCompositingForAnimation(RenderObject* renderer) const
+bool CompositingReasonFinder::requiresCompositingForAnimation(RenderStyle* style) const
{
- if (renderer->style()->subtreeWillChangeContents())
- return renderer->style()->isRunningAnimationOnCompositor();
+ if (style->subtreeWillChangeContents())
+ return style->isRunningAnimationOnCompositor();
- return renderer->style()->shouldCompositeForCurrentAnimations();
+ return style->shouldCompositeForCurrentAnimations();
}
bool CompositingReasonFinder::requiresCompositingForPosition(RenderObject* renderer, const RenderLayer* layer, RenderLayer::ViewportConstrainedNotCompositedReason* viewportConstrainedNotCompositedReason) const
« no previous file with comments | « Source/core/rendering/compositing/CompositingReasonFinder.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698