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

Side by Side Diff: Source/devtools/front_end/SourcesPanelDescriptor.js

Issue 23484056: [DevTools] Renaming Scripts panel to Sources panel (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Modified missed files Created 7 years, 3 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 10 *
(...skipping 13 matching lines...) Expand all
24 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 24 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 25 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
26 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 26 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 */ 27 */
28 28
29 /** 29 /**
30 * @constructor 30 * @constructor
31 * @extends {WebInspector.PanelDescriptor} 31 * @extends {WebInspector.PanelDescriptor}
32 * @implements {WebInspector.ContextMenu.Provider} 32 * @implements {WebInspector.ContextMenu.Provider}
33 */ 33 */
34 WebInspector.ScriptsPanelDescriptor = function() 34 WebInspector.SourcesPanelDescriptor = function()
35 { 35 {
36 WebInspector.PanelDescriptor.call(this, "scripts", WebInspector.UIString("So urces"), "ScriptsPanel", "ScriptsPanel.js"); 36 WebInspector.PanelDescriptor.call(this, "sources", WebInspector.UIString("So urces"), "SourcesPanel", "SourcesPanel.js");
37 WebInspector.ContextMenu.registerProvider(this); 37 WebInspector.ContextMenu.registerProvider(this);
38 } 38 }
39 39
40 WebInspector.ScriptsPanelDescriptor.prototype = { 40 WebInspector.SourcesPanelDescriptor.prototype = {
41 /** 41 /**
42 * @param {WebInspector.ContextMenu} contextMenu 42 * @param {WebInspector.ContextMenu} contextMenu
43 * @param {Object} target 43 * @param {Object} target
44 */ 44 */
45 appendApplicableItems: function(event, contextMenu, target) 45 appendApplicableItems: function(event, contextMenu, target)
46 { 46 {
47 var hasApplicableItems = target instanceof WebInspector.UISourceCode; 47 var hasApplicableItems = target instanceof WebInspector.UISourceCode;
48 48
49 if (!hasApplicableItems && target instanceof WebInspector.RemoteObject) { 49 if (!hasApplicableItems && target instanceof WebInspector.RemoteObject) {
50 var remoteObject = /** @type {WebInspector.RemoteObject} */ (target) ; 50 var remoteObject = /** @type {WebInspector.RemoteObject} */ (target) ;
51 if (remoteObject.type !== "function") 51 if (remoteObject.type !== "function")
52 return; 52 return;
53 } 53 }
54 54
55 this.panel().appendApplicableItems(event, contextMenu, target); 55 this.panel().appendApplicableItems(event, contextMenu, target);
56 }, 56 },
57 57
58 registerShortcuts: function() 58 registerShortcuts: function()
59 { 59 {
60 var section = WebInspector.shortcutsScreen.section(WebInspector.UIString ("Sources Panel")); 60 var section = WebInspector.shortcutsScreen.section(WebInspector.UIString ("Sources Panel"));
61 61
62 section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKey s.PauseContinue, WebInspector.UIString("Pause/Continue")); 62 section.addAlternateKeys(WebInspector.SourcesPanelDescriptor.ShortcutKey s.PauseContinue, WebInspector.UIString("Pause/Continue"));
63 section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKey s.StepOver, WebInspector.UIString("Step over")); 63 section.addAlternateKeys(WebInspector.SourcesPanelDescriptor.ShortcutKey s.StepOver, WebInspector.UIString("Step over"));
64 section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKey s.StepInto, WebInspector.UIString("Step into")); 64 section.addAlternateKeys(WebInspector.SourcesPanelDescriptor.ShortcutKey s.StepInto, WebInspector.UIString("Step into"));
65 section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKey s.StepIntoSelection, WebInspector.UIString("Step into selection")); 65 section.addAlternateKeys(WebInspector.SourcesPanelDescriptor.ShortcutKey s.StepIntoSelection, WebInspector.UIString("Step into selection"));
66 section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKey s.StepOut, WebInspector.UIString("Step out")); 66 section.addAlternateKeys(WebInspector.SourcesPanelDescriptor.ShortcutKey s.StepOut, WebInspector.UIString("Step out"));
67 67
68 var nextAndPrevFrameKeys = WebInspector.ScriptsPanelDescriptor.ShortcutK eys.NextCallFrame.concat(WebInspector.ScriptsPanelDescriptor.ShortcutKeys.PrevCa llFrame); 68 var nextAndPrevFrameKeys = WebInspector.SourcesPanelDescriptor.ShortcutK eys.NextCallFrame.concat(WebInspector.SourcesPanelDescriptor.ShortcutKeys.PrevCa llFrame);
69 section.addRelatedKeys(nextAndPrevFrameKeys, WebInspector.UIString("Next /previous call frame")); 69 section.addRelatedKeys(nextAndPrevFrameKeys, WebInspector.UIString("Next /previous call frame"));
70 70
71 section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKey s.EvaluateSelectionInConsole, WebInspector.UIString("Evaluate selection in conso le")); 71 section.addAlternateKeys(WebInspector.SourcesPanelDescriptor.ShortcutKey s.EvaluateSelectionInConsole, WebInspector.UIString("Evaluate selection in conso le"));
72 section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKey s.GoToMember, WebInspector.UIString("Go to member")); 72 section.addAlternateKeys(WebInspector.SourcesPanelDescriptor.ShortcutKey s.GoToMember, WebInspector.UIString("Go to member"));
73 section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKey s.ToggleBreakpoint, WebInspector.UIString("Toggle breakpoint")); 73 section.addAlternateKeys(WebInspector.SourcesPanelDescriptor.ShortcutKey s.ToggleBreakpoint, WebInspector.UIString("Toggle breakpoint"));
74 section.addAlternateKeys(WebInspector.ScriptsPanelDescriptor.ShortcutKey s.ToggleComment, WebInspector.UIString("Toggle comment")); 74 section.addAlternateKeys(WebInspector.SourcesPanelDescriptor.ShortcutKey s.ToggleComment, WebInspector.UIString("Toggle comment"));
75 }, 75 },
76 76
77 __proto__: WebInspector.PanelDescriptor.prototype 77 __proto__: WebInspector.PanelDescriptor.prototype
78 } 78 }
79 79
80 WebInspector.ScriptsPanelDescriptor.ShortcutKeys = { 80 WebInspector.SourcesPanelDescriptor.ShortcutKeys = {
81 RunSnippet: [ 81 RunSnippet: [
82 WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortc ut.Keys.Enter, WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta) 82 WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortc ut.Keys.Enter, WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)
83 ], 83 ],
84 84
85 PauseContinue: [ 85 PauseContinue: [
86 WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortc ut.Keys.F8), 86 WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortc ut.Keys.F8),
87 WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortc ut.Keys.Backslash, WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta) 87 WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortc ut.Keys.Backslash, WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)
88 ], 88 ],
89 89
90 StepOver: [ 90 StepOver: [
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 125
126 PrevCallFrame: [ 126 PrevCallFrame: [
127 WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortc ut.Keys.Comma, WebInspector.KeyboardShortcut.Modifiers.Ctrl) 127 WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortc ut.Keys.Comma, WebInspector.KeyboardShortcut.Modifiers.Ctrl)
128 ], 128 ],
129 129
130 ToggleComment: [ 130 ToggleComment: [
131 WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortc ut.Keys.Slash, WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta) 131 WebInspector.KeyboardShortcut.makeDescriptor(WebInspector.KeyboardShortc ut.Keys.Slash, WebInspector.KeyboardShortcut.Modifiers.CtrlOrMeta)
132 132
133 ] 133 ]
134 }; 134 };
OLDNEW
« no previous file with comments | « Source/devtools/front_end/SourcesPanel.js ('k') | Source/devtools/front_end/SourcesSearchScope.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698