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

Issue 2656633003: Changing URL bar constraints only calls performResize on Hidden <-> Both (Closed)

Created:
3 years, 11 months ago by bokan
Modified:
3 years, 11 months ago
CC:
blink-reviews, chromium-reviews, kinuko+watch
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Changing URL bar constraints only calls performResize on Hidden <-> Both With the change to the URL bar not causing a vertical resize on showing/hiding, we keep the layout height sized "as if" the URL bar was always shown. However, for fullscreen scenarios, since the URL bar is locked to a hidden state there's no need to keep it static to the smaller size so we use the full viewport height instead. This means that when we change the URL bar constraints we may need to change the layout height. In most cases, we can rely on a Resize event being sent to the renderer kicking off the layout size change. The one exception here is from a "Locked Hidden" to "Unlocked" state, or vice-versa. That's because the URL bar's state might not change (it can remain hidden) but the layout size should change. Note that going from "Locked Hidden" -> "Shown" doesn't have this problem as the URL bar state will change necessarily. Going from "Unlocked" -> "Shown" may or may not change the URL bar state, but it will not change the layout height since we use the "Shown" height for layout height when the URL bar is "Unlocked". Before this patch, we were overly-aggressive in triggering performResize which caused us to perform extra work as the page went from "Locked Shown" to "Unlocked", as happens when the page is navigated. This caused a minor memory regression. This patch performs the resize only when needed, on going from "Locked Hidden" to "Unlocked" or vice-versa. BUG=679546 Review-Url: https://codereview.chromium.org/2656633003 Cr-Commit-Position: refs/heads/master@{#445855} Committed: https://chromium.googlesource.com/chromium/src/+/38992dee686ca58d5f1a61d44ef3e534b8c2967c

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+8 lines, -6 lines) Patch
M third_party/WebKit/Source/web/WebViewImpl.cpp View 1 chunk +8 lines, -6 lines 0 comments Download

Messages

Total messages: 22 (17 generated)
bokan
3 years, 11 months ago (2017-01-24 23:06:48 UTC) #15
aelias_OOO_until_Jul13
lgtm
3 years, 11 months ago (2017-01-24 23:18:02 UTC) #16
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2656633003/1
3 years, 11 months ago (2017-01-24 23:19:22 UTC) #18
commit-bot: I haz the power
Committed patchset #1 (id:1) as https://chromium.googlesource.com/chromium/src/+/38992dee686ca58d5f1a61d44ef3e534b8c2967c
3 years, 11 months ago (2017-01-24 23:27:09 UTC) #21
bokan
3 years, 11 months ago (2017-01-26 15:55:31 UTC) #22
Message was sent while issue was closed.
A revert of this CL (patchset #1 id:1) has been created in
https://codereview.chromium.org/2659483003/ by bokan@chromium.org.

The reason for reverting is: Didn't help on the perf bots. Temporarily reverting
along with orignial patch to investigate..

Powered by Google App Engine
This is Rietveld 408576698