New issue
Advanced search Search tips

Issue 836182 link

Starred by 2 users

Issue metadata

Status: Verified
Owner:
Closed: Apr 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows
Pri: 1
Type: Bug-Regression



Sign in to add a comment

Regression: Unable to resize the omnibox in order to show the extension icon in toolbar

Reported by khushal....@etouch.net, Apr 24 2018

Issue description

Chrome Version: 67.0.3396.18 (Official Build) Revision	399b73768e46f9219d4868a2ad1ccb517da5347d-refs/branch-heads/3396@{#251}  (32/64-bit).
 
OS: Win (7, 8, 8.1, 10) and Linux (14.04 LTS).

Pre-condition: Install any 1 extension in chrome.

Steps to reproduce:
1. Launch chrome and navigate to chrome://extensions/
2. Drag the installed extension in to wrench menu.
3. Turn OFF the toggle of installed extension and then turn ON the toggle again.
4. Now try to resize the omnibox to show extension again in toolbar or try to drag the extension from wrench menu to toolbar.
 
Actual Result:
1) Unable to resize the omnibox in order to show the extension icon in toolbar.
2) Unable to drag extension icon from wrench menu to toolbar.

Expected Result:
1) Should be able to resize the omnibox in order to show the extension icon in toolbar.
2) Should be able to drag extension icon from wrench menu to toolbar.

This is Regression issue broken in 'M-67’ and using the per-revision bisect providing the bisect results,

Good Build: 67.0.3378.0 (Revision: 544932)
Bad Build:  67.0.3379.0 (Revision: 545319)

You are probably looking for a change made after 544962 (known good), but no later than 544963 (first known bad).

CHANGE-LOG URL:

The script might not always return single CL as suspect as some perf builds might get missing due to failure.

https://chromium.googlesource.com/chromium/src/+log/fae199abc147d925470e745e0fa2752775d4fa63..bd465948ea74fbf1d40c495832e4306c07c13406

Suspect: https://chromium.googlesource.com/chromium/src/+/bd465948ea74fbf1d40c495832e4306c07c13406

@afakhry: Could you please check whether this is caused with respect to your change, if not please help us in assigning it to the right owner.

Note:
1) Issue is also seen on M-68 Canary (build #68.0.3405.0).
2) Issue is not seen on Mac OS (10.12.6, 10.13.1, 10.13.5).

Kindly refer attached screen cast.

Thank You..!!

 
Actual Video.mp4
865 KB View Download
Expected Video.mp4
795 KB View Download
Cc: afakhry@chromium.org bsep@chromium.org pkasting@chromium.org
Components: UI>Browser>Toolbar
Owner: pbos@chromium.org
This was caused by https://chromium-review.googlesource.com/c/chromium/src/+/1011343 since BrowserActionsContainer::GetWidth() now clamps down to 0, rather than `toolbar_actions_bar_->GetMinimumWidth()`. 

As a result, in ToolbarActionsBar::ResizeDelegate() [1] which is called from ToolbarActionsBar::OnToolbarActionAdded() [2], the desired_width is 0 (since the omnibox was resized so that extension moves to the menu before the extension was disabled and reenabled). BrowserActionsContainer::GetWidth() returns 0 as well, so we endup calling `delegate_->Redraw(false);` rather than calling `delegate_->ResizeAndAnimate(tween_type, desired_width);`

Clamping down to `toolbar_actions_bar_->GetMinimumWidth()` fixes the problem. But I'm not sure if that works for the recently added separator area work. pbos@ can you please take a look?

[1]: https://cs.chromium.org/chromium/src/chrome/browser/ui/toolbar/toolbar_actions_bar.cc?type=cs&q=ToolbarActionsBar::ResizeDelegate&sq=package:chromium&l=687

[2]: https://cs.chromium.org/chromium/src/chrome/browser/ui/toolbar/toolbar_actions_bar.cc?type=cs&q=ToolbarActionsBar::OnToolbarActionAdded&sq=package:chromium&l=609

Comment 2 by pbos@chromium.org, Apr 25 2018

At a glance I think it should be fine, but this will break returning zero when width() does, so maybe we need to special case that if we need to handle the too-tiny-for-resize-handle case. WDYT?
Project Member

Comment 3 by bugdroid1@chromium.org, Apr 27 2018

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

commit 95bff1bfd712ccb5f7ad4bfdeaf4ceb26ad0aedf
Author: Peter Boström <pbos@chromium.org>
Date: Fri Apr 27 00:07:01 2018

