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

Side by Side Diff: android_webview/browser/browser_view_renderer.h

Issue 256303006: Make LayerScrollOffsetDelegate updates consistent. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: less jni Created 6 years, 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef ANDROID_WEBVIEW_BROWSER_BROWSER_VIEW_RENDERER_H_ 5 #ifndef ANDROID_WEBVIEW_BROWSER_BROWSER_VIEW_RENDERER_H_
6 #define ANDROID_WEBVIEW_BROWSER_BROWSER_VIEW_RENDERER_H_ 6 #define ANDROID_WEBVIEW_BROWSER_BROWSER_VIEW_RENDERER_H_
7 7
8 #include "android_webview/browser/shared_renderer_state.h" 8 #include "android_webview/browser/shared_renderer_state.h"
9 #include "base/android/scoped_java_ref.h" 9 #include "base/android/scoped_java_ref.h"
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 // immediately discarded. This is a hack to force invoke parts of the 105 // immediately discarded. This is a hack to force invoke parts of the
106 // compositor that are not directly exposed here. 106 // compositor that are not directly exposed here.
107 void ForceFakeCompositeSW(); 107 void ForceFakeCompositeSW();
108 108
109 // SynchronousCompositorClient overrides 109 // SynchronousCompositorClient overrides
110 virtual void DidInitializeCompositor( 110 virtual void DidInitializeCompositor(
111 content::SynchronousCompositor* compositor) OVERRIDE; 111 content::SynchronousCompositor* compositor) OVERRIDE;
112 virtual void DidDestroyCompositor(content::SynchronousCompositor* compositor) 112 virtual void DidDestroyCompositor(content::SynchronousCompositor* compositor)
113 OVERRIDE; 113 OVERRIDE;
114 virtual void SetContinuousInvalidate(bool invalidate) OVERRIDE; 114 virtual void SetContinuousInvalidate(bool invalidate) OVERRIDE;
115 virtual void SetMaxRootLayerScrollOffset(gfx::Vector2dF new_value) OVERRIDE; 115 virtual void SetTotalRootLayerScrollOffset(
116 virtual void SetTotalRootLayerScrollOffset(gfx::Vector2dF new_value_css) 116 gfx::Vector2dF new_value_dip) OVERRIDE;
117 OVERRIDE;
118 virtual void DidUpdateContent() OVERRIDE; 117 virtual void DidUpdateContent() OVERRIDE;
119 virtual gfx::Vector2dF GetTotalRootLayerScrollOffset() OVERRIDE; 118 virtual gfx::Vector2dF GetTotalRootLayerScrollOffset() OVERRIDE;
120 virtual bool IsExternalFlingActive() const OVERRIDE; 119 virtual bool IsExternalFlingActive() const OVERRIDE;
121 virtual void SetRootLayerPageScaleFactorAndLimits(float page_scale_factor, 120 virtual void UpdateRootLayerState(
122 float min_page_scale_factor, 121 const gfx::Vector2dF& total_scroll_offset_dip,
123 float max_page_scale_factor) 122 const gfx::Vector2dF& max_scroll_offset_dip,
124 OVERRIDE; 123 const gfx::SizeF& scrollable_size_dip,
125 virtual void SetRootLayerScrollableSize(gfx::SizeF scrollable_size) OVERRIDE; 124 float page_scale_factor,
125 float min_page_scale_factor,
126 float max_page_scale_factor) OVERRIDE;
126 virtual void DidOverscroll(gfx::Vector2dF accumulated_overscroll, 127 virtual void DidOverscroll(gfx::Vector2dF accumulated_overscroll,
127 gfx::Vector2dF latest_overscroll_delta, 128 gfx::Vector2dF latest_overscroll_delta,
128 gfx::Vector2dF current_fling_velocity) OVERRIDE; 129 gfx::Vector2dF current_fling_velocity) OVERRIDE;
129 130
130 private: 131 private:
131 // Checks the continuous invalidate and block invalidate state, and schedule 132 // Checks the continuous invalidate and block invalidate state, and schedule
132 // invalidates appropriately. If |force_invalidate| is true, then send a view 133 // invalidates appropriately. If |force_invalidate| is true, then send a view
133 // invalidate regardless of compositor expectation. 134 // invalidate regardless of compositor expectation.
134 void EnsureContinuousInvalidation(bool force_invalidate); 135 void EnsureContinuousInvalidation(bool force_invalidate);
135 bool DrawSWInternal(jobject java_canvas, const gfx::Rect& clip_bounds); 136 bool DrawSWInternal(jobject java_canvas, const gfx::Rect& clip_bounds);
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
198 // visible skew (especially noticeable when scrolling up and down in the same 199 // visible skew (especially noticeable when scrolling up and down in the same
199 // spot over a period of time). 200 // spot over a period of time).
200 gfx::Vector2dF overscroll_rounding_error_; 201 gfx::Vector2dF overscroll_rounding_error_;
201 202
202 DISALLOW_COPY_AND_ASSIGN(BrowserViewRenderer); 203 DISALLOW_COPY_AND_ASSIGN(BrowserViewRenderer);
203 }; 204 };
204 205
205 } // namespace android_webview 206 } // namespace android_webview
206 207
207 #endif // ANDROID_WEBVIEW_BROWSER_BROWSER_VIEW_RENDERER_H_ 208 #endif // ANDROID_WEBVIEW_BROWSER_BROWSER_VIEW_RENDERER_H_
OLDNEW
« no previous file with comments | « no previous file | android_webview/browser/browser_view_renderer.cc » ('j') | android_webview/browser/browser_view_renderer.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698