diff options
author | danakj <danakj@chromium.org> | 2015-09-09 14:36:16 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-09-09 21:37:01 +0000 |
commit | e9f830c3b57371a0b3d090f48be2545a58eba3d6 (patch) | |
tree | 273dd1a308ceeb80d66cc96fab9d6e7ebdfa0f97 /cc/input | |
parent | a2c9f2ae93b9920f1ddeb01042e9b1a431106e71 (diff) | |
download | chromium_src-e9f830c3b57371a0b3d090f48be2545a58eba3d6.zip chromium_src-e9f830c3b57371a0b3d090f48be2545a58eba3d6.tar.gz chromium_src-e9f830c3b57371a0b3d090f48be2545a58eba3d6.tar.bz2 |
Move the AnimateInput paths for WebView around to not path through cc.
They don't need to go through cc, so let's not and this lets cc reason
about when/how things happen better.
Adds 2 new interfaces:
- SynchronousInputHandlerProxy. A limited view of the InputHandlerProxy
given out to WebView to control animating timing. It lets WebView call
SynchronouslyAnimate() to do animations. And if cc tried to also animate,
we'd hit a DCHECK.
- SynchronousInputHandler. An interface given to the InputHandlerProxy
as an alternate place to handle requests for animation. When it's
present animate requests go there instead of the usual InputHandler.
R=boliu, enne, hush, jdduke, sievers
BUG=522658
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel
Review URL: https://codereview.chromium.org/1307203003
Cr-Commit-Position: refs/heads/master@{#348014}
Diffstat (limited to 'cc/input')
-rw-r--r-- | cc/input/input_handler.h | 6 | ||||
-rw-r--r-- | cc/input/layer_scroll_offset_delegate.h | 5 |
2 files changed, 5 insertions, 6 deletions
diff --git a/cc/input/input_handler.h b/cc/input/input_handler.h index 4852bdc..67a2c57 100644 --- a/cc/input/input_handler.h +++ b/cc/input/input_handler.h @@ -143,9 +143,13 @@ class CC_EXPORT InputHandler { // Request another callback to InputHandlerClient::Animate(). virtual void SetNeedsAnimateInput() = 0; + // If there is a scroll active, this reports whether the scroll is on the + // root layer, or on some other sublayer. + virtual bool IsCurrentlyScrollingRoot() const = 0; + // Whether the layer under |viewport_point| is the currently scrolling layer. virtual bool IsCurrentlyScrollingLayerAt(const gfx::Point& viewport_point, - ScrollInputType type) = 0; + ScrollInputType type) const = 0; virtual bool HaveWheelEventHandlersAt(const gfx::Point& viewport_point) = 0; diff --git a/cc/input/layer_scroll_offset_delegate.h b/cc/input/layer_scroll_offset_delegate.h index a0c0e0d..afd6e4b 100644 --- a/cc/input/layer_scroll_offset_delegate.h +++ b/cc/input/layer_scroll_offset_delegate.h @@ -44,11 +44,6 @@ class LayerScrollOffsetDelegate { float min_page_scale_factor, float max_page_scale_factor) = 0; - // This is called by the compositor when a fling hitting the root layer - // requires a scheduled animation update. - typedef base::Callback<void(base::TimeTicks)> AnimationCallback; - virtual void SetNeedsAnimate(const AnimationCallback& animation) = 0; - protected: LayerScrollOffsetDelegate() {} virtual ~LayerScrollOffsetDelegate() {} |