Clamp BrowserActionsContainer::GetWidth()

This fixes an issue where the browser actions bar disappears after
disabling the last extension (intended) and cannot come. Before this
change when re-enabling an extension the bar would not be resized to
include its resize handle so it could not be pulled to bring out the
newly added extension.

The fix seems fairly safe which is good as it needs to be merged into
M67. I'm intending to revisit this part of the code as part of cleanup
work to unify ToolbarActionsBar and BrowserActionsContainer.

Bug:  chromium:836182 
Change-Id: I2a196edc867ec70dd74aa4690576540b31548b97
Reviewed-on: https://chromium-review.googlesource.com/1030891
Commit-Queue: Peter Boström <pbos@chromium.org>
Reviewed-by: Bret Sepulveda <bsep@chromium.org>
Reviewed-by: Ahmed Fakhry <afakhry@chromium.org>
Cr-Commit-Position: refs/heads/master@{#554202}
[modify] https://crrev.com/95bff1bfd712ccb5f7ad4bfdeaf4ceb26ad0aedf/chrome/browser/ui/views/toolbar/browser_actions_container.cc

Labels: TE-Verified-68.0.3410.0 TE-Verified-M68
Rechecked the above issue on latest Canary build #68.0.3410.0 for Windows OS (7, 8, 8.1, 10) and Linux OS (14.04 LTS) and the issue is fixed.
Please refer the attached screencast.
Fixed Video.mp4
466 KB View Download

Comment 5 by pbos@chromium.org, Apr 27 2018

Labels: Merge-Request-67
Thank you!

Comment 6 by pbos@chromium.org, Apr 27 2018

Additional info for merge request: Without this fix the browser actions will be invisible and unusable when going from zero enabled to more extensions. It's pretty user visible and feels very broken.

Comment 7 by gov...@chromium.org, Apr 27 2018

Labels: -Merge-Request-67 Merge-Approved-67
Approving merge to M67 branch 3396 based on comment #4 and #6. Please merge ASAP. Thank you.
Project Member

Comment 8 by bugdroid1@chromium.org, Apr 27 2018

Labels: -merge-approved-67 merge-merged-3396
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/660c34994165eea303bd6f4bf6254be642786111

commit 660c34994165eea303bd6f4bf6254be642786111
Author: Peter Boström <pbos@chromium.org>
Date: Fri Apr 27 18:35:17 2018

Clamp BrowserActionsContainer::GetWidth()

This fixes an issue where the browser actions bar disappears after
disabling the last extension (intended) and cannot come. Before this
change when re-enabling an extension the bar would not be resized to
include its resize handle so it could not be pulled to bring out the
newly added extension.

The fix seems fairly safe which is good as it needs to be merged into
M67. I'm intending to revisit this part of the code as part of cleanup
work to unify ToolbarActionsBar and BrowserActionsContainer.

Bug:  chromium:836182 
Change-Id: I2a196edc867ec70dd74aa4690576540b31548b97
Reviewed-on: https://chromium-review.googlesource.com/1030891
Commit-Queue: Peter Boström <pbos@chromium.org>
Reviewed-by: Bret Sepulveda <bsep@chromium.org>
Reviewed-by: Ahmed Fakhry <afakhry@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#554202}(cherry picked from commit 95bff1bfd712ccb5f7ad4bfdeaf4ceb26ad0aedf)
Reviewed-on: https://chromium-review.googlesource.com/1033395
Reviewed-by: Peter Boström <pbos@chromium.org>
Cr-Commit-Position: refs/branch-heads/3396@{#355}
Cr-Branched-From: 9ef2aa869bc7bc0c089e255d698cca6e47d6b038-refs/heads/master@{#550428}
[modify] https://crrev.com/660c34994165eea303bd6f4bf6254be642786111/chrome/browser/ui/views/toolbar/browser_actions_container.cc

Comment 9 by pbos@chromium.org, Apr 27 2018

Status: Verified (was: Assigned)
Verified by TE in #4
Labels: TE-Verified-M67 TE-Verified-67.0.3396.30
Tested this issue on Windows 10,Debian Rodate using chrome-67.0.3396.30  & seems issue working as intended as per C#0.

Hence adding TE verified labels.Please find the attached screencast for reference.

Thanks..!
836182-Win.mp4
847 KB View Download

Sign in to add a comment