| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Apple Inc. All rights reserved. | 2 * Copyright (C) 2013 Apple 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 | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * | 7 * |
| 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 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 65 { | 65 { |
| 66 if (muteCount) | 66 if (muteCount) |
| 67 return; | 67 return; |
| 68 | 68 |
| 69 // FIXME: This should not need to reach for the main-frame. | 69 // FIXME: This should not need to reach for the main-frame. |
| 70 // Inspector code should just take the current frame and know how to walk it
self. | 70 // Inspector code should just take the current frame and know how to walk it
self. |
| 71 ExecutionContext* context = m_frame.document(); | 71 ExecutionContext* context = m_frame.document(); |
| 72 if (!context) | 72 if (!context) |
| 73 return; | 73 return; |
| 74 | 74 |
| 75 String messageURL; | 75 String messageURL = url; |
| 76 if (callStack) { | 76 if (callStack) { |
| 77 messageURL = callStack->at(0).sourceURL(); | 77 InspectorInstrumentation::addMessageToConsole(context, source, LogMessag
eType, level, message, url, lineNumber, columnNumber, callStack, scriptState, re
questIdentifier); |
| 78 InspectorInstrumentation::addMessageToConsole(context, source, LogMessag
eType, level, message, callStack, requestIdentifier); | |
| 79 } else { | 78 } else { |
| 80 messageURL = url; | |
| 81 InspectorInstrumentation::addMessageToConsole(context, source, LogMessag
eType, level, message, url, lineNumber, columnNumber, scriptState, requestIdenti
fier); | 79 InspectorInstrumentation::addMessageToConsole(context, source, LogMessag
eType, level, message, url, lineNumber, columnNumber, scriptState, requestIdenti
fier); |
| 82 } | 80 } |
| 83 | 81 |
| 84 if (source == CSSMessageSource) | 82 if (source == CSSMessageSource) |
| 85 return; | 83 return; |
| 86 | 84 |
| 87 String stackTrace; | 85 String stackTrace; |
| 88 if (callStack && m_frame.chromeClient().shouldReportDetailedMessageForSource
(messageURL)) | 86 if (callStack && m_frame.chromeClient().shouldReportDetailedMessageForSource
(messageURL)) |
| 89 stackTrace = FrameConsole::formatStackTraceString(message, callStack); | 87 stackTrace = FrameConsole::formatStackTraceString(message, callStack); |
| 90 | 88 |
| (...skipping 23 matching lines...) Expand all Loading... |
| 114 muteCount++; | 112 muteCount++; |
| 115 } | 113 } |
| 116 | 114 |
| 117 void FrameConsole::unmute() | 115 void FrameConsole::unmute() |
| 118 { | 116 { |
| 119 ASSERT(muteCount > 0); | 117 ASSERT(muteCount > 0); |
| 120 muteCount--; | 118 muteCount--; |
| 121 } | 119 } |
| 122 | 120 |
| 123 } // namespace WebCore | 121 } // namespace WebCore |
| OLD | NEW |