summaryrefslogtreecommitdiffstats
path: root/cc/trees/layer_tree_impl.h
diff options
context:
space:
mode:
authorricea@chromium.org <ricea@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-01-29 14:32:46 +0000
committerricea@chromium.org <ricea@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-01-29 14:32:46 +0000
commitd35cd7b26ab76fee5a42eeaec4a9538265a490e3 (patch)
treedeca5f14d0c152f12146f2dcb0613bdbef72805c /cc/trees/layer_tree_impl.h
parentb5ef3d30c1e8f33718f6dcfde5fa19fa4a6c7f93 (diff)
downloadchromium_src-d35cd7b26ab76fee5a42eeaec4a9538265a490e3.zip
chromium_src-d35cd7b26ab76fee5a42eeaec4a9538265a490e3.tar.gz
chromium_src-d35cd7b26ab76fee5a42eeaec4a9538265a490e3.tar.bz2
Revert of Pinch/Zoom Infrastructure & Plumbing CL (https://codereview.chromium.org/23983047/)
Reason for revert: Broke Linux ASAN Tests (3) bot. Original issue's description: > Pinch/Zoom Infrastructure & Plumbing CL > > This CL supplies the necessary changes to CC to support the > inner/outer viewport model for pinch-zoom and fixed-position > elements. The specification for these changes is contained in > the document "Layer-based Solution for Pinch Zoom / Fixed > Position". > > It incorporates a change to how scrollbar parameters are > computed (removes the notion of max_scroll_offset as a > quantity set be the embedder, and instead inferred from the > relative sizes of a clip layer w.r.t. the scroll layer). > > Scrollbars are generalized so that a layer may have more than > two scrollbars, and the parameters of the scrollbar are set > w.r.t. the sizes and positions of a clip and a scroll layer. > Further, changes to the scrip/scroll layer automatically > notify any attached scrollbars. > > The CL also removes existing references to root_scroll_layer > from LTH, LTI and LTHI and replaces them with either > Inner/OuterViewportScrollLayer (dual-layer operation only > exists at present if the --enable-pinch-virtual-viewport flag > is specified, otherwise behavior is unchanged). > > Logic is added to (i) combine scroll offsets for the two > viewports before passing it to the embedder, and (ii) > splitting any offsets received from the embedder > appropriately between the two viewports. > > This CL relies on https://codereview.chromium.org/138453004/ > for changes in Blink to support it. > > BUG=148816 > > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=246812 > > R=aelias@chromium.org, enne@chromium.org, joi@chromium.org, piman@chromium.org, sky@chromium.org > > Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=247684 TBR=enne@chromium.org,aelias@chromium.org,joi@chromium.org,sky@chromium.org,piman@chromium.org,tony@chromium.org,wjmaclean@chromium.org NOTREECHECKS=true NOTRY=true BUG=148816 Review URL: https://codereview.chromium.org/135183016 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@247688 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cc/trees/layer_tree_impl.h')
-rw-r--r--cc/trees/layer_tree_impl.h22
1 files changed, 6 insertions, 16 deletions
diff --git a/cc/trees/layer_tree_impl.h b/cc/trees/layer_tree_impl.h
index 81a8992..7c4479d 100644
--- a/cc/trees/layer_tree_impl.h
+++ b/cc/trees/layer_tree_impl.h
@@ -34,7 +34,6 @@ class ContextProvider;
class DebugRectHistory;
class FrameRateCounter;
class HeadsUpDisplayLayerImpl;
-class LayerScrollOffsetDelegateProxy;
class LayerTreeDebugState;
class LayerTreeHostImpl;
class LayerTreeImpl;
@@ -114,24 +113,18 @@ class CC_EXPORT LayerTreeImpl {
hud_layer_ = layer_impl;
}
- LayerImpl* InnerViewportScrollLayer() const;
- // This function may return NULL, it is the caller's responsibility to check.
- LayerImpl* OuterViewportScrollLayer() const;
- gfx::Vector2dF TotalScrollOffset() const;
- gfx::Vector2dF TotalMaxScrollOffset() const;
- gfx::Vector2dF TotalScrollDelta() const;
-
+ LayerImpl* RootScrollLayer() const;
LayerImpl* RootContainerLayer() const;
LayerImpl* CurrentlyScrollingLayer() const;
void SetCurrentlyScrollingLayer(LayerImpl* layer);
void ClearCurrentlyScrollingLayer();
- float VerticalAdjust(const LayerImpl* layer) const;
+ void FindRootScrollLayer();
+ void UpdateMaxScrollOffset();
void SetViewportLayersFromIds(int page_scale_layer_id,
int inner_viewport_scroll_layer_id,
int outer_viewport_scroll_layer_id);
void ClearViewportLayers();
- LayerImpl* page_scale_layer() { return page_scale_layer_; }
void ApplySentScrollAndScaleDeltasFromAbortedCommit();
void ApplyScrollDeltasSinceBeginMainFrame();
@@ -214,8 +207,6 @@ class CC_EXPORT LayerTreeImpl {
void SetRootLayerScrollOffsetDelegate(
LayerScrollOffsetDelegate* root_layer_scroll_offset_delegate);
- void UpdateScrollOffsetDelegate();
- gfx::Vector2dF GetDelegatedScrollOffset(LayerImpl* layer);
// Call this function when you expect there to be a swap buffer.
// See swap_promise.h for how to use SwapPromise.
@@ -240,18 +231,17 @@ class CC_EXPORT LayerTreeImpl {
protected:
explicit LayerTreeImpl(LayerTreeHostImpl* layer_tree_host_impl);
+ void UpdateSolidColorScrollbars();
+
void UpdateRootScrollLayerSizeDelta();
LayerTreeHostImpl* layer_tree_host_impl_;
int source_frame_number_;
scoped_ptr<LayerImpl> root_layer_;
HeadsUpDisplayLayerImpl* hud_layer_;
+ LayerImpl* root_scroll_layer_;
LayerImpl* currently_scrolling_layer_;
LayerScrollOffsetDelegate* root_layer_scroll_offset_delegate_;
- scoped_ptr<LayerScrollOffsetDelegateProxy>
- inner_viewport_scroll_delegate_proxy_;
- scoped_ptr<LayerScrollOffsetDelegateProxy>
- outer_viewport_scroll_delegate_proxy_;
SkColor background_color_;
bool has_transparent_background_;