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

Unified Diff: ui/app_list/cocoa/apps_grid_controller_unittest.mm

Issue 93793012: Squelch context menus on the OSX App List when both buttons are pressed. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | ui/app_list/cocoa/apps_grid_view_item.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/app_list/cocoa/apps_grid_controller_unittest.mm
diff --git a/ui/app_list/cocoa/apps_grid_controller_unittest.mm b/ui/app_list/cocoa/apps_grid_controller_unittest.mm
index 2815882a50d8e3f99e0bec78196d674daa0ab5f5..a01524644e11618c51b954740191ef7d1cb5c431 100644
--- a/ui/app_list/cocoa/apps_grid_controller_unittest.mm
+++ b/ui/app_list/cocoa/apps_grid_controller_unittest.mm
@@ -983,6 +983,13 @@ TEST_F(AppsGridControllerTest, ContextMenus) {
menu = [page menuForEvent:mouse_at_cell_1];
EXPECT_EQ(1, [menu numberOfItems]);
EXPECT_NSEQ(@"Menu For: Item Two", [[menu itemAtIndex:0] title]);
+
+ // Test that a button being held down with the left button does not also show
+ // a context menu.
+ [GetItemViewAt(0) highlight:YES];
+ EXPECT_FALSE([page menuForEvent:mouse_at_cell_0]);
+ [GetItemViewAt(0) highlight:NO];
+ EXPECT_TRUE([page menuForEvent:mouse_at_cell_0]);
}
} // namespace test
« no previous file with comments | « no previous file | ui/app_list/cocoa/apps_grid_view_item.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698