OLD | NEW |
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 418 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
429 /** @type {number} */ | 429 /** @type {number} */ |
430 this.column = column || 0; | 430 this.column = column || 0; |
431 this.parameters = parameters; | 431 this.parameters = parameters; |
432 /** @type {!Protocol.Runtime.StackTrace|undefined} */ | 432 /** @type {!Protocol.Runtime.StackTrace|undefined} */ |
433 this.stackTrace = stackTrace; | 433 this.stackTrace = stackTrace; |
434 this.timestamp = timestamp || Date.now(); | 434 this.timestamp = timestamp || Date.now(); |
435 this.executionContextId = executionContextId || 0; | 435 this.executionContextId = executionContextId || 0; |
436 this.scriptId = scriptId || null; | 436 this.scriptId = scriptId || null; |
437 this.workerId = workerId || null; | 437 this.workerId = workerId || null; |
438 | 438 |
439 var networkLog = target && SDK.NetworkLog.fromTarget(target); | 439 this.request = (target && requestId) ? SDK.networkLog.requestForId(target, r
equestId) : null; |
440 this.request = (requestId && networkLog) ? networkLog.requestForId(requestId
) : null; | |
441 | 440 |
442 if (this.request) { | 441 if (this.request) { |
443 var initiator = this.request.initiator(); | 442 var initiator = this.request.initiator(); |
444 if (initiator) { | 443 if (initiator) { |
445 this.stackTrace = initiator.stack || undefined; | 444 this.stackTrace = initiator.stack || undefined; |
446 if (initiator.url) { | 445 if (initiator.url) { |
447 this.url = initiator.url; | 446 this.url = initiator.url; |
448 this.line = initiator.lineNumber || 0; | 447 this.line = initiator.lineNumber || 0; |
449 } | 448 } |
450 } | 449 } |
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
665 return 2; | 664 return 2; |
666 return 3; | 665 return 3; |
667 }; | 666 }; |
668 | 667 |
669 ConsoleModel.ConsoleModel._events = Symbol('ConsoleModel.ConsoleModel.events'); | 668 ConsoleModel.ConsoleModel._events = Symbol('ConsoleModel.ConsoleModel.events'); |
670 | 669 |
671 /** | 670 /** |
672 * @type {!ConsoleModel.ConsoleModel} | 671 * @type {!ConsoleModel.ConsoleModel} |
673 */ | 672 */ |
674 ConsoleModel.consoleModel; | 673 ConsoleModel.consoleModel; |
OLD | NEW |