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

Unified Diff: chrome/browser/resources/shared/js/cr/ui/context_menu_handler.js

Issue 8422008: TaskManager: minor UI cleanup (consume Esc with context menu opened, use classList). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 2 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 | chrome/browser/resources/task_manager/main.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/resources/shared/js/cr/ui/context_menu_handler.js
diff --git a/chrome/browser/resources/shared/js/cr/ui/context_menu_handler.js b/chrome/browser/resources/shared/js/cr/ui/context_menu_handler.js
index ae998e0a57aa0b96679fe4d24ef28ebd5c1030b1..c413229adbbc7a278967f59c01c71e40c4ba1a4f 100644
--- a/chrome/browser/resources/shared/js/cr/ui/context_menu_handler.js
+++ b/chrome/browser/resources/shared/js/cr/ui/context_menu_handler.js
@@ -132,6 +132,8 @@ cr.define('cr.ui', function() {
// keyIdentifier does not report 'Esc' correctly
if (e.keyCode == 27 /* Esc */) {
this.hideMenu();
+ e.stopPropagation();
+ e.preventDefault();
// If the menu is visible we let it handle all the keyboard events.
} else if (this.menu) {
« no previous file with comments | « no previous file | chrome/browser/resources/task_manager/main.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698