| OLD | NEW |
| (Empty) |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef WorkletConsole_h | |
| 6 #define WorkletConsole_h | |
| 7 | |
| 8 #include "core/frame/ConsoleBase.h" | |
| 9 #include "core/frame/ConsoleTypes.h" | |
| 10 #include "core/inspector/ConsoleAPITypes.h" | |
| 11 #include "platform/heap/Handle.h" | |
| 12 | |
| 13 namespace blink { | |
| 14 | |
| 15 class ConsoleMessage; | |
| 16 class WorkletGlobalScope; | |
| 17 | |
| 18 class WorkletConsole final : public ConsoleBase { | |
| 19 DEFINE_WRAPPERTYPEINFO(); | |
| 20 public: | |
| 21 static WorkletConsole* create(WorkletGlobalScope* scope) | |
| 22 { | |
| 23 return new WorkletConsole(scope); | |
| 24 } | |
| 25 ~WorkletConsole() override; | |
| 26 | |
| 27 DECLARE_VIRTUAL_TRACE(); | |
| 28 | |
| 29 protected: | |
| 30 ExecutionContext* context() final; | |
| 31 void reportMessageToConsole(ConsoleMessage*) final; | |
| 32 | |
| 33 private: | |
| 34 explicit WorkletConsole(WorkletGlobalScope*); | |
| 35 | |
| 36 Member<WorkletGlobalScope> m_scope; | |
| 37 }; | |
| 38 | |
| 39 } // namespace blink | |
| 40 | |
| 41 #endif // WorkletConsole_h | |
| OLD | NEW |