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

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

Issue 23533051: [android_webview] Use a fraction to calculate scroll offset. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: get rid of NaNs Created 7 years, 2 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 "base/android/scoped_java_ref.h" 8 #include "base/android/scoped_java_ref.h"
9 #include "skia/ext/refptr.h" 9 #include "skia/ext/refptr.h"
10 #include "ui/gfx/point.h" 10 #include "ui/gfx/point.h"
(...skipping 30 matching lines...) Expand all
41 41
42 // Synchronously call back to SetGlobalVisibleRect with current value. 42 // Synchronously call back to SetGlobalVisibleRect with current value.
43 virtual void UpdateGlobalVisibleRect() = 0; 43 virtual void UpdateGlobalVisibleRect() = 0;
44 44
45 // Called to get view's absolute location on the screen. 45 // Called to get view's absolute location on the screen.
46 virtual gfx::Point GetLocationOnScreen() = 0; 46 virtual gfx::Point GetLocationOnScreen() = 0;
47 47
48 // Try to set the view's scroll offset to |new_value|. 48 // Try to set the view's scroll offset to |new_value|.
49 virtual void ScrollContainerViewTo(gfx::Vector2d new_value) = 0; 49 virtual void ScrollContainerViewTo(gfx::Vector2d new_value) = 0;
50 50
51 // Set the view's scroll offset cap to |new_value|.
52 virtual void SetMaxContainerViewScrollOffset(gfx::Vector2d new_value) = 0;
53
51 // Handle overscroll. 54 // Handle overscroll.
52 virtual void DidOverscroll(gfx::Vector2d overscroll_delta) = 0; 55 virtual void DidOverscroll(gfx::Vector2d overscroll_delta) = 0;
53 56
54 protected: 57 protected:
55 virtual ~Client() {} 58 virtual ~Client() {}
56 }; 59 };
57 60
58 // Delegate to perform rendering actions involving Java objects. 61 // Delegate to perform rendering actions involving Java objects.
59 class JavaHelper { 62 class JavaHelper {
60 public: 63 public:
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 virtual bool IsAttachedToWindow() = 0; 134 virtual bool IsAttachedToWindow() = 0;
132 virtual bool IsVisible() = 0; 135 virtual bool IsVisible() = 0;
133 virtual gfx::Rect GetScreenRect() = 0; 136 virtual gfx::Rect GetScreenRect() = 0;
134 137
135 virtual ~BrowserViewRenderer() {} 138 virtual ~BrowserViewRenderer() {}
136 }; 139 };
137 140
138 } // namespace android_webview 141 } // namespace android_webview
139 142
140 #endif // ANDROID_WEBVIEW_BROWSER_BROWSER_VIEW_RENDERER_H_ 143 #endif // ANDROID_WEBVIEW_BROWSER_BROWSER_VIEW_RENDERER_H_
OLDNEW
« no previous file with comments | « no previous file | android_webview/browser/in_process_view_renderer.h » ('j') | android_webview/browser/in_process_view_renderer.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698