summaryrefslogtreecommitdiffstats
path: root/ui/webui
diff options
context:
space:
mode:
Diffstat (limited to 'ui/webui')
-rw-r--r--ui/webui/resources/js/cr/ui/context_menu_handler.js5
1 files changed, 5 insertions, 0 deletions
diff --git a/ui/webui/resources/js/cr/ui/context_menu_handler.js b/ui/webui/resources/js/cr/ui/context_menu_handler.js
index 0b1cc21..7dc16aa 100644
--- a/ui/webui/resources/js/cr/ui/context_menu_handler.js
+++ b/ui/webui/resources/js/cr/ui/context_menu_handler.js
@@ -53,6 +53,7 @@ cr.define('cr.ui', function() {
this.showingEvents_.add(doc, 'focus', this);
this.showingEvents_.add(win, 'popstate', this);
this.showingEvents_.add(win, 'resize', this);
+ this.showingEvents_.add(win, 'blur', this);
this.showingEvents_.add(menu, 'contextmenu', this);
this.showingEvents_.add(menu, 'activate', this);
this.positionMenu_(e, menu);
@@ -181,6 +182,10 @@ cr.define('cr.ui', function() {
this.hideMenu();
break;
+ case 'blur':
+ this.hideMenu();
+ break;
+
case 'popstate':
case 'resize':
this.hideMenu();