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

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

Issue 651533003: DevTools: Introduce Debugger::Reason::PromiseRejection pause reason. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: also disaply <exception> in scopes sidebar 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
« no previous file with comments | « Source/devtools/front_end/sdk/DebuggerModel.js ('k') | Source/devtools/protocol.json » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 227 matching lines...) Expand 10 before | Expand all | Expand 10 after
238 WebInspector.domBreakpointsSidebarPane.createBreakpointHitStatusMess age(details, didCreateBreakpointHitStatusMessage.bind(this)); 238 WebInspector.domBreakpointsSidebarPane.createBreakpointHitStatusMess age(details, didCreateBreakpointHitStatusMessage.bind(this));
239 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Eve ntListener) { 239 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Eve ntListener) {
240 var eventName = details.auxData["eventName"]; 240 var eventName = details.auxData["eventName"];
241 var targetName = details.auxData["targetName"]; 241 var targetName = details.auxData["targetName"];
242 this.sidebarPanes.eventListenerBreakpoints.highlightBreakpoint(event Name, targetName); 242 this.sidebarPanes.eventListenerBreakpoints.highlightBreakpoint(event Name, targetName);
243 var eventNameForUI = WebInspector.EventListenerBreakpointsSidebarPan e.eventNameForUI(eventName, details.auxData); 243 var eventNameForUI = WebInspector.EventListenerBreakpointsSidebarPan e.eventNameForUI(eventName, details.auxData);
244 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a \"%s\" Event Listener.", eventNameForUI)); 244 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a \"%s\" Event Listener.", eventNameForUI));
245 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.XHR ) { 245 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.XHR ) {
246 this.sidebarPanes.xhrBreakpoints.highlightBreakpoint(details.auxData ["breakpointURL"]); 246 this.sidebarPanes.xhrBreakpoints.highlightBreakpoint(details.auxData ["breakpointURL"]);
247 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a XMLHttpRequest.")); 247 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a XMLHttpRequest."));
248 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Exc eption) 248 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Exc eption) {
249 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on exception: '%s'.", details.auxData["description"])); 249 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on exception: '%s'.", details.auxData["description"]));
250 else if (details.reason === WebInspector.DebuggerModel.BreakReason.Asser t) 250 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Pro miseRejection) {
251 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on promise rejection: '%s'.", details.auxData["description"]));
252 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Ass ert) {
251 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on assertion.")); 253 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on assertion."));
252 else if (details.reason === WebInspector.DebuggerModel.BreakReason.CSPVi olation) 254 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.CSP Violation) {
253 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a script blocked due to Content Security Policy directive: \"%s\".", details. auxData["directiveText"])); 255 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a script blocked due to Content Security Policy directive: \"%s\".", details. auxData["directiveText"]));
254 else if (details.reason === WebInspector.DebuggerModel.BreakReason.Debug Command) 256 } else if (details.reason === WebInspector.DebuggerModel.BreakReason.Deb ugCommand) {
255 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a debugged function")); 257 this.sidebarPanes.callstack.setStatus(WebInspector.UIString("Paused on a debugged function"));
256 else { 258 } else {
257 if (details.callFrames.length) 259 if (details.callFrames.length)
258 WebInspector.debuggerWorkspaceBinding.createCallFrameLiveLocatio n(details.callFrames[0], didGetUILocation.bind(this)); 260 WebInspector.debuggerWorkspaceBinding.createCallFrameLiveLocatio n(details.callFrames[0], didGetUILocation.bind(this));
259 else 261 else
260 console.warn("ScriptsPanel paused, but callFrames.length is zero ."); // TODO remove this once we understand this case better 262 console.warn("ScriptsPanel paused, but callFrames.length is zero ."); // TODO remove this once we understand this case better
261 } 263 }
262 264
263 this._splitView.showBoth(true); 265 this._splitView.showBoth(true);
264 this._toggleDebuggerSidebarButton.setEnabled(false); 266 this._toggleDebuggerSidebarButton.setEnabled(false);
265 window.focus(); 267 window.focus();
266 InspectorFrontendHost.bringToFront(); 268 InspectorFrontendHost.bringToFront();
(...skipping 1137 matching lines...) Expand 10 before | Expand all | Expand 10 after
1404 1406
1405 WebInspector.SourcesPanelFactory.prototype = { 1407 WebInspector.SourcesPanelFactory.prototype = {
1406 /** 1408 /**
1407 * @return {!WebInspector.Panel} 1409 * @return {!WebInspector.Panel}
1408 */ 1410 */
1409 createPanel: function() 1411 createPanel: function()
1410 { 1412 {
1411 return WebInspector.SourcesPanel.instance(); 1413 return WebInspector.SourcesPanel.instance();
1412 } 1414 }
1413 } 1415 }
OLDNEW
« no previous file with comments | « Source/devtools/front_end/sdk/DebuggerModel.js ('k') | Source/devtools/protocol.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698