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

Side by Side Diff: Source/devtools/front_end/console/ConsoleViewMessage.js

Issue 272613002: DevTools: implemented scriptFailedToParse protocol event (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 7 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) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. 3 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.
4 * Copyright (C) 2009 Joseph Pecoraro 4 * Copyright (C) 2009 Joseph Pecoraro
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 9 *
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
164 this._messageElement = this._format([consoleMessage.messageT ext]); 164 this._messageElement = this._format([consoleMessage.messageT ext]);
165 } 165 }
166 } else { 166 } else {
167 var args = consoleMessage.parameters || [consoleMessage.messageT ext]; 167 var args = consoleMessage.parameters || [consoleMessage.messageT ext];
168 this._messageElement = this._format(args); 168 this._messageElement = this._format(args);
169 } 169 }
170 } 170 }
171 171
172 if (consoleMessage.source !== WebInspector.ConsoleMessage.MessageSource. Network || consoleMessage.request) { 172 if (consoleMessage.source !== WebInspector.ConsoleMessage.MessageSource. Network || consoleMessage.request) {
173 var callFrame = this._callFrameAnchorFromStackTrace(consoleMessage.s tackTrace); 173 var callFrame = this._callFrameAnchorFromStackTrace(consoleMessage.s tackTrace);
174 if (callFrame) 174 if (consoleMessage.url && consoleMessage.url !== "undefined")
175 this._anchorElement = this._linkifyLocation(consoleMessage.url, consoleMessage.line, consoleMessage.column);
176 else if (callFrame)
175 this._anchorElement = this._linkifyCallFrame(callFrame); 177 this._anchorElement = this._linkifyCallFrame(callFrame);
176 else if (consoleMessage.url && consoleMessage.url !== "undefined")
177 this._anchorElement = this._linkifyLocation(consoleMessage.url, consoleMessage.line, consoleMessage.column);
178 } 178 }
179 179
180 this._formattedMessage.appendChild(this._messageElement); 180 this._formattedMessage.appendChild(this._messageElement);
181 if (this._anchorElement) { 181 if (this._anchorElement) {
182 this._formattedMessage.appendChild(document.createTextNode(" ")); 182 this._formattedMessage.appendChild(document.createTextNode(" "));
183 this._formattedMessage.appendChild(this._anchorElement); 183 this._formattedMessage.appendChild(this._anchorElement);
184 } 184 }
185 185
186 var dumpStackTrace = !!consoleMessage.stackTrace && consoleMessage.stack Trace.length && (consoleMessage.source === WebInspector.ConsoleMessage.MessageSo urce.Network || consoleMessage.level === WebInspector.ConsoleMessage.MessageLeve l.Error || consoleMessage.type === WebInspector.ConsoleMessage.MessageType.Trace ); 186 var dumpStackTrace = !!consoleMessage.stackTrace && consoleMessage.stack Trace.length && (consoleMessage.source === WebInspector.ConsoleMessage.MessageSo urce.Network || consoleMessage.level === WebInspector.ConsoleMessage.MessageLeve l.Error || consoleMessage.type === WebInspector.ConsoleMessage.MessageType.Trace );
187 if (dumpStackTrace) { 187 if (dumpStackTrace) {
(...skipping 998 matching lines...) Expand 10 before | Expand all | Expand 10 after
1186 { 1186 {
1187 if (!this._wrapperElement) { 1187 if (!this._wrapperElement) {
1188 WebInspector.ConsoleViewMessage.prototype.toMessageElement.call(this ); 1188 WebInspector.ConsoleViewMessage.prototype.toMessageElement.call(this );
1189 this._wrapperElement.classList.toggle("collapsed", this._collapsed); 1189 this._wrapperElement.classList.toggle("collapsed", this._collapsed);
1190 } 1190 }
1191 return this._wrapperElement; 1191 return this._wrapperElement;
1192 }, 1192 },
1193 1193
1194 __proto__: WebInspector.ConsoleViewMessage.prototype 1194 __proto__: WebInspector.ConsoleViewMessage.prototype
1195 } 1195 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698