summaryrefslogtreecommitdiffstats
path: root/cc/trees/layer_tree_impl_unittest.cc
diff options
context:
space:
mode:
authoraelias <aelias@chromium.org>2014-12-03 17:04:40 -0800
committerCommit bot <commit-bot@chromium.org>2014-12-04 01:06:00 +0000
commit58eec0810c6412fb9debb83754bd0e5a65cecdc6 (patch)
tree8c36e88e33ce9728121b212eb285ffaddac26638 /cc/trees/layer_tree_impl_unittest.cc
parent6657c7a9f11b17e3a378b0bb2112ecc314ec9cad (diff)
downloadchromium_src-58eec0810c6412fb9debb83754bd0e5a65cecdc6.zip
chromium_src-58eec0810c6412fb9debb83754bd0e5a65cecdc6.tar.gz
chromium_src-58eec0810c6412fb9debb83754bd0e5a65cecdc6.tar.bz2
Refactor delta/sent_delta logic into self-contained abstraction.
This patch updates page scale to use a new SyncedProperty abstraction. This is shared between the pending and active trees and contains all page scale state on the impl side except for the min/max limits. Its API only exposes those operations that are encouraged: for example, the raw main-thread originating value can no longer be used by accident. This patch should be a no-op. In future patches, I intend to make scroll offsets and top controls use this abstraction as well. NOTRY=true BUG= Review URL: https://codereview.chromium.org/764483002 Cr-Commit-Position: refs/heads/master@{#306736}
Diffstat (limited to 'cc/trees/layer_tree_impl_unittest.cc')
-rw-r--r--cc/trees/layer_tree_impl_unittest.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/cc/trees/layer_tree_impl_unittest.cc b/cc/trees/layer_tree_impl_unittest.cc
index 52f8e0a..2131d4c 100644
--- a/cc/trees/layer_tree_impl_unittest.cc
+++ b/cc/trees/layer_tree_impl_unittest.cc
@@ -1795,8 +1795,9 @@ TEST_F(LayerTreeImplTest,
host_impl().SetViewportSize(scaled_bounds_for_root);
host_impl().SetDeviceScaleFactor(device_scale_factor);
- host_impl().active_tree()->SetPageScaleFactorAndLimits(
+ host_impl().active_tree()->PushPageScaleFromMainThread(
page_scale_factor, page_scale_factor, page_scale_factor);
+ host_impl().SetPageScaleOnActiveTree(page_scale_factor);
host_impl().active_tree()->SetRootLayer(root.Pass());
host_impl().active_tree()->SetViewportLayersFromIds(Layer::INVALID_ID, 1, 1,
Layer::INVALID_ID);
@@ -2299,8 +2300,9 @@ TEST_F(LayerTreeImplTest, SelectionBoundsForScaledLayers) {
host_impl().SetViewportSize(scaled_bounds_for_root);
host_impl().SetDeviceScaleFactor(device_scale_factor);
- host_impl().active_tree()->SetPageScaleFactorAndLimits(
+ host_impl().active_tree()->PushPageScaleFromMainThread(
page_scale_factor, page_scale_factor, page_scale_factor);
+ host_impl().SetPageScaleOnActiveTree(page_scale_factor);
host_impl().active_tree()->SetRootLayer(root.Pass());
host_impl().active_tree()->SetViewportLayersFromIds(Layer::INVALID_ID, 1, 1,
Layer::INVALID_ID);