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

Unified Diff: chrome/browser/ui/cocoa/menu_button_unittest.mm

Issue 1256183004: Fixed crashed when activating the context menu for toolbar buttons using Voiceover (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed indentation. Created 5 years, 4 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 | « chrome/browser/ui/cocoa/menu_button.mm ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/menu_button_unittest.mm
diff --git a/chrome/browser/ui/cocoa/menu_button_unittest.mm b/chrome/browser/ui/cocoa/menu_button_unittest.mm
index 5ce4caf72a97b9e6dd9575a56444b2d8bf7007a9..15d76d66672d5ba9d6efe7153393b52b04ada97f 100644
--- a/chrome/browser/ui/cocoa/menu_button_unittest.mm
+++ b/chrome/browser/ui/cocoa/menu_button_unittest.mm
@@ -247,6 +247,13 @@ TEST_F(MenuButtonTest, OpenOnAccessibilityPerformActionWithSetRightClick) {
actionNames = [buttonCell accessibilityActionNames];
EXPECT_TRUE([actionNames containsObject:NSAccessibilityShowMenuAction]);
+ [button_ setOpenMenuOnClick:NO];
+
+ // Command should still be available, even when both click + hold and right
+ // click are turned on.
+ actionNames = [buttonCell accessibilityActionNames];
+ EXPECT_TRUE([actionNames containsObject:NSAccessibilityShowMenuAction]);
+
[buttonCell accessibilityPerformAction:NSAccessibilityShowMenuAction];
EXPECT_TRUE([delegate didOpen]);
EXPECT_FALSE([delegate isOpen]);
« no previous file with comments | « chrome/browser/ui/cocoa/menu_button.mm ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698