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

Unified Diff: Source/devtools/front_end/SourceFrame.js

Issue 218613013: DevTools: Decouple shortcuts from actions, introduce shortcut contexts (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Address comments - take 1 Created 6 years, 8 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
Index: Source/devtools/front_end/SourceFrame.js
diff --git a/Source/devtools/front_end/SourceFrame.js b/Source/devtools/front_end/SourceFrame.js
index 937d52e22e8df9fac3a19e6336c78716f4789b16..c4ba20c82f765d825cbe1dc78ebfd3f435be621e 100644
--- a/Source/devtools/front_end/SourceFrame.js
+++ b/Source/devtools/front_end/SourceFrame.js
@@ -425,6 +425,12 @@ WebInspector.SourceFrame.prototype = {
_editorFocused: function()
{
this._resetCurrentSearchResultIndex();
+ WebInspector.context.setFlavor(WebInspector.SourceFrame, this);
pfeldman 2014/04/17 10:40:25 I think this should be done on the level of Source
apavlov 2014/04/17 12:42:22 If Ctrl+H were our "Search&Replace in source code"
+ },
+
+ _editorBlurred: function()
+ {
+ WebInspector.context.setFlavor(WebInspector.SourceFrame, null);
},
_resetCurrentSearchResultIndex: function()
@@ -839,6 +845,11 @@ WebInspector.TextEditorDelegateForSourceFrame.prototype = {
this._sourceFrame._editorFocused();
},
+ editorBlurred: function()
+ {
+ this._sourceFrame._editorBlurred();
+ },
+
populateLineGutterContextMenu: function(contextMenu, lineNumber)
{
this._sourceFrame.populateLineGutterContextMenu(contextMenu, lineNumber);

Powered by Google App Engine
This is Rietveld 408576698