OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef ThreadDebugger_h | 5 #ifndef ThreadDebugger_h |
6 #define ThreadDebugger_h | 6 #define ThreadDebugger_h |
7 | 7 |
8 #include <memory> | 8 #include <memory> |
9 #include "core/CoreExport.h" | 9 #include "core/CoreExport.h" |
10 #include "core/inspector/ConsoleTypes.h" | 10 #include "core/inspector/ConsoleTypes.h" |
(...skipping 25 matching lines...) Expand all Loading... |
36 v8_inspector::V8Inspector* GetV8Inspector() const { | 36 v8_inspector::V8Inspector* GetV8Inspector() const { |
37 return v8_inspector_.get(); | 37 return v8_inspector_.get(); |
38 } | 38 } |
39 | 39 |
40 static void IdleStarted(v8::Isolate*); | 40 static void IdleStarted(v8::Isolate*); |
41 static void IdleFinished(v8::Isolate*); | 41 static void IdleFinished(v8::Isolate*); |
42 | 42 |
43 void AsyncTaskScheduled(const String& task_name, void* task, bool recurring); | 43 void AsyncTaskScheduled(const String& task_name, void* task, bool recurring); |
44 void AsyncTaskCanceled(void* task); | 44 void AsyncTaskCanceled(void* task); |
45 void AllAsyncTasksCanceled(); | 45 void AllAsyncTasksCanceled(); |
46 void AsyncTaskStarted(void* task); | 46 bool AsyncTaskStarted(void* task, bool optional); |
47 void AsyncTaskFinished(void* task); | 47 void AsyncTaskFinished(void* task); |
48 unsigned PromiseRejected(v8::Local<v8::Context>, | 48 unsigned PromiseRejected(v8::Local<v8::Context>, |
49 const String& error_message, | 49 const String& error_message, |
50 v8::Local<v8::Value> exception, | 50 v8::Local<v8::Value> exception, |
51 std::unique_ptr<SourceLocation>); | 51 std::unique_ptr<SourceLocation>); |
52 void PromiseRejectionRevoked(v8::Local<v8::Context>, | 52 void PromiseRejectionRevoked(v8::Local<v8::Context>, |
53 unsigned promise_rejection_id); | 53 unsigned promise_rejection_id); |
54 | 54 |
55 protected: | 55 protected: |
56 virtual int ContextGroupId(ExecutionContext*) = 0; | 56 virtual int ContextGroupId(ExecutionContext*) = 0; |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 | 103 |
104 static void GetEventListenersCallback( | 104 static void GetEventListenersCallback( |
105 const v8::FunctionCallbackInfo<v8::Value>&); | 105 const v8::FunctionCallbackInfo<v8::Value>&); |
106 | 106 |
107 std::unique_ptr<v8_inspector::V8Inspector> v8_inspector_; | 107 std::unique_ptr<v8_inspector::V8Inspector> v8_inspector_; |
108 std::unique_ptr<v8::TracingCpuProfiler> v8_tracing_cpu_profiler_; | 108 std::unique_ptr<v8::TracingCpuProfiler> v8_tracing_cpu_profiler_; |
109 Vector<std::unique_ptr<Timer<ThreadDebugger>>> timers_; | 109 Vector<std::unique_ptr<Timer<ThreadDebugger>>> timers_; |
110 Vector<v8_inspector::V8InspectorClient::TimerCallback> timer_callbacks_; | 110 Vector<v8_inspector::V8InspectorClient::TimerCallback> timer_callbacks_; |
111 Vector<void*> timer_data_; | 111 Vector<void*> timer_data_; |
112 std::unique_ptr<UserGestureIndicator> user_gesture_indicator_; | 112 std::unique_ptr<UserGestureIndicator> user_gesture_indicator_; |
| 113 |
| 114 int current_async_tasks_ = 0; |
113 }; | 115 }; |
114 | 116 |
115 } // namespace blink | 117 } // namespace blink |
116 | 118 |
117 #endif // ThreadDebugger_h | 119 #endif // ThreadDebugger_h |
OLD | NEW |