| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 #include "bindings/core/v8/RejectedPromises.h" | 5 #include "bindings/core/v8/RejectedPromises.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 #include "bindings/core/v8/ScopedPersistent.h" | 8 #include "bindings/core/v8/ScopedPersistent.h" |
| 9 #include "bindings/core/v8/ScriptState.h" | 9 #include "bindings/core/v8/ScriptState.h" |
| 10 #include "bindings/core/v8/ScriptValue.h" | 10 #include "bindings/core/v8/ScriptValue.h" |
| 11 #include "bindings/core/v8/V8BindingForCore.h" | 11 #include "bindings/core/v8/V8BindingForCore.h" |
| 12 #include "bindings/core/v8/V8PerIsolateData.h" | 12 #include "bindings/core/v8/V8PerIsolateData.h" |
| 13 #include "core/dom/ExecutionContext.h" | 13 #include "core/dom/ExecutionContext.h" |
| 14 #include "core/events/EventTarget.h" | 14 #include "core/events/EventTarget.h" |
| 15 #include "core/events/PromiseRejectionEvent.h" | 15 #include "core/events/PromiseRejectionEvent.h" |
| 16 #include "core/inspector/ThreadDebugger.h" | 16 #include "core/inspector/ThreadDebugger.h" |
| 17 #include "platform/WebTaskRunner.h" | 17 #include "platform/WebTaskRunner.h" |
| 18 #include "platform/scheduler/child/web_scheduler.h" |
| 18 #include "platform/wtf/Functional.h" | 19 #include "platform/wtf/Functional.h" |
| 19 #include "platform/wtf/PtrUtil.h" | 20 #include "platform/wtf/PtrUtil.h" |
| 20 #include "public/platform/Platform.h" | 21 #include "public/platform/Platform.h" |
| 21 #include "public/platform/WebScheduler.h" | |
| 22 #include "public/platform/WebThread.h" | 22 #include "public/platform/WebThread.h" |
| 23 | 23 |
| 24 namespace blink { | 24 namespace blink { |
| 25 | 25 |
| 26 static const unsigned kMaxReportedHandlersPendingResolution = 1000; | 26 static const unsigned kMaxReportedHandlersPendingResolution = 1000; |
| 27 | 27 |
| 28 class RejectedPromises::Message final { | 28 class RejectedPromises::Message final { |
| 29 public: | 29 public: |
| 30 static std::unique_ptr<Message> Create( | 30 static std::unique_ptr<Message> Create( |
| 31 ScriptState* script_state, | 31 ScriptState* script_state, |
| (...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 281 kMaxReportedHandlersPendingResolution / 10); | 281 kMaxReportedHandlersPendingResolution / 10); |
| 282 } | 282 } |
| 283 } | 283 } |
| 284 } | 284 } |
| 285 | 285 |
| 286 void RejectedPromises::RevokeNow(std::unique_ptr<Message> message) { | 286 void RejectedPromises::RevokeNow(std::unique_ptr<Message> message) { |
| 287 message->Revoke(); | 287 message->Revoke(); |
| 288 } | 288 } |
| 289 | 289 |
| 290 } // namespace blink | 290 } // namespace blink |
| OLD | NEW |