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

Unified Diff: android_webview/browser/browser_view_renderer.h

Issue 1556733002: Restore scrolloffset after exiting fullscreen. Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: restore only when the page scale factor is back to the initial value Created 5 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | android_webview/browser/browser_view_renderer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: android_webview/browser/browser_view_renderer.h
diff --git a/android_webview/browser/browser_view_renderer.h b/android_webview/browser/browser_view_renderer.h
index 128b5cd55589556517850ad1e2bdc2957580d004..2150646045693f6deaab039c7fde4edc608689ac 100644
--- a/android_webview/browser/browser_view_renderer.h
+++ b/android_webview/browser/browser_view_renderer.h
@@ -107,9 +107,9 @@ class BrowserViewRenderer : public content::SynchronousCompositorClient {
void DidBecomeCurrent(content::SynchronousCompositor* compositor) override;
void PostInvalidate() override;
void DidUpdateContent() override;
- void UpdateRootLayerState(const gfx::Vector2dF& total_scroll_offset_dip,
- const gfx::Vector2dF& max_scroll_offset_dip,
- const gfx::SizeF& scrollable_size_dip,
+ void UpdateRootLayerState(const gfx::Vector2dF& total_scroll_offset_css,
+ const gfx::Vector2dF& max_scroll_offset_css,
+ const gfx::SizeF& scrollable_size_css,
float page_scale_factor,
float min_page_scale_factor,
float max_page_scale_factor) override;
@@ -121,7 +121,7 @@ class BrowserViewRenderer : public content::SynchronousCompositorClient {
void DetachFunctorFromView();
private:
- void SetTotalRootLayerScrollOffset(const gfx::Vector2dF& new_value_dip);
+ void SetTotalRootLayerScrollOffset(const gfx::Vector2dF& new_value_css);
bool CanOnDraw();
// Posts an invalidate with fallback tick. All invalidates posted while an
// invalidate is pending will be posted as a single invalidate after the
@@ -131,8 +131,8 @@ class BrowserViewRenderer : public content::SynchronousCompositorClient {
void UpdateCompositorIsActive();
bool CompositeSW(SkCanvas* canvas);
scoped_refptr<base::trace_event::ConvertableToTraceFormat>
- RootLayerStateAsValue(const gfx::Vector2dF& total_scroll_offset_dip,
- const gfx::SizeF& scrollable_size_dip);
+ RootLayerStateAsValue(const gfx::Vector2dF& total_scroll_offset_css,
+ const gfx::SizeF& scrollable_size_css);
bool CompositeHw();
void ReturnUnusedResource(scoped_ptr<ChildFrame> frame);
@@ -194,15 +194,15 @@ class BrowserViewRenderer : public content::SynchronousCompositorClient {
gfx::Size size_;
- gfx::SizeF scrollable_size_dip_;
+ gfx::SizeF scrollable_size_css_;
// Current scroll offset in CSS pixels.
- // TODO(miletus): Make scroll_offset_dip_ a gfx::ScrollOffset.
- gfx::Vector2dF scroll_offset_dip_;
+ // TODO(miletus): Make scroll_offset_css_ a gfx::ScrollOffset.
+ gfx::Vector2dF scroll_offset_css_;
// Max scroll offset in CSS pixels.
- // TODO(miletus): Make max_scroll_offset_dip_ a gfx::ScrollOffset.
- gfx::Vector2dF max_scroll_offset_dip_;
+ // TODO(miletus): Make max_scroll_offset_css_ a gfx::ScrollOffset.
+ gfx::Vector2dF max_scroll_offset_css_;
// Used to prevent rounding errors from accumulating enough to generate
// visible skew (especially noticeable when scrolling up and down in the same
« no previous file with comments | « no previous file | android_webview/browser/browser_view_renderer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698