| 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 23 matching lines...) Expand all Loading... |
| 34 #include "bindings/core/v8/ScriptDebugServer.h" | 34 #include "bindings/core/v8/ScriptDebugServer.h" |
| 35 #include "core/inspector/WorkerInspectorController.h" | 35 #include "core/inspector/WorkerInspectorController.h" |
| 36 #include "core/workers/WorkerGlobalScope.h" | 36 #include "core/workers/WorkerGlobalScope.h" |
| 37 #include "core/workers/WorkerThread.h" | 37 #include "core/workers/WorkerThread.h" |
| 38 #include "wtf/MessageQueue.h" | 38 #include "wtf/MessageQueue.h" |
| 39 | 39 |
| 40 namespace blink { | 40 namespace blink { |
| 41 | 41 |
| 42 namespace { | 42 namespace { |
| 43 | 43 |
| 44 class RunInspectorCommandsTask FINAL : public ScriptDebugServer::Task { | 44 class RunInspectorCommandsTask final : public ScriptDebugServer::Task { |
| 45 public: | 45 public: |
| 46 explicit RunInspectorCommandsTask(WorkerThread* thread) | 46 explicit RunInspectorCommandsTask(WorkerThread* thread) |
| 47 : m_thread(thread) { } | 47 : m_thread(thread) { } |
| 48 virtual ~RunInspectorCommandsTask() { } | 48 virtual ~RunInspectorCommandsTask() { } |
| 49 virtual void run() OVERRIDE | 49 virtual void run() override |
| 50 { | 50 { |
| 51 // Process all queued debugger commands. WorkerThread is certainly | 51 // Process all queued debugger commands. WorkerThread is certainly |
| 52 // alive if this task is being executed. | 52 // alive if this task is being executed. |
| 53 m_thread->willEnterNestedLoop(); | 53 m_thread->willEnterNestedLoop(); |
| 54 while (MessageQueueMessageReceived == m_thread->runDebuggerTask(WorkerTh
read::DontWaitForMessage)) { } | 54 while (MessageQueueMessageReceived == m_thread->runDebuggerTask(WorkerTh
read::DontWaitForMessage)) { } |
| 55 m_thread->didLeaveNestedLoop(); | 55 m_thread->didLeaveNestedLoop(); |
| 56 } | 56 } |
| 57 | 57 |
| 58 private: | 58 private: |
| 59 WorkerThread* m_thread; | 59 WorkerThread* m_thread; |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 116 { | 116 { |
| 117 // We don't need to mute console for workers. | 117 // We don't need to mute console for workers. |
| 118 } | 118 } |
| 119 | 119 |
| 120 void WorkerDebuggerAgent::unmuteConsole() | 120 void WorkerDebuggerAgent::unmuteConsole() |
| 121 { | 121 { |
| 122 // We don't need to mute console for workers. | 122 // We don't need to mute console for workers. |
| 123 } | 123 } |
| 124 | 124 |
| 125 } // namespace blink | 125 } // namespace blink |
| OLD | NEW |