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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/sources/SourcesPanel.js

Issue 2234193002: DevTools: migrate some of the sources panel sidebar panes to view management, allow view toolbars. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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) 2008 Apple Inc. All Rights Reserved. 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved.
3 * Copyright (C) 2011 Google Inc. All rights reserved. 3 * Copyright (C) 2011 Google Inc. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
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 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 this._sourcesView = new WebInspector.SourcesView(); 79 this._sourcesView = new WebInspector.SourcesView();
80 this._sourcesView.addEventListener(WebInspector.SourcesView.Events.EditorSel ected, this._editorSelected.bind(this)); 80 this._sourcesView.addEventListener(WebInspector.SourcesView.Events.EditorSel ected, this._editorSelected.bind(this));
81 this._sourcesView.addEventListener(WebInspector.SourcesView.Events.EditorClo sed, this._editorClosed.bind(this)); 81 this._sourcesView.addEventListener(WebInspector.SourcesView.Events.EditorClo sed, this._editorClosed.bind(this));
82 this._sourcesView.registerShortcuts(this.registerShortcuts.bind(this)); 82 this._sourcesView.registerShortcuts(this.registerShortcuts.bind(this));
83 this.editorView.setMainWidget(this._sourcesView); 83 this.editorView.setMainWidget(this._sourcesView);
84 84
85 this.sidebarPanes = {}; 85 this.sidebarPanes = {};
86 this.sidebarPanes.threads = null; 86 this.sidebarPanes.threads = null;
87 this.sidebarPanes.watchExpressions = new WebInspector.WatchExpressionsSideba rPane(); 87 this.sidebarPanes.watchExpressions = new WebInspector.WatchExpressionsSideba rPane();
88 this.sidebarPanes.callstack = new WebInspector.CallStackSidebarPane(); 88 this.sidebarPanes.callstack = new WebInspector.CallStackSidebarPane();
89 this.sidebarPanes.callstack.addEventListener(WebInspector.CallStackSidebarPa ne.Events.CallFrameSelected, this._callFrameSelectedInSidebar.bind(this));
90 this.sidebarPanes.callstack.registerShortcuts(this.registerShortcuts.bind(th is)); 89 this.sidebarPanes.callstack.registerShortcuts(this.registerShortcuts.bind(th is));
91 90
92 this.sidebarPanes.scopechain = new WebInspector.ScopeChainSidebarPane(); 91 this.sidebarPanes.scopechain = new WebInspector.ScopeChainSidebarPane();
93 this.sidebarPanes.jsBreakpoints = new WebInspector.JavaScriptBreakpointsSide barPane(WebInspector.breakpointManager, this.showUISourceCode.bind(this)); 92 this.sidebarPanes.jsBreakpoints = new WebInspector.JavaScriptBreakpointsSide barPane(WebInspector.breakpointManager, this.showUISourceCode.bind(this));
94 this.sidebarPanes.xhrBreakpoints = new WebInspector.XHRBreakpointsSidebarPan e();
95 this.sidebarPanes.eventListenerBreakpoints = new WebInspector.EventListenerB reakpointsSidebarPane();
96 this.sidebarPanes.objectEventListeners = new WebInspector.ObjectEventListene rsSidebarPane();
97 93
98 this._installDebuggerSidebarController(); 94 this._installDebuggerSidebarController();
99 95
100 WebInspector.moduleSetting("sidebarPosition").addChangeListener(this._update SidebarPosition.bind(this)); 96 WebInspector.moduleSetting("sidebarPosition").addChangeListener(this._update SidebarPosition.bind(this));
101 this._updateSidebarPosition(); 97 this._updateSidebarPosition();
102 98
103 this._updateDebuggerButtons(); 99 this._updateDebuggerButtons();
104 this._pauseOnExceptionEnabledChanged(); 100 this._pauseOnExceptionEnabledChanged();
105 WebInspector.moduleSetting("pauseOnExceptionEnabled").addChangeListener(this ._pauseOnExceptionEnabledChanged, this); 101 WebInspector.moduleSetting("pauseOnExceptionEnabled").addChangeListener(this ._pauseOnExceptionEnabledChanged, this);
106 102
107 this._liveLocationPool = new WebInspector.LiveLocationPool(); 103 this._liveLocationPool = new WebInspector.LiveLocationPool();
108 104
109 this._setTarget(WebInspector.context.flavor(WebInspector.Target)); 105 this._setTarget(WebInspector.context.flavor(WebInspector.Target));
110 WebInspector.breakpointManager.addEventListener(WebInspector.BreakpointManag er.Events.BreakpointsActiveStateChanged, this._breakpointsActiveStateChanged, th is); 106 WebInspector.breakpointManager.addEventListener(WebInspector.BreakpointManag er.Events.BreakpointsActiveStateChanged, this._breakpointsActiveStateChanged, th is);
111 WebInspector.context.addFlavorChangeListener(WebInspector.Target, this._onCu rrentTargetChanged, this); 107 WebInspector.context.addFlavorChangeListener(WebInspector.Target, this._onCu rrentTargetChanged, this);
112 WebInspector.targetManager.addModelListener(WebInspector.DebuggerModel, WebI nspector.DebuggerModel.Events.DebuggerWasEnabled, this._debuggerWasEnabled, this ); 108 WebInspector.targetManager.addModelListener(WebInspector.DebuggerModel, WebI nspector.DebuggerModel.Events.DebuggerWasEnabled, this._debuggerWasEnabled, this );
113 WebInspector.targetManager.addModelListener(WebInspector.DebuggerModel, WebI nspector.DebuggerModel.Events.DebuggerPaused, this._debuggerPaused, this); 109 WebInspector.targetManager.addModelListener(WebInspector.DebuggerModel, WebI nspector.DebuggerModel.Events.DebuggerPaused, this._debuggerPaused, this);
114 WebInspector.targetManager.addModelListener(WebInspector.DebuggerModel, WebI nspector.DebuggerModel.Events.DebuggerResumed, this._debuggerResumed, this); 110 WebInspector.targetManager.addModelListener(WebInspector.DebuggerModel, WebI nspector.DebuggerModel.Events.DebuggerResumed, this._debuggerResumed, this);
115 WebInspector.targetManager.addModelListener(WebInspector.DebuggerModel, WebI nspector.DebuggerModel.Events.CallFrameSelected, this._callFrameSelected, this); 111 WebInspector.targetManager.addModelListener(WebInspector.DebuggerModel, WebI nspector.DebuggerModel.Events.CallFrameSelected, this._callFrameSelectedOnModel, this);
116 WebInspector.targetManager.addModelListener(WebInspector.DebuggerModel, WebI nspector.DebuggerModel.Events.ConsoleCommandEvaluatedInSelectedCallFrame, this._ consoleCommandEvaluatedInSelectedCallFrame, this);
117 WebInspector.targetManager.addModelListener(WebInspector.DebuggerModel, WebI nspector.DebuggerModel.Events.GlobalObjectCleared, this._debuggerReset, this); 112 WebInspector.targetManager.addModelListener(WebInspector.DebuggerModel, WebI nspector.DebuggerModel.Events.GlobalObjectCleared, this._debuggerReset, this);
118 new WebInspector.WorkspaceMappingTip(this, this._workspace); 113 new WebInspector.WorkspaceMappingTip(this, this._workspace);
119 WebInspector.extensionServer.addEventListener(WebInspector.ExtensionServer.E vents.SidebarPaneAdded, this._extensionSidebarPaneAdded, this); 114 WebInspector.extensionServer.addEventListener(WebInspector.ExtensionServer.E vents.SidebarPaneAdded, this._extensionSidebarPaneAdded, this);
120 WebInspector.DataSaverInfobar.maybeShowInPanel(this); 115 WebInspector.DataSaverInfobar.maybeShowInPanel(this);
121 WebInspector.targetManager.observeTargets(this); 116 WebInspector.targetManager.observeTargets(this);
122 } 117 }
123 118
124 WebInspector.SourcesPanel._lastModificationTimeout = 200; 119 WebInspector.SourcesPanel._lastModificationTimeout = 200;
125 120
126 WebInspector.SourcesPanel.minToolbarWidth = 215; 121 WebInspector.SourcesPanel.minToolbarWidth = 215;
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 if (!target) 160 if (!target)
166 return; 161 return;
167 var debuggerModel = WebInspector.DebuggerModel.fromTarget(target); 162 var debuggerModel = WebInspector.DebuggerModel.fromTarget(target);
168 if (!debuggerModel) 163 if (!debuggerModel)
169 return; 164 return;
170 165
171 if (debuggerModel.isPaused()) { 166 if (debuggerModel.isPaused()) {
172 this._showDebuggerPausedDetails(/** @type {!WebInspector.DebuggerPau sedDetails} */ (debuggerModel.debuggerPausedDetails())); 167 this._showDebuggerPausedDetails(/** @type {!WebInspector.DebuggerPau sedDetails} */ (debuggerModel.debuggerPausedDetails()));
173 var callFrame = debuggerModel.selectedCallFrame(); 168 var callFrame = debuggerModel.selectedCallFrame();
174 if (callFrame) 169 if (callFrame)
175 this._selectCallFrame(callFrame); 170 this._selectCallFrameInUI(callFrame);
176 } else { 171 } else {
177 this._paused = false; 172 this._paused = false;
178 this._clearInterface(); 173 this._clearInterface();
179 this._toggleDebuggerSidebarButton.disabled = false; 174 this._toggleDebuggerSidebarButton.disabled = false;
180 } 175 }
181 }, 176 },
182 177
183 /** 178 /**
184 * @param {!WebInspector.Event} event 179 * @param {!WebInspector.Event} event
185 */ 180 */
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
250 245
251 /** 246 /**
252 * @override 247 * @override
253 * @return {!WebInspector.SearchableView} 248 * @return {!WebInspector.SearchableView}
254 */ 249 */
255 searchableView: function() 250 searchableView: function()
256 { 251 {
257 return this._sourcesView.searchableView(); 252 return this._sourcesView.searchableView();
258 }, 253 },
259 254
260 _consoleCommandEvaluatedInSelectedCallFrame: function(event)
261 {
262 var debuggerModel = /** @type {!WebInspector.DebuggerModel} */ (event. target);
263 var target = debuggerModel.target();
264 if (WebInspector.context.flavor(WebInspector.Target) !== target)
265 return;
266 this.sidebarPanes.scopechain.update(debuggerModel.selectedCallFrame());
dgozman 2016/08/11 01:42:16 Let's also fix the watches.
267 },
268
269 /** 255 /**
270 * @param {!WebInspector.Event} event 256 * @param {!WebInspector.Event} event
271 */ 257 */
272 _debuggerPaused: function(event) 258 _debuggerPaused: function(event)
273 { 259 {
274 var details = /** @type {!WebInspector.DebuggerPausedDetails} */ (event. data); 260 var details = /** @type {!WebInspector.DebuggerPausedDetails} */ (event. data);
275 if (!this._paused) 261 if (!this._paused)
276 WebInspector.inspectorView.setCurrentPanel(this); 262 WebInspector.inspectorView.setCurrentPanel(this);
277 263
278 if (WebInspector.context.flavor(WebInspector.Target) === details.target( )) 264 if (WebInspector.context.flavor(WebInspector.Target) === details.target( ))
279 this._showDebuggerPausedDetails(details); 265 this._showDebuggerPausedDetails(details);
280 else if (!this._paused) 266 else if (!this._paused)
281 WebInspector.context.setFlavor(WebInspector.Target, details.target() ); 267 WebInspector.context.setFlavor(WebInspector.Target, details.target() );
282 }, 268 },
283 269
284 /** 270 /**
285 * @param {!WebInspector.DebuggerPausedDetails} details 271 * @param {!WebInspector.DebuggerPausedDetails} details
286 */ 272 */
287 _showDebuggerPausedDetails: function(details) 273 _showDebuggerPausedDetails: function(details)
288 { 274 {
289 this._paused = true; 275 this._paused = true;
290 this._updateDebuggerButtons(); 276 this._updateDebuggerButtons();
291 277
292 this.sidebarPanes.callstack.update(details);
293
294 /** 278 /**
295 * @param {!WebInspector.LiveLocation} liveLocation 279 * @param {!WebInspector.LiveLocation} liveLocation
296 * @this {WebInspector.SourcesPanel} 280 * @this {WebInspector.SourcesPanel}
297 */ 281 */
298 function didGetUILocation(liveLocation) 282 function didGetUILocation(liveLocation)
299 { 283 {
300 var uiLocation = liveLocation.uiLocation(); 284 var uiLocation = liveLocation.uiLocation();
301 if (!uiLocation) 285 if (!uiLocation)
302 return; 286 return;
303 var breakpoint = WebInspector.breakpointManager.findBreakpointOnLine (uiLocation.uiSourceCode, uiLocation.lineNumber); 287 var breakpoint = WebInspector.breakpointManager.findBreakpointOnLine (uiLocation.uiSourceCode, uiLocation.lineNumber);
304 if (!breakpoint) 288 if (!breakpoint)
305 return; 289 return;
306 this.sidebarPanes.jsBreakpoints.highlightBreakpoint(breakpoint); 290 this.sidebarPanes.jsBreakpoints.highlightBreakpoint(breakpoint);
307 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a JavaScript breakpoint.")); 291 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a JavaScript breakpoint."));
308 } 292 }
309 293
310 if (details.reason === WebInspector.DebuggerModel.BreakReason.DOM) { 294 if (details.reason === WebInspector.DebuggerModel.BreakReason.DOM) {
311 WebInspector.domBreakpointsSidebarPane.highlightBreakpoint(details.a uxData);
312 this.sidebarPanes.callstack.setStatus(WebInspector.domBreakpointsSid ebarPane.createBreakpointHitStatusMessage(details)); 295 this.sidebarPanes.callstack.setStatus(WebInspector.domBreakpointsSid ebarPane.createBreakpointHitStatusMessage(details));
313 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Eve ntListener) { 296 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Eve ntListener) {
314 var eventName = details.auxData["eventName"]; 297 var eventName = details.auxData["eventName"];
315 var targetName = details.auxData["targetName"];
316 this.sidebarPanes.eventListenerBreakpoints.highlightBreakpoint(event Name, targetName);
317 var eventNameForUI = WebInspector.EventListenerBreakpointsSidebarPan e.eventNameForUI(eventName, details.auxData); 298 var eventNameForUI = WebInspector.EventListenerBreakpointsSidebarPan e.eventNameForUI(eventName, details.auxData);
318 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a \"%s\" Event Listener.", eventNameForUI)); 299 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a \"%s\" Event Listener.", eventNameForUI));
319 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.XHR ) { 300 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.XHR ) {
320 this.sidebarPanes.xhrBreakpoints.highlightBreakpoint(details.auxData ["breakpointURL"]);
321 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a XMLHttpRequest.")); 301 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a XMLHttpRequest."));
322 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Exc eption) { 302 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Exc eption) {
323 var description = details.auxData["description"] || ""; 303 var description = details.auxData["description"] || "";
324 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on exception: '%s'.", description.split("\n", 1)[0])); 304 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on exception: '%s'.", description.split("\n", 1)[0]));
325 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Pro miseRejection) { 305 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Pro miseRejection) {
326 var description = details.auxData["description"] || ""; 306 var description = details.auxData["description"] || "";
327 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on promise rejection: '%s'.", description.split("\n", 1)[0])); 307 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on promise rejection: '%s'.", description.split("\n", 1)[0]));
328 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Ass ert) { 308 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Ass ert) {
329 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on assertion.")); 309 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on assertion."));
330 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Deb ugCommand) { 310 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Deb ugCommand) {
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
487 }, 467 },
488 468
489 _updateLastModificationTimeForTest: function() 469 _updateLastModificationTimeForTest: function()
490 { 470 {
491 WebInspector.SourcesPanel._lastModificationTimeout = Number.MAX_VALUE; 471 WebInspector.SourcesPanel._lastModificationTimeout = Number.MAX_VALUE;
492 }, 472 },
493 473
494 /** 474 /**
495 * @param {!WebInspector.Event} event 475 * @param {!WebInspector.Event} event
496 */ 476 */
497 _callFrameSelected: function(event) 477 _callFrameSelectedOnModel: function(event)
498 { 478 {
499 var callFrame = /** @type {?WebInspector.DebuggerModel.CallFrame} */ (ev ent.data); 479 var callFrame = /** @type {?WebInspector.DebuggerModel.CallFrame} */ (ev ent.data);
500
501 if (!callFrame || callFrame.target() !== WebInspector.context.flavor(Web Inspector.Target)) 480 if (!callFrame || callFrame.target() !== WebInspector.context.flavor(Web Inspector.Target))
502 return; 481 return;
503 482 this._selectCallFrameInUI(callFrame);
504 this._selectCallFrame(callFrame);
505 }, 483 },
506 484
507 /** 485 /**
508 * @param {!WebInspector.DebuggerModel.CallFrame} callFrame 486 * @param {!WebInspector.DebuggerModel.CallFrame} callFrame
509 */ 487 */
510 _selectCallFrame: function(callFrame) 488 _selectCallFrameInUI: function(callFrame)
511 { 489 {
512 this.sidebarPanes.scopechain.update(callFrame); 490 WebInspector.context.setFlavor(WebInspector.DebuggerModel.CallFrame, cal lFrame);
513 this.sidebarPanes.watchExpressions.refreshExpressions();
514 this.sidebarPanes.callstack.setSelectedCallFrame(callFrame);
515 WebInspector.debuggerWorkspaceBinding.createCallFrameLiveLocation(callFr ame.location(), this._executionLineChanged.bind(this), this._liveLocationPool); 491 WebInspector.debuggerWorkspaceBinding.createCallFrameLiveLocation(callFr ame.location(), this._executionLineChanged.bind(this), this._liveLocationPool);
516 }, 492 },
517 493
518 _pauseOnExceptionEnabledChanged: function() 494 _pauseOnExceptionEnabledChanged: function()
519 { 495 {
520 var enabled = WebInspector.moduleSetting("pauseOnExceptionEnabled").get( ); 496 var enabled = WebInspector.moduleSetting("pauseOnExceptionEnabled").get( );
521 this._pauseOnExceptionButton.setToggled(enabled); 497 this._pauseOnExceptionButton.setToggled(enabled);
522 this._pauseOnExceptionButton.setTitle(WebInspector.UIString(enabled ? "D on't pause on exceptions" : "Pause on exceptions")); 498 this._pauseOnExceptionButton.setTitle(WebInspector.UIString(enabled ? "D on't pause on exceptions" : "Pause on exceptions"));
523 this._debugToolbarDrawer.classList.toggle("expanded", enabled); 499 this._debugToolbarDrawer.classList.toggle("expanded", enabled);
524 }, 500 },
(...skipping 17 matching lines...) Expand all
542 this._togglePauseAction.setToggled(false); 518 this._togglePauseAction.setToggled(false);
543 this._togglePauseAction.setEnabled(!currentDebuggerModel.isPausing() ); 519 this._togglePauseAction.setEnabled(!currentDebuggerModel.isPausing() );
544 this._stepOverAction.setEnabled(false); 520 this._stepOverAction.setEnabled(false);
545 this._stepIntoAction.setEnabled(false); 521 this._stepIntoAction.setEnabled(false);
546 this._stepOutAction.setEnabled(false); 522 this._stepOutAction.setEnabled(false);
547 } 523 }
548 }, 524 },
549 525
550 _clearInterface: function() 526 _clearInterface: function()
551 { 527 {
552 this.sidebarPanes.callstack.update(null);
553 this.sidebarPanes.scopechain.update(null);
554 this.sidebarPanes.jsBreakpoints.clearBreakpointHighlight(); 528 this.sidebarPanes.jsBreakpoints.clearBreakpointHighlight();
555 WebInspector.domBreakpointsSidebarPane.clearBreakpointHighlight();
556 this.sidebarPanes.eventListenerBreakpoints.clearBreakpointHighlight();
557 this.sidebarPanes.xhrBreakpoints.clearBreakpointHighlight();
558 if (this.sidebarPanes.asyncOperationBreakpoints) 529 if (this.sidebarPanes.asyncOperationBreakpoints)
dgozman 2016/08/11 01:42:16 Remove.
559 this.sidebarPanes.asyncOperationBreakpoints.clearBreakpointHighlight (); 530 this.sidebarPanes.asyncOperationBreakpoints.clearBreakpointHighlight ();
560 531
561 this._sourcesView.clearCurrentExecutionLine(); 532 this._sourcesView.clearCurrentExecutionLine();
562 this._updateDebuggerButtons(); 533 this._updateDebuggerButtons();
563 534
564 if (this._switchToPausedTargetTimeout) 535 if (this._switchToPausedTargetTimeout)
565 clearTimeout(this._switchToPausedTargetTimeout); 536 clearTimeout(this._switchToPausedTargetTimeout);
566 this._liveLocationPool.disposeAll(); 537 this._liveLocationPool.disposeAll();
567 }, 538 },
568 539
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
722 { 693 {
723 var debuggerModel = this._prepareToResume(); 694 var debuggerModel = this._prepareToResume();
724 if (!debuggerModel) 695 if (!debuggerModel)
725 return true; 696 return true;
726 697
727 debuggerModel.stepOut(); 698 debuggerModel.stepOut();
728 return true; 699 return true;
729 }, 700 },
730 701
731 /** 702 /**
732 * @param {!WebInspector.Event} event
733 */
734 _callFrameSelectedInSidebar: function(event)
735 {
736 var callFrame = /** @type {!WebInspector.DebuggerModel.CallFrame} */ (ev ent.data);
737 callFrame.debuggerModel.setSelectedCallFrame(callFrame);
738 },
739
740 /**
741 * @param {!WebInspector.UILocation} uiLocation 703 * @param {!WebInspector.UILocation} uiLocation
742 */ 704 */
743 _continueToLocation: function(uiLocation) 705 _continueToLocation: function(uiLocation)
744 { 706 {
745 var executionContext = WebInspector.context.flavor(WebInspector.Executio nContext); 707 var executionContext = WebInspector.context.flavor(WebInspector.Executio nContext);
746 if (!executionContext) 708 if (!executionContext)
747 return; 709 return;
748 710
749 // Always use 0 column. 711 // Always use 0 column.
750 var rawLocation = WebInspector.debuggerWorkspaceBinding.uiLocationToRawL ocation(executionContext.target(), uiLocation.uiSourceCode, uiLocation.lineNumbe r, 0); 712 var rawLocation = WebInspector.debuggerWorkspaceBinding.uiLocationToRawL ocation(executionContext.target(), uiLocation.uiSourceCode, uiLocation.lineNumbe r, 0);
(...skipping 407 matching lines...) Expand 10 before | Expand all | Expand 10 after
1158 this._sidebarPaneStack.appendView(this.sidebarPanes[pane]); 1120 this._sidebarPaneStack.appendView(this.sidebarPanes[pane]);
1159 } 1121 }
1160 this._extensionSidebarPanesContainer = this._sidebarPaneStack; 1122 this._extensionSidebarPanesContainer = this._sidebarPaneStack;
1161 this.sidebarPaneView = vbox; 1123 this.sidebarPaneView = vbox;
1162 } else { 1124 } else {
1163 var splitWidget = new WebInspector.SplitWidget(true, true, "sourcesP anelDebuggerSidebarSplitViewState", 0.5); 1125 var splitWidget = new WebInspector.SplitWidget(true, true, "sourcesP anelDebuggerSidebarSplitViewState", 0.5);
1164 splitWidget.setMainWidget(vbox); 1126 splitWidget.setMainWidget(vbox);
1165 1127
1166 // Populate the left stack. 1128 // Populate the left stack.
1167 this._sidebarPaneStack.showView(this.sidebarPanes.jsBreakpoints); 1129 this._sidebarPaneStack.showView(this.sidebarPanes.jsBreakpoints);
1168 this._sidebarPaneStack.appendView(this.sidebarPanes.xhrBreakpoints);
1169 this._sidebarPaneStack.appendView(this.sidebarPanes.eventListenerBre akpoints);
1170 this._sidebarPaneStack.appendView(this.sidebarPanes.objectEventListe ners);
1171 1130
1172 var tabbedLocation = WebInspector.viewManager.createTabbedLocation(t his._setAsCurrentPanel.bind(this)); 1131 var tabbedLocation = WebInspector.viewManager.createTabbedLocation(t his._setAsCurrentPanel.bind(this));
1173 splitWidget.setSidebarWidget(tabbedLocation.tabbedPane()); 1132 splitWidget.setSidebarWidget(tabbedLocation.tabbedPane());
1174 tabbedLocation.appendView(this.sidebarPanes.scopechain); 1133 tabbedLocation.appendView(this.sidebarPanes.scopechain);
1175 tabbedLocation.appendView(this.sidebarPanes.watchExpressions); 1134 tabbedLocation.appendView(this.sidebarPanes.watchExpressions);
1176 this._extensionSidebarPanesContainer = tabbedLocation; 1135 this._extensionSidebarPanesContainer = tabbedLocation;
1177 this.sidebarPaneView = splitWidget; 1136 this.sidebarPaneView = splitWidget;
1178 } 1137 }
1179 1138
1180 this._sidebarPaneStack.appendApplicableItems("sources-sidebar"); 1139 this._sidebarPaneStack.appendApplicableItems("sources-sidebar");
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after
1478 __proto__: WebInspector.VBox.prototype 1437 __proto__: WebInspector.VBox.prototype
1479 } 1438 }
1480 1439
1481 /** 1440 /**
1482 * @return {boolean} 1441 * @return {boolean}
1483 */ 1442 */
1484 WebInspector.SourcesPanel.WrapperView.isShowing = function() 1443 WebInspector.SourcesPanel.WrapperView.isShowing = function()
1485 { 1444 {
1486 return !!WebInspector.SourcesPanel.WrapperView._instance && WebInspector.Sou rcesPanel.WrapperView._instance.isShowing(); 1445 return !!WebInspector.SourcesPanel.WrapperView._instance && WebInspector.Sou rcesPanel.WrapperView._instance.isShowing();
1487 } 1446 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698