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

Unified Diff: ui/webui/resources/js/cr/ui/focus_outline_manager.js

Issue 732253002: options: Fix focus "Show advanced settings..." click focus regression. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@fix-settings-focus
Patch Set: Created 6 years, 1 month 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/resources/options/browser_options.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/webui/resources/js/cr/ui/focus_outline_manager.js
diff --git a/ui/webui/resources/js/cr/ui/focus_outline_manager.js b/ui/webui/resources/js/cr/ui/focus_outline_manager.js
index f7185d427450b0723ce5eec9234b19045d8d75e0..1adc142ddab8ee17484e47ce56df9553188e10cf 100644
--- a/ui/webui/resources/js/cr/ui/focus_outline_manager.js
+++ b/ui/webui/resources/js/cr/ui/focus_outline_manager.js
@@ -39,10 +39,12 @@ cr.define('cr.ui', function() {
self.focusByKeyboard_ = false;
}, true);
- doc.addEventListener('focus', function(event) {
+ function updateVisiblity() {
// Update visibility only when focus is actually changed.
self.visible = self.focusByKeyboard_;
- }, true);
+ }
+ doc.addEventListener('focus', updateVisiblity, true);
+ doc.addEventListener('blur', updateVisiblity, true);
}
FocusOutlineManager.prototype = {
« no previous file with comments | « chrome/browser/resources/options/browser_options.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698