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

Issue 2502533002: Mac: Always layout the Download Shelf, even if it has zero height. (Closed)

Created:
4 years, 1 month ago by tapted
Modified:
4 years, 1 month ago
Reviewers:
erikchen
CC:
chromium-reviews, mac-reviews_chromium.org, chrome-apps-syd-reviews_chromium.org
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Mac: Always layout the Download Shelf, even if it has zero height. Even when the download shelf has zero height, Cocoa autolayout can change its width. It does this when going fullscreen. However, not when exiting fullscreen. If the download shelf is visible (i.e. has non-zero height), then -[BrowserWindowController applyLayout:] does the layout instead. However, currently that layout is skipped if the download shelf is hidden. This can leave the download shelf with a stale width that influences the Cocoa autolayout applied when the browser window is user-resized. This, in turn, can result in the browser window refusing to violate a constraint that would break when the browser window is resized to be small. To fix, always set the download shelf frame, even if it has zero height. This ensures the width is valid, even when hidden. BUG=664477 TEST=On Mac (10.11 or 10.12) Open a new browser window (without a download shelf). Resize the window to be "large", then make it fullscreen (e.g. Cmd+Ctrl+f). Exit fullscreen (e.g. Cmd+Ctrl+f), then resize the window again to try to make it "small". Ensure the width can be made small as normal. Committed: https://crrev.com/d8b183ffcfbb18293f623615017bc2e25b023906 Cr-Commit-Position: refs/heads/master@{#432024}

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+1 line, -2 lines) Patch
M chrome/browser/ui/cocoa/browser_window_controller_private.mm View 1 chunk +1 line, -2 lines 0 comments Download

Messages

Total messages: 14 (5 generated)
tapted
Erik? Could please take a look? (+sdy cc - I think you've been looking at ...
4 years, 1 month ago (2016-11-14 05:31:40 UTC) #3
erikchen
lgtm I suspect we want something similar for bookmarkFrame, etc., but those layout methods will ...
4 years, 1 month ago (2016-11-14 18:29:50 UTC) #4
erikchen
On 2016/11/14 18:29:50, erikchen wrote: > lgtm > > I suspect we want something similar ...
4 years, 1 month ago (2016-11-14 18:39:14 UTC) #5
Sidney San Martín
On 2016/11/14 at 18:39:14, erikchen wrote: > Woah. When did we opt into autolayout anywhere? ...
4 years, 1 month ago (2016-11-14 18:43:42 UTC) #6
lgrey
On 2016/11/14 18:43:42, Sidney San Martín wrote: > On 2016/11/14 at 18:39:14, erikchen wrote: > ...
4 years, 1 month ago (2016-11-14 19:27:13 UTC) #7
tapted
On 2016/11/14 18:39:14, erikchen wrote: > On 2016/11/14 18:29:50, erikchen wrote: > > lgtm > ...
4 years, 1 month ago (2016-11-14 23:27:41 UTC) #8
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/2502533002/1
4 years, 1 month ago (2016-11-14 23:30:12 UTC) #10
commit-bot: I haz the power
Committed patchset #1 (id:1)
4 years, 1 month ago (2016-11-15 00:42:27 UTC) #12
commit-bot: I haz the power
4 years, 1 month ago (2016-11-15 00:50:37 UTC) #14
Message was sent while issue was closed.
Patchset 1 (id:??) landed as
https://crrev.com/d8b183ffcfbb18293f623615017bc2e25b023906
Cr-Commit-Position: refs/heads/master@{#432024}

Powered by Google App Engine
This is Rietveld 408576698