Commit 0c93cd87 authored by bokan's avatar bokan Committed by Commit bot

Adjust maximum scroll bounds on FrameView to account for top controls. (Chromium-side)

The compositor adjusts the viewport bounds based on how far the top
controls are shown; however, the resize of the viewport on the Blink
side doesn't happen until a Resize event is received, which is heavily
throttled. This means that when a commit happens before the Resize,
the scroll offsets given to Blink may be outside the maximum bounds
and will be incorrectly clamped.

This CL adjusts FrameView's maximumScrollPosition to account for the
drift in where Blink and the Compositor think the top controls are.

Blink-side: https://codereview.chromium.org/560623002/

BUG=412581

Review URL: https://codereview.chromium.org/563513002

Cr-Commit-Position: refs/heads/master@{#297478}
parent f7571f31
...@@ -681,6 +681,8 @@ void RenderWidget::Resize(const gfx::Size& new_size, ...@@ -681,6 +681,8 @@ void RenderWidget::Resize(const gfx::Size& new_size,
WillToggleFullscreen(); WillToggleFullscreen();
is_fullscreen_ = is_fullscreen; is_fullscreen_ = is_fullscreen;
webwidget_->setTopControlsLayoutHeight(top_controls_layout_height);
if (size_ != new_size) { if (size_ != new_size) {
size_ = new_size; size_ = new_size;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment