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

Side by Side Diff: Source/devtools/front_end/components/InspectorView.js

Issue 614323003: DevTools: enable by default disableAgentsWhenProfile experiment (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: unnecessary line was removed Created 6 years, 2 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 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 * * Redistributions of source code must retain the above copyright 8 * * 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 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 InspectorFrontendHost.events.addEventListener(InspectorFrontendHostAPI.Event s.ShowConsole, showConsole.bind(this)); 87 InspectorFrontendHost.events.addEventListener(InspectorFrontendHostAPI.Event s.ShowConsole, showConsole.bind(this));
88 this._loadPanelDesciptors(); 88 this._loadPanelDesciptors();
89 89
90 /** 90 /**
91 * @this {WebInspector.InspectorView} 91 * @this {WebInspector.InspectorView}
92 */ 92 */
93 function showConsole() 93 function showConsole()
94 { 94 {
95 this.showPanel("console").done(); 95 this.showPanel("console").done();
96 } 96 }
97
98 WebInspector.targetManager.addEventListener(WebInspector.TargetManager.Event s.SuspendStateChanged, this._onSuspendStateChanged.bind(this));
97 }; 99 };
98 100
99 WebInspector.InspectorView.prototype = { 101 WebInspector.InspectorView.prototype = {
100 _loadPanelDesciptors: function() 102 _loadPanelDesciptors: function()
101 { 103 {
102 WebInspector.startBatchUpdate(); 104 WebInspector.startBatchUpdate();
103 self.runtime.extensions(WebInspector.PanelFactory).forEach(processPanelE xtensions.bind(this)); 105 self.runtime.extensions(WebInspector.PanelFactory).forEach(processPanelE xtensions.bind(this));
104 /** 106 /**
105 * @param {!Runtime.Extension} extension 107 * @param {!Runtime.Extension} extension
106 * @this {!WebInspector.InspectorView} 108 * @this {!WebInspector.InspectorView}
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 function cachePanel(panel) 180 function cachePanel(panel)
179 { 181 {
180 delete this._panelPromises[panelName]; 182 delete this._panelPromises[panelName];
181 this._panels[panelName] = panel; 183 this._panels[panelName] = panel;
182 return panel; 184 return panel;
183 } 185 }
184 return promise; 186 return promise;
185 }, 187 },
186 188
187 /** 189 /**
188 * @param {boolean} locked 190 * @param {!WebInspector.Event} event
189 */ 191 */
190 setCurrentPanelLocked: function(locked) 192 _onSuspendStateChanged: function(event)
191 { 193 {
192 this._currentPanelLocked = locked; 194 this._currentPanelLocked = WebInspector.targetManager.allTargetsSuspende d();
193 this._tabbedPane.setCurrentTabLocked(locked); 195 this._tabbedPane.setCurrentTabLocked(this._currentPanelLocked);
194 for (var i = 0; i < this._toolbarItems.length; ++i) 196 for (var i = 0; i < this._toolbarItems.length; ++i)
195 this._toolbarItems[i].setEnabled(!locked); 197 this._toolbarItems[i].setEnabled(!this._currentPanelLocked);
196 }, 198 },
197 199
198 /** 200 /**
199 * The returned Promise is resolved with null if another showPanel() 201 * The returned Promise is resolved with null if another showPanel()
200 * gets called while this.panel(panelName) Promise is in flight. 202 * gets called while this.panel(panelName) Promise is in flight.
201 * 203 *
202 * @param {string} panelName 204 * @param {string} panelName
203 * @return {!Promise.<?WebInspector.Panel>} 205 * @return {!Promise.<?WebInspector.Panel>}
204 */ 206 */
205 showPanel: function(panelName) 207 showPanel: function(panelName)
(...skipping 325 matching lines...) Expand 10 before | Expand all | Expand 10 after
531 533
532 WebInspector.InspectorView.ToggleDrawerButtonProvider.prototype = { 534 WebInspector.InspectorView.ToggleDrawerButtonProvider.prototype = {
533 /** 535 /**
534 * @return {?WebInspector.StatusBarItem} 536 * @return {?WebInspector.StatusBarItem}
535 */ 537 */
536 item: function() 538 item: function()
537 { 539 {
538 return WebInspector.inspectorView._drawer.toggleButton(); 540 return WebInspector.inspectorView._drawer.toggleButton();
539 } 541 }
540 } 542 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698