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

Unified Diff: cc/trees/layer_tree_host_perftest.cc

Issue 544853002: cc: Remove static from leaf invalidation perf test (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/layer_tree_host_perftest.cc
diff --git a/cc/trees/layer_tree_host_perftest.cc b/cc/trees/layer_tree_host_perftest.cc
index 999ab3f02c0591c044536cd2719897945f1ad687..d78c517459e3cd53d1290ab79c3119c7bd350515 100644
--- a/cc/trees/layer_tree_host_perftest.cc
+++ b/cc/trees/layer_tree_host_perftest.cc
@@ -192,9 +192,8 @@ class LayerTreeHostPerfTestLeafInvalidates
if (TestEnded())
return;
- static bool flip = true;
- layer_to_invalidate_->SetOpacity(flip ? 1.f : 0.5f);
- flip = !flip;
+ layer_to_invalidate_->SetOpacity(
+ layer_to_invalidate_->opacity() != 1.f ? 1.f : 0.5f);
}
protected:
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698