OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2007 Apple Inc. All rights reserved. | 2 * Copyright (C) 2007 Apple Inc. All rights reserved. |
3 * Copyright (C) 2013 Google Inc. All rights reserved. | 3 * Copyright (C) 2013 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 * | 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 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
47 | 47 |
48 WorkerConsole::~WorkerConsole() | 48 WorkerConsole::~WorkerConsole() |
49 { | 49 { |
50 } | 50 } |
51 | 51 |
52 void WorkerConsole::reportMessageToConsole(PassRefPtrWillBeRawPtr<ConsoleMessage
> consoleMessage) | 52 void WorkerConsole::reportMessageToConsole(PassRefPtrWillBeRawPtr<ConsoleMessage
> consoleMessage) |
53 { | 53 { |
54 const ScriptCallFrame& lastCaller = consoleMessage->callStack()->at(0); | 54 const ScriptCallFrame& lastCaller = consoleMessage->callStack()->at(0); |
55 consoleMessage->setURL(lastCaller.sourceURL()); | 55 consoleMessage->setURL(lastCaller.sourceURL()); |
56 consoleMessage->setLineNumber(lastCaller.lineNumber()); | 56 consoleMessage->setLineNumber(lastCaller.lineNumber()); |
57 m_scope->addMessage(consoleMessage); | 57 m_scope->addConsoleMessage(consoleMessage); |
58 } | 58 } |
59 | 59 |
60 ExecutionContext* WorkerConsole::context() | 60 ExecutionContext* WorkerConsole::context() |
61 { | 61 { |
62 if (!m_scope) | 62 if (!m_scope) |
63 return 0; | 63 return 0; |
64 return m_scope->executionContext(); | 64 return m_scope->executionContext(); |
65 } | 65 } |
66 | 66 |
67 void WorkerConsole::trace(Visitor* visitor) | 67 void WorkerConsole::trace(Visitor* visitor) |
68 { | 68 { |
69 visitor->trace(m_scope); | 69 visitor->trace(m_scope); |
70 ConsoleBase::trace(visitor); | 70 ConsoleBase::trace(visitor); |
71 } | 71 } |
72 | 72 |
73 // FIXME: add memory getter | 73 // FIXME: add memory getter |
74 | 74 |
75 } // namespace blink | 75 } // namespace blink |
OLD | NEW |