OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 CONTENT_CHILD_BLINK_PLATFORM_IMPL_H_ | 5 #ifndef CONTENT_CHILD_BLINK_PLATFORM_IMPL_H_ |
6 #define CONTENT_CHILD_BLINK_PLATFORM_IMPL_H_ | 6 #define CONTENT_CHILD_BLINK_PLATFORM_IMPL_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <stdint.h> | 9 #include <stdint.h> |
10 | 10 |
11 #include "base/compiler_specific.h" | 11 #include "base/compiler_specific.h" |
12 #include "base/threading/thread_local_storage.h" | 12 #include "base/threading/thread_local_storage.h" |
13 #include "base/timer/timer.h" | 13 #include "base/timer/timer.h" |
14 #include "base/trace_event/trace_event.h" | 14 #include "base/trace_event/trace_event.h" |
15 #include "build/build_config.h" | 15 #include "build/build_config.h" |
16 #include "components/webcrypto/webcrypto_impl.h" | 16 #include "components/webcrypto/webcrypto_impl.h" |
17 #include "content/child/webfallbackthemeengine_impl.h" | 17 #include "content/child/webfallbackthemeengine_impl.h" |
18 #include "content/common/content_export.h" | 18 #include "content/common/content_export.h" |
| 19 #include "media/blink/webmediacapabilitiesclient_impl.h" |
19 #include "third_party/WebKit/public/platform/Platform.h" | 20 #include "third_party/WebKit/public/platform/Platform.h" |
20 #include "third_party/WebKit/public/platform/WebGestureDevice.h" | 21 #include "third_party/WebKit/public/platform/WebGestureDevice.h" |
21 #include "third_party/WebKit/public/platform/WebURLError.h" | 22 #include "third_party/WebKit/public/platform/WebURLError.h" |
22 #include "third_party/WebKit/public/public_features.h" | 23 #include "third_party/WebKit/public/public_features.h" |
23 #include "ui/base/layout.h" | 24 #include "ui/base/layout.h" |
24 | 25 |
25 #if BUILDFLAG(USE_DEFAULT_RENDER_THEME) | 26 #if BUILDFLAG(USE_DEFAULT_RENDER_THEME) |
26 #include "content/child/webthemeengine_impl_default.h" | 27 #include "content/child/webthemeengine_impl_default.h" |
27 #elif defined(OS_WIN) | 28 #elif defined(OS_WIN) |
28 #include "content/child/webthemeengine_impl_win.h" | 29 #include "content/child/webthemeengine_impl_win.h" |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
103 blink::WebGestureDevice device_source, | 104 blink::WebGestureDevice device_source, |
104 const blink::WebFloatPoint& velocity, | 105 const blink::WebFloatPoint& velocity, |
105 const blink::WebSize& cumulative_scroll) override; | 106 const blink::WebSize& cumulative_scroll) override; |
106 void didStartWorkerThread() override; | 107 void didStartWorkerThread() override; |
107 void willStopWorkerThread() override; | 108 void willStopWorkerThread() override; |
108 bool allowScriptExtensionForServiceWorker( | 109 bool allowScriptExtensionForServiceWorker( |
109 const blink::WebURL& script_url) override; | 110 const blink::WebURL& script_url) override; |
110 blink::WebCrypto* crypto() override; | 111 blink::WebCrypto* crypto() override; |
111 blink::WebNotificationManager* notificationManager() override; | 112 blink::WebNotificationManager* notificationManager() override; |
112 blink::WebPushProvider* pushProvider() override; | 113 blink::WebPushProvider* pushProvider() override; |
| 114 blink::WebMediaCapabilitiesClient* mediaCapabilitiesClient() override; |
113 | 115 |
114 blink::WebString domCodeStringFromEnum(int dom_code) override; | 116 blink::WebString domCodeStringFromEnum(int dom_code) override; |
115 int domEnumFromCodeString(const blink::WebString& codeString) override; | 117 int domEnumFromCodeString(const blink::WebString& codeString) override; |
116 blink::WebString domKeyStringFromEnum(int dom_key) override; | 118 blink::WebString domKeyStringFromEnum(int dom_key) override; |
117 int domKeyEnumFromString(const blink::WebString& key_string) override; | 119 int domKeyEnumFromString(const blink::WebString& key_string) override; |
118 | 120 |
119 // This class does *not* own the compositor thread. It is the responsibility | 121 // This class does *not* own the compositor thread. It is the responsibility |
120 // of the caller to ensure that the compositor thread is cleared before it is | 122 // of the caller to ensure that the compositor thread is cleared before it is |
121 // destructed. | 123 // destructed. |
122 void SetCompositorThread(blink::scheduler::WebThreadBase* compositor_thread); | 124 void SetCompositorThread(blink::scheduler::WebThreadBase* compositor_thread); |
(...skipping 12 matching lines...) Expand all Loading... |
135 void WaitUntilWebThreadTLSUpdate(blink::scheduler::WebThreadBase* thread); | 137 void WaitUntilWebThreadTLSUpdate(blink::scheduler::WebThreadBase* thread); |
136 void UpdateWebThreadTLS(blink::WebThread* thread, base::WaitableEvent* event); | 138 void UpdateWebThreadTLS(blink::WebThread* thread, base::WaitableEvent* event); |
137 | 139 |
138 bool IsMainThread() const; | 140 bool IsMainThread() const; |
139 | 141 |
140 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner_; | 142 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner_; |
141 WebThemeEngineImpl native_theme_engine_; | 143 WebThemeEngineImpl native_theme_engine_; |
142 WebFallbackThemeEngineImpl fallback_theme_engine_; | 144 WebFallbackThemeEngineImpl fallback_theme_engine_; |
143 base::ThreadLocalStorage::Slot current_thread_slot_; | 145 base::ThreadLocalStorage::Slot current_thread_slot_; |
144 webcrypto::WebCryptoImpl web_crypto_; | 146 webcrypto::WebCryptoImpl web_crypto_; |
| 147 media::WebMediaCapabilitiesClientImpl media_capabilities_client_; |
145 | 148 |
146 scoped_refptr<ThreadSafeSender> thread_safe_sender_; | 149 scoped_refptr<ThreadSafeSender> thread_safe_sender_; |
147 scoped_refptr<NotificationDispatcher> notification_dispatcher_; | 150 scoped_refptr<NotificationDispatcher> notification_dispatcher_; |
148 | 151 |
149 blink::scheduler::WebThreadBase* compositor_thread_; | 152 blink::scheduler::WebThreadBase* compositor_thread_; |
150 }; | 153 }; |
151 | 154 |
152 } // namespace content | 155 } // namespace content |
153 | 156 |
154 #endif // CONTENT_CHILD_BLINK_PLATFORM_IMPL_H_ | 157 #endif // CONTENT_CHILD_BLINK_PLATFORM_IMPL_H_ |
OLD | NEW |