New issue
Advanced search Search tips

Issue 882662 link

Starred by 10 users

Issue metadata

Status: Fixed
Owner:
Closed: Oct 24
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 1
Type: Bug-Regression


Show other hotlists

Hotlists containing this issue:
Chrome-ES


Sign in to add a comment

Browser: Context Menus from Links Near the Right Side of the Screen From Selected Sites Do Not Render Correctly

Project Member Reported by sdantul...@chromium.org, Sep 10

Issue description

Google Chrome	70.0.3538.14 (Official Build) dev (32-bit)
Revision	a7f1f6d7a1cb45c5c85121c09ee54ee00f7caa50-refs/branch-heads/3538@{#195}
Platform	11021.11.0 (Official Build) dev-channel kevin

What steps will reproduce the problem?
1. Open chrome browser
2. Open youtube.com webpage
3. Right click on any video which is near the right edge of the browser window. IMPORTANT: The context menu should be derived from a link.
4. Observe the context menu

What is the expected result?
Context menu items should be visible completely

What happens instead?
Context menu items are cut off and not visible completely
 
Cc: avkodipelli@chromium.org
Components: -UI>Browser UI>Browser>Core
I've also seen the issue by opening the context menu from a link near the right edge of the screen. Please see the screenshot. Very easy to reproduce with Hangouts in Gmail.


Screenshot 2018-09-12 at 09.27.16.png
71.2 KB View Download
Owner: markchang@chromium.org
markchang@, I heard you would be a good contact for issues like this. Could you triage this? thanks!
Labels: M-69
I've seen this on M69 on chromeos:

69.0.3497.87 (Official Build) beta (64-bit)

Full details:

Google Chrome	69.0.3497.87 (Official Build) beta (64-bit)
Revision	7435079008d0cd339e5a43b34a0577dfcc3df922-refs/branch-heads/3497@{#900}
Platform	10895.49.0 (Official Build) beta-channel samus
Labels: -Type-Bug Type-Bug-Regression
Issue not repro'd on M68 (10718.88.2, 68.0.3440.118 stable-channel)
Labels: -Pri-2 Pri-1
Issue reproduced on M69 (10895.56.0, 69.0.3497.95 stable-channel).


Labels: proj-desktopui
We received feedback on this for a difference device, but we were never able to repro it on our Eve's or Link's. We suspect something hardware specific.

Can CrOS assist in the repro? 
Keyword Search:
Issue: When right clicking, the menu appears faded. See screenshot in the...
Issue reproduced on all ChromeOS devices. Tested on eve, cave, coral, kevin and scarlet
Cc: markchang@chromium.org
Owner: robliao@chromium.org
Status: Assigned (was: Untriaged)
Summary: Browser: Context Menus from Links Near the Right Side of the Screen From Selected Sites Do Not Render Correctly (was: Browser: Context menu items are not visible completely)
Performing an initial routing triage. We don't directly handle CrOS Context Menus.
Description: Show this description
Cc: robliao@chromium.org
Owner: newcomer@chromium.org
Reassigning to newcomer@, who has recent changes in the context menu code.

newcomer@: Can you take a look? Thanks!
I'll do a bisect this week. If it's a simple fix, I'll merge it.
Issue 846524 has been merged into this issue.
Issue 887210 has been merged into this issue.
Owner: tnijssen@chromium.org
Passing this one off to tnijssen, who recently refactored MenuController::CalculateMenuBounds().

I'm also seeing menus sometimes rendering 1/10th on screen with the rest of the menu off screen.
Labels: Needs-Bisect
Owner: newcomer@chromium.org
tnijssen is an intern, and not here any more :(

Also, this repros ChromeOS only, and tnijssen's changes were for all platforms. I'm moving it back to you for now - mostly because of CrOS only. Requested a bisect as well, let's see what comes out of that.
So does the needs-bisect label go to another group that does this, or is that wishful thinking on my part?
It depends if test can pick it up in time. In this particular case, it's probably urgent enough to go ahead and do the local manual bisect.
Status: Started (was: Assigned)
Labels: Hotlist-DesktopUITriaged
Seems like a CrOS side issue because I bisected between CrOS R70-10906.0.0 and R70-10907.0.0, both of which have the same Chrome version (70.0.3501.0). Strange! I'll keep investigating.


Cc: osh...@chromium.org
This most likely depends on a feature controlled by finch. It doesn't happen when you test in guest mode for example.
newcomer@ - one thing to check during bisects: are you making sure to run with a fresh install each time?  Otherwise you can have errant state laying around.

Also, can you post the link to the diff between those versions?  I don't know how to get blamelists between two ChromeOS versions, only Chrome versions.
Please see my comment above. The same binary, different behavior depending on how you started/login, so it must be controlled by some flag.

newcomer@ can you check the finch experiment list at https://uma.googleplex.com/variations/hashes/ and see if there is anything suspicious? 
Cc: pkasting@chromium.org tapted@chromium.org
This one is not easy to repro, which is how I mistakenly thought it did not repro on R70-10906.0.0.

Root cause of text eliding on the right side of the screen is TBD, I will create a new bug for that and investigate.

For now, I found the CL[1] which exposed this bug (the context menus for links will show up on the right side of the anchor regardless if there is space for the full menu).

I will submit a bug fix and merge this to M-70.

[1]
https://chromium-review.googlesource.com/c/chromium/src/+/1114073
Labels: Merge-Request-70
CL under review:
https://chromium-review.googlesource.com/c/chromium/src/+/1262397

This is a very safe change to merge (said everyone ever). WDYT?
Project Member

Comment 32 by sheriffbot@chromium.org, Oct 5

Labels: -Merge-Request-70 Merge-Review-70 Hotlist-Merge-Review
This bug requires manual review: We are only 10 days from stable.
Please contact the milestone owner if you have questions.
Owners: benmason@(Android), kariahda@(iOS), geohsu@(ChromeOS), abdulsyed@(Desktop)

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Labels: -Merge-Review-70 Merge-Approved-70
Labels: Group-Menus
Project Member

Comment 35 by sheriffbot@chromium.org, Oct 9

Cc: geo...@google.com
This issue has been approved for a merge. Please merge the fix to any appropriate branches as soon as possible!

If all merges have been completed, please remove any remaining Merge-Approved labels from this issue.

Thanks for your time! To disable nags, add the Disable-Nags label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Labels: -Needs-Bisect -M-69 -Merge-Approved-70 -M-70 M-71
Moving the fix target to M-71, I'm gardening all week and won't be able to fix this.
Labels: -M-71 ReleaseBlock-Stable M-70 Merge-Approved-70
After talking to a few people, this is actually bad enough to block stable for M-70. Reassigning the old labels.

I'm gardening, but I will do my best to have a solution for this very soon.
Project Member

Comment 38 by sheriffbot@chromium.org, Oct 15

This issue has been approved for a merge. Please merge the fix to any appropriate branches as soon as possible!

If all merges have been completed, please remove any remaining Merge-Approved labels from this issue.

Thanks for your time! To disable nags, add the Disable-Nags label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Project Member

Comment 39 by bugdroid1@chromium.org, Oct 17

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

commit be913dcb4d9dc61efbc9ff9c8bb9ef14b75ed61b
Author: Alex Newcomer <newcomer@chromium.org>
Date: Wed Oct 17 21:32:44 2018

cros: Fix menus getting squished

Menu bounds do not fit new wider options if the menu options are added
after the menu is initially drawn, and the width of the new options
exceeds {screen_width - original_menu_origin.x}. This makes wide menu
options unusable in some cases because the menu does not widen to
accommodate the new items.

Regression started: r573978

Test case:
1. Show a website with link[1] on the far right side of the screen:
https://www.google.com/chromebook/
2. Right click to show a menu on one of the links in the toolbar.

The menu should be wide enough to show all contents of the menu.

[1]Step 1 must have a link as the source of the menu because
links use arc::OpenWithMenu, which can add wider ("Open with ...")
options to a context menu. These options are added after the menu
is drawn because we show the menu before arc calls back with the new
menu options.

Test: MenuControllerTest.GrowingMenuMovesLaterallyNotVertically
Bug:  882662 
Change-Id: Ic848fdb545bbdd05f874041bf1044adb7bd1d094
Reviewed-on: https://chromium-review.googlesource.com/c/1262397
Commit-Queue: Alex Newcomer <newcomer@chromium.org>
Reviewed-by: Trent Apted <tapted@chromium.org>
Cr-Commit-Position: refs/heads/master@{#600563}
[modify] https://crrev.com/be913dcb4d9dc61efbc9ff9c8bb9ef14b75ed61b/ui/views/controls/menu/menu_controller.cc
[modify] https://crrev.com/be913dcb4d9dc61efbc9ff9c8bb9ef14b75ed61b/ui/views/controls/menu/menu_controller_unittest.cc

Labels: -Merge-Approved-70 Merge-Merged-70-3538
The following revision refers to this bug: 
https://chromium.googlesource.com/chromium/src.git/+/e908ed05c0f94553e48ce52d905fb4bbc9ee952d

Commit: e908ed05c0f94553e48ce52d905fb4bbc9ee952d
Author: newcomer@chromium.org
Commiter: newcomer@chromium.org
Date: 2018-10-17 21:36:59 +0000 UTC

cros: Fix menus getting squished

Menu bounds do not fit new wider options if the menu options are added
after the menu is initially drawn, and the width of the new options
exceeds {screen_width - original_menu_origin.x}. This makes wide menu
options unusable in some cases because the menu does not widen to
accommodate the new items.

Regression started: r573978

Test case:
1. Show a website with link[1] on the far right side of the screen:
https://www.google.com/chromebook/
2. Right click to show a menu on one of the links in the toolbar.

The menu should be wide enough to show all contents of the menu.

[1]Step 1 must have a link as the source of the menu because
links use arc::OpenWithMenu, which can add wider ("Open with ...")
options to a context menu. These options are added after the menu
is drawn because we show the menu before arc calls back with the new
menu options.

Test: MenuControllerTest.GrowingMenuMovesLaterallyNotVertically
Bug:  882662 
Change-Id: Ic848fdb545bbdd05f874041bf1044adb7bd1d094
Reviewed-on: https://chromium-review.googlesource.com/c/1262397
Commit-Queue: Alex Newcomer <newcomer@chromium.org>
Reviewed-by: Trent Apted <tapted@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#600563}(cherry picked from commit 86fdcac088f169ebd04c09ae0ebfd93c6a0953ab)
Reviewed-on: https://chromium-review.googlesource.com/c/1287182
Reviewed-by: Alex Newcomer <newcomer@chromium.org>
Cr-Commit-Position: refs/branch-heads/3538@{#1012}
Cr-Branched-From: 79f7c91a2b2a2932cd447fa6f865cb6662fa8fa6-refs/heads/master@{#587811}
Project Member

Comment 41 by bugdroid1@chromium.org, Oct 17

Labels: merge-merged-3538
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/e908ed05c0f94553e48ce52d905fb4bbc9ee952d

commit e908ed05c0f94553e48ce52d905fb4bbc9ee952d
Author: Alex Newcomer <newcomer@chromium.org>
Date: Wed Oct 17 21:36:59 2018

cros: Fix menus getting squished

Menu bounds do not fit new wider options if the menu options are added
after the menu is initially drawn, and the width of the new options
exceeds {screen_width - original_menu_origin.x}. This makes wide menu
options unusable in some cases because the menu does not widen to
accommodate the new items.

Regression started: r573978

Test case:
1. Show a website with link[1] on the far right side of the screen:
https://www.google.com/chromebook/
2. Right click to show a menu on one of the links in the toolbar.

The menu should be wide enough to show all contents of the menu.

[1]Step 1 must have a link as the source of the menu because
links use arc::OpenWithMenu, which can add wider ("Open with ...")
options to a context menu. These options are added after the menu
is drawn because we show the menu before arc calls back with the new
menu options.

Test: MenuControllerTest.GrowingMenuMovesLaterallyNotVertically
Bug:  882662 
Change-Id: Ic848fdb545bbdd05f874041bf1044adb7bd1d094
Reviewed-on: https://chromium-review.googlesource.com/c/1262397
Commit-Queue: Alex Newcomer <newcomer@chromium.org>
Reviewed-by: Trent Apted <tapted@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#600563}(cherry picked from commit 86fdcac088f169ebd04c09ae0ebfd93c6a0953ab)
Reviewed-on: https://chromium-review.googlesource.com/c/1287182
Reviewed-by: Alex Newcomer <newcomer@chromium.org>
Cr-Commit-Position: refs/branch-heads/3538@{#1012}
Cr-Branched-From: 79f7c91a2b2a2932cd447fa6f865cb6662fa8fa6-refs/heads/master@{#587811}
[modify] https://crrev.com/e908ed05c0f94553e48ce52d905fb4bbc9ee952d/ui/views/controls/menu/menu_controller.cc
[modify] https://crrev.com/e908ed05c0f94553e48ce52d905fb4bbc9ee952d/ui/views/controls/menu/menu_controller_unittest.cc

Looks like this has been merged into M70, can we close? Thanks
Issue 896953 has been merged into this issue.
I think newcomer@ is OOO, can someone help verify this is fixed? Thanks.
geohsu@ There are no new chrome yet on M72 or M70. Will verify once new build is available. 

Also, the fix needs to be merged to M71. Thanks.

Labels: Merge-Request-71
Labels: M-71
Project Member

Comment 48 by sheriffbot@chromium.org, Oct 20

Labels: -Merge-Request-71 Hotlist-Merge-Approved Merge-Approved-71
Your change meets the bar and is auto-approved for M71. Please go ahead and merge the CL to branch 3578 manually. Please contact milestone owner if you have questions.
Owners: benmason@(Android), kariahda@(iOS), kbleicher@(ChromeOS), govind@(Desktop)

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Project Member

Comment 49 by bugdroid1@chromium.org, Oct 21

Labels: -merge-approved-71 merge-merged-3578
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/4244c640e5367c2c4d002a39350cc5f8740cf07a

commit 4244c640e5367c2c4d002a39350cc5f8740cf07a
Author: Trent Apted <tapted@chromium.org>
Date: Sun Oct 21 23:48:43 2018

[merge-m71] cros: Fix menus getting squished

Menu bounds do not fit new wider options if the menu options are added
after the menu is initially drawn, and the width of the new options
exceeds {screen_width - original_menu_origin.x}. This makes wide menu
options unusable in some cases because the menu does not widen to
accommodate the new items.

Regression started: r573978

Test case:
1. Show a website with link[1] on the far right side of the screen:
https://www.google.com/chromebook/
2. Right click to show a menu on one of the links in the toolbar.

The menu should be wide enough to show all contents of the menu.

[1]Step 1 must have a link as the source of the menu because
links use arc::OpenWithMenu, which can add wider ("Open with ...")
options to a context menu. These options are added after the menu
is drawn because we show the menu before arc calls back with the new
menu options.

TBR=newcomer@chromium.org

(cherry picked from commit be913dcb4d9dc61efbc9ff9c8bb9ef14b75ed61b)

Test: MenuControllerTest.GrowingMenuMovesLaterallyNotVertically
Bug:  882662 
Change-Id: Ic848fdb545bbdd05f874041bf1044adb7bd1d094
Reviewed-on: https://chromium-review.googlesource.com/c/1262397
Commit-Queue: Alex Newcomer <newcomer@chromium.org>
Reviewed-by: Trent Apted <tapted@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#600563}
Reviewed-on: https://chromium-review.googlesource.com/c/1292658
Cr-Commit-Position: refs/branch-heads/3578@{#192}
Cr-Branched-From: 4226ddf99103e493d7afb23a4c7902ee496108b6-refs/heads/master@{#599034}
[modify] https://crrev.com/4244c640e5367c2c4d002a39350cc5f8740cf07a/ui/views/controls/menu/menu_controller.cc
[modify] https://crrev.com/4244c640e5367c2c4d002a39350cc5f8740cf07a/ui/views/controls/menu/menu_controller_unittest.cc

I believe the M70 builds have picked up this change. Please verify when able. Thanks.
Labels: Merge-Merged-71-3578
The following revision refers to this bug: 
https://chromium.googlesource.com/chromium/src.git/+/4244c640e5367c2c4d002a39350cc5f8740cf07a

Commit: 4244c640e5367c2c4d002a39350cc5f8740cf07a
Author: tapted@chromium.org
Commiter: tapted@chromium.org
Date: 2018-10-21 23:48:43 +0000 UTC

[merge-m71] cros: Fix menus getting squished

Menu bounds do not fit new wider options if the menu options are added
after the menu is initially drawn, and the width of the new options
exceeds {screen_width - original_menu_origin.x}. This makes wide menu
options unusable in some cases because the menu does not widen to
accommodate the new items.

Regression started: r573978

Test case:
1. Show a website with link[1] on the far right side of the screen:
https://www.google.com/chromebook/
2. Right click to show a menu on one of the links in the toolbar.

The menu should be wide enough to show all contents of the menu.

[1]Step 1 must have a link as the source of the menu because
links use arc::OpenWithMenu, which can add wider ("Open with ...")
options to a context menu. These options are added after the menu
is drawn because we show the menu before arc calls back with the new
menu options.

TBR=newcomer@chromium.org

(cherry picked from commit be913dcb4d9dc61efbc9ff9c8bb9ef14b75ed61b)

Test: MenuControllerTest.GrowingMenuMovesLaterallyNotVertically
Bug:  882662 
Change-Id: Ic848fdb545bbdd05f874041bf1044adb7bd1d094
Reviewed-on: https://chromium-review.googlesource.com/c/1262397
Commit-Queue: Alex Newcomer <newcomer@chromium.org>
Reviewed-by: Trent Apted <tapted@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#600563}
Reviewed-on: https://chromium-review.googlesource.com/c/1292658
Cr-Commit-Position: refs/branch-heads/3578@{#192}
Cr-Branched-From: 4226ddf99103e493d7afb23a4c7902ee496108b6-refs/heads/master@{#599034}
Status: Fixed (was: Started)
Thanks for merging this to 71! I was OOO. 

Sign in to add a comment