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

Issue 1495973002: [Views] If a sibling menu is selected, reset the MenuButton's PressedLock (Closed)

Created:
5 years ago by Devlin
Modified:
5 years ago
Reviewers:
sky
CC:
chromium-reviews, tfarina, noyau+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Views] If a sibling menu is selected, reset the MenuButton's PressedLock MenuButton::Activate() creates a PressedLock, which is important if it doesn't call into MenuController code. However, if it is running a menu through the MenuController and a sibling menu is shown, we need to reset that PressedLock so that buttons don't remain pressed. Fix the bug and add a couple tests. BUG=560852 Committed: https://crrev.com/d2db790c2898559a24402c131d22444c6d0ca4a4 Cr-Commit-Position: refs/heads/master@{#363547}

Patch Set 1 : #

Total comments: 4

Patch Set 2 : Remove PressedLock #

Patch Set 3 : #

Patch Set 4 : Test fix #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+50 lines, -10 lines) Patch
M chrome/browser/ui/views/bookmarks/bookmark_bar_view_test.cc View 2 chunks +8 lines, -2 lines 0 comments Download
M ui/views/controls/button/menu_button.cc View 1 2 3 2 chunks +6 lines, -4 lines 1 comment Download
M ui/views/controls/button/menu_button_unittest.cc View 1 2 3 7 chunks +36 lines, -4 lines 1 comment Download

Messages

Total messages: 22 (10 generated)
Devlin
Scott, mind taking a look?
5 years ago (2015-12-03 22:56:38 UTC) #6
sky
https://codereview.chromium.org/1495973002/diff/60001/ui/views/controls/button/menu_button.cc File ui/views/controls/button/menu_button.cc (right): https://codereview.chromium.org/1495973002/diff/60001/ui/views/controls/button/menu_button.cc#newcode134 ui/views/controls/button/menu_button.cc:134: listener_->OnMenuButtonClicked(this, menu_position); Under what case does this not show ...
5 years ago (2015-12-04 00:44:40 UTC) #7
sky
On 2015/12/04 00:44:40, sky wrote: > https://codereview.chromium.org/1495973002/diff/60001/ui/views/controls/button/menu_button.cc > File ui/views/controls/button/menu_button.cc (right): > > https://codereview.chromium.org/1495973002/diff/60001/ui/views/controls/button/menu_button.cc#newcode134 > ...
5 years ago (2015-12-04 00:45:18 UTC) #8
Devlin
https://codereview.chromium.org/1495973002/diff/60001/ui/views/controls/button/menu_button.cc File ui/views/controls/button/menu_button.cc (right): https://codereview.chromium.org/1495973002/diff/60001/ui/views/controls/button/menu_button.cc#newcode134 ui/views/controls/button/menu_button.cc:134: listener_->OnMenuButtonClicked(this, menu_position); On 2015/12/04 00:44:40, sky wrote: > Under ...
5 years ago (2015-12-04 16:43:59 UTC) #9
sky
https://codereview.chromium.org/1495973002/diff/60001/ui/views/controls/button/menu_button.cc File ui/views/controls/button/menu_button.cc (right): https://codereview.chromium.org/1495973002/diff/60001/ui/views/controls/button/menu_button.cc#newcode134 ui/views/controls/button/menu_button.cc:134: listener_->OnMenuButtonClicked(this, menu_position); On 2015/12/04 16:43:59, Devlin wrote: > On ...
5 years ago (2015-12-04 16:56:53 UTC) #10
Devlin
https://codereview.chromium.org/1495973002/diff/60001/ui/views/controls/button/menu_button.cc File ui/views/controls/button/menu_button.cc (right): https://codereview.chromium.org/1495973002/diff/60001/ui/views/controls/button/menu_button.cc#newcode134 ui/views/controls/button/menu_button.cc:134: listener_->OnMenuButtonClicked(this, menu_position); On 2015/12/04 16:56:53, sky wrote: > On ...
5 years ago (2015-12-04 18:04:36 UTC) #11
sky
Yes, LGTM I think the avatar menu should really persist the lock until the bubble ...
5 years ago (2015-12-04 20:22:01 UTC) #12
Devlin
I very sillily forgot to re-run (all the) menu button tests with the last CL. ...
5 years ago (2015-12-05 00:28:27 UTC) #14
sky
SLGTM
5 years ago (2015-12-07 16:05:42 UTC) #15
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1495973002/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1495973002/120001
5 years ago (2015-12-07 18:44:26 UTC) #18
commit-bot: I haz the power
Committed patchset #4 (id:120001)
5 years ago (2015-12-07 19:40:28 UTC) #20
commit-bot: I haz the power
5 years ago (2015-12-07 19:41:24 UTC) #22
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/d2db790c2898559a24402c131d22444c6d0ca4a4
Cr-Commit-Position: refs/heads/master@{#363547}

Powered by Google App Engine
This is Rietveld 408576698