| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2009 Joseph Pecoraro | 3 * Copyright (C) 2009 Joseph Pecoraro |
| 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 * | 8 * |
| 9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
| 10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
| (...skipping 796 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 807 _printResult: function(result, originatingConsoleMessage, exceptionDetails) | 807 _printResult: function(result, originatingConsoleMessage, exceptionDetails) |
| 808 { | 808 { |
| 809 if (!result) | 809 if (!result) |
| 810 return; | 810 return; |
| 811 | 811 |
| 812 var level = !!exceptionDetails ? WebInspector.ConsoleMessage.MessageLeve
l.Error : WebInspector.ConsoleMessage.MessageLevel.Log; | 812 var level = !!exceptionDetails ? WebInspector.ConsoleMessage.MessageLeve
l.Error : WebInspector.ConsoleMessage.MessageLevel.Log; |
| 813 var message; | 813 var message; |
| 814 if (!exceptionDetails) | 814 if (!exceptionDetails) |
| 815 message = new WebInspector.ConsoleMessage(result.target(), WebInspec
tor.ConsoleMessage.MessageSource.JS, level, "", WebInspector.ConsoleMessage.Mess
ageType.Result, undefined, undefined, undefined, undefined, [result]); | 815 message = new WebInspector.ConsoleMessage(result.target(), WebInspec
tor.ConsoleMessage.MessageSource.JS, level, "", WebInspector.ConsoleMessage.Mess
ageType.Result, undefined, undefined, undefined, undefined, [result]); |
| 816 else | 816 else |
| 817 message = new WebInspector.ConsoleMessage(result.target(), WebInspec
tor.ConsoleMessage.MessageSource.JS, level, exceptionDetails.text, WebInspector.
ConsoleMessage.MessageType.Result, undefined, exceptionDetails.lineNumber, excep
tionDetails.columnNumber, undefined, [WebInspector.UIString("Uncaught"), result]
, exceptionDetails.stackTrace, undefined, undefined, exceptionDetails.scriptId); | 817 message = WebInspector.ConsoleMessage.fromException(result.target(),
exceptionDetails, WebInspector.ConsoleMessage.MessageType.Result, undefined, un
defined); |
| 818 message.setOriginatingMessage(originatingConsoleMessage); | 818 message.setOriginatingMessage(originatingConsoleMessage); |
| 819 result.target().consoleModel.addMessage(message); | 819 result.target().consoleModel.addMessage(message); |
| 820 }, | 820 }, |
| 821 | 821 |
| 822 /** | 822 /** |
| 823 * @param {string} text | 823 * @param {string} text |
| 824 * @param {boolean} useCommandLineAPI | 824 * @param {boolean} useCommandLineAPI |
| 825 */ | 825 */ |
| 826 _appendCommand: function(text, useCommandLineAPI) | 826 _appendCommand: function(text, useCommandLineAPI) |
| 827 { | 827 { |
| (...skipping 582 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1410 return true; | 1410 return true; |
| 1411 } | 1411 } |
| 1412 return false; | 1412 return false; |
| 1413 } | 1413 } |
| 1414 } | 1414 } |
| 1415 | 1415 |
| 1416 /** | 1416 /** |
| 1417 * @typedef {{messageIndex: number, matchIndex: number}} | 1417 * @typedef {{messageIndex: number, matchIndex: number}} |
| 1418 */ | 1418 */ |
| 1419 WebInspector.ConsoleView.RegexMatchRange; | 1419 WebInspector.ConsoleView.RegexMatchRange; |
| OLD | NEW |