New issue
Advanced search Search tips

Issue 845534 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: May 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: iOS
Pri: 1
Type: Bug



Sign in to add a comment

Collections: Rotating with a context menu visible breaks tableview layout

Project Member Reported by rohitrao@chromium.org, May 22 2018

Issue description

1) Put an iPad in 25/75 mode in landscape, with Chromium on the 75% side.
2) Open History with the UIRefresh flag enabled.
3) Long press on an item to show a context menu.
4) Rotate the device into portrait, so that the split becomes 33/66.  This will change Chromium's size class from regular to compact.
5) Rotate back to landscape, so that Chromium goes back to a Regular width.

The UITableView will incorrectly be offset inside the presentation bubble, instead of filling the bubble exactly.  Note that this only happens when another VC (such as a context menu) is presented on top of the tableview.

The UITableView is set to fill its parent with an autoresizing mask, but somehow its origin is getting modified.  We can fix this by adding code in containerViewWillLayoutSubviews to forcibly set the table view's frame before running the layout pass.
 
Project Member

Comment 1 by bugdroid1@chromium.org, May 22 2018

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

commit aa0671241e4fa544d9a7d3709348a2227db5f722
Author: Rohit Rao <rohitrao@chromium.org>
Date: Tue May 22 21:04:06 2018

[ios] Fixes Collections layout issues when showing context menus.

Rotating or exiting multitasking while a context menu was visible would
result in the Collections tableviews being offset within the bubble.
Fixes this bug by forcing the tableview to fill its parent before
running the layout pass.

BUG= 845534 

Cq-Include-Trybots: luci.chromium.try:ios-simulator-full-configs;master.tryserver.chromium.mac:ios-simulator-cronet
Change-Id: I72f1ab1d33d2b8ca22a32c9161e6eeaf561c7844
Reviewed-on: https://chromium-review.googlesource.com/1067866
Reviewed-by: Sergio Collazos <sczs@chromium.org>
Commit-Queue: Rohit Rao <rohitrao@chromium.org>
Cr-Commit-Position: refs/heads/master@{#560772}
[modify] https://crrev.com/aa0671241e4fa544d9a7d3709348a2227db5f722/ios/chrome/browser/ui/table_view/table_view_presentation_controller.mm

Status: Fixed (was: Started)

Sign in to add a comment