New issue
Advanced search Search tips

Issue 770693 link

Starred by 3 users

Issue metadata

Status: Verified
Owner:
Closed: Oct 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: iOS
Pri: 1
Type: Bug



Sign in to add a comment

Show a normal-sized toolbar in landscape on the iPhone X.

Project Member Reported by jif@chromium.org, Oct 2 2017

Issue description

Currently the toolbar is huge on the iPhone X in landscape.
The toolbar should be re-relayed out when the status bar height changes.
 
landscapeBeforeRotate.png
182 KB View Download

Comment 1 by pkl@chromium.org, Oct 2 2017

Components: UI>Browser>Toolbar
Labels: -Pri-3 Pri-2

Comment 2 Deleted

Project Member

Comment 3 by bugdroid1@chromium.org, Oct 11 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/ed4cde72c45ebba1112b17d0651e7b64de77b98c

commit ed4cde72c45ebba1112b17d0651e7b64de77b98c
Author: Jean-François Geyelin <jif@chromium.org>
Date: Wed Oct 11 11:34:50 2017

[iOS] Resize toolbar when the safe area changes.

This CL adds an experimental flag, and makes the Toolbar be resized
when the Safe Area changes when the experimental flag is enabled.

The subviews of the Toolbar and WebToolbar are now bottom aligned,
with a flexible top margin. This allows changing the height of the
toolbar.
The WebToolbar's clipping view is an exception: it can't be
laid out with autoresizing masks because its frame must change according
to its _superview's superview_ height.
For reason I don't understand setting a constraint between the clipping
view's height and its superview's superview's height did not work.

The frame of the Toolbar is set by the owners of the Toolbar:
the BVC or the NTPHeaderView. They both need to listen for when
the safe area changes, so that they can update the height of the
toolbar accordingly.

The Stack View and Pull To Action are not handled yet.

What it looks like after this CL:
https://drive.google.com/open?id=0Bw-kA2pwDsU-TjBPZDlJODA4TEU

Bug:  770693 
Change-Id: I5b2ff14934a14584e0d9b68b8b9ba8ee94ac6112
Reviewed-on: https://chromium-review.googlesource.com/698067
Commit-Queue: Jean-François Geyelin <jif@chromium.org>
Reviewed-by: Rohit Rao (ping after 24h) <rohitrao@chromium.org>
Cr-Commit-Position: refs/heads/master@{#507950}
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/BUILD.gn
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/about_flags.mm
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ios_chrome_flag_descriptions.cc
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ios_chrome_flag_descriptions.h
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ui/BUILD.gn
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ui/browser_view_controller.mm
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ui/ntp/BUILD.gn
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ui/ntp/new_tab_page_header_view.mm
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ui/toolbar/BUILD.gn
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ui/toolbar/toolbar_controller.h
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ui/toolbar/toolbar_controller.mm
[add] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ui/toolbar/toolbar_controller_base_feature.h
[add] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ui/toolbar/toolbar_controller_base_feature.mm
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ui/toolbar/toolbar_view.mm
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ui/toolbar/web_toolbar_controller.mm
[modify] https://crrev.com/ed4cde72c45ebba1112b17d0651e7b64de77b98c/ios/chrome/browser/ui/ui_util.mm

Comment 4 by cma...@chromium.org, Oct 19 2017

Hey jif@ is this now fixed?

Comment 5 by jif@chromium.org, Oct 20 2017

The fix is behind an experimental flag.
Problem is that it breaks the StackView in many ways.

Comment 6 by jif@chromium.org, Oct 24 2017

Status: Fixed (was: Started)
Going to mark this as fixed and file more specific bugs.
Labels: Merge-TBD
[Auto-generated comment by a script] We noticed that this issue is targeted for M-63; it appears the fix may have landed after branch point, meaning a merge might be required. Please confirm if a merge is required here - if so add Merge-Request-63 label, otherwise remove Merge-TBD label. Thanks.
Cc: justincohen@chromium.org
Owner: pkl@chromium.org
Assigning to you Peter. Do we have plan to merge this again?
Labels: -Pri-2 Pri-1

Comment 10 by pkl@chromium.org, Nov 8 2017

Shouldn't this be M-64? We've "accepted" that toolbar height will be "too tall" for M-63.
gambard@ what cherry picks would it take to get M63 to where 64 is with the toolbar?  How bad is that?
Labels: -M-63 M-64
 Issue 781695  has been merged into this issue.
pkl@ should this be merged in M64?
Cc: gambard@chromium.org
Labels: -Merge-TBD
That Merge-TBD flag is from October, for M63.  Removing, as this fix is in M64 with the safe area enabled toolbar.
Status: Verified (was: Fixed)
Issue verified 
Version: 64.0.3282.81 beta
Device: iPhoneX
iOS: 11.1

https://drive.google.com/open?id=1j59oXWUZjL4ayh2Wq9WbLYoUeXqT-TS0
https://drive.google.com/open?id=1u5_ZRJfeyTyY1kADbYMAF_i1mHsRO0eE

Sign in to add a comment