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

Unified Diff: Source/devtools/front_end/ui/UIUtils.js

Issue 1172733002: Devtools: Fix ctrl-z in ColorPicker (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rework Created 5 years, 6 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 | « Source/devtools/front_end/elements/spectrum.css ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/devtools/front_end/ui/UIUtils.js
diff --git a/Source/devtools/front_end/ui/UIUtils.js b/Source/devtools/front_end/ui/UIUtils.js
index 22baf783e68e340fb0954e44a65888d02de54f23..eb570da1b1e337ea2f01e8694ed84efd8e175c19 100644
--- a/Source/devtools/front_end/ui/UIUtils.js
+++ b/Source/devtools/front_end/ui/UIUtils.js
@@ -651,6 +651,7 @@ WebInspector.createShadowRootWithCoreStyles = function(element)
var shadowRoot = element.createShadowRoot();
shadowRoot.appendChild(WebInspector.Widget.createStyleElement("ui/inspectorCommon.css"));
shadowRoot.appendChild(WebInspector.Widget.createStyleElement("ui/inspectorSyntaxHighlight.css"));
+ shadowRoot.addEventListener("focus", WebInspector._focusChanged.bind(WebInspector), true);
return shadowRoot;
}
@@ -691,10 +692,9 @@ WebInspector.currentFocusElement = function()
}
/**
- * @param {!Document} document
* @param {!Event} event
*/
-WebInspector._focusChanged = function(document, event)
+WebInspector._focusChanged = function(event)
{
var node = event.deepActiveElement();
WebInspector.setCurrentFocusElement(node);
@@ -1201,7 +1201,7 @@ WebInspector.initializeUIUtils = function(window)
{
window.addEventListener("focus", WebInspector._windowFocused.bind(WebInspector, window.document), false);
window.addEventListener("blur", WebInspector._windowBlurred.bind(WebInspector, window.document), false);
- window.document.addEventListener("focus", WebInspector._focusChanged.bind(WebInspector, window.document), true);
+ window.document.addEventListener("focus", WebInspector._focusChanged.bind(WebInspector), true);
window.document.addEventListener("blur", WebInspector._documentBlurred.bind(WebInspector, window.document), true);
}
« no previous file with comments | « Source/devtools/front_end/elements/spectrum.css ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698