Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(46)

Side by Side Diff: content/child/blink_platform_impl.h

Issue 2118903002: scheduler: Move the Blink scheduler into Blink (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Another GYP fix Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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
(...skipping 19 matching lines...) Expand all
30 #include "content/child/webthemeengine_impl_mac.h" 30 #include "content/child/webthemeengine_impl_mac.h"
31 #elif defined(OS_ANDROID) 31 #elif defined(OS_ANDROID)
32 #include "content/child/webthemeengine_impl_android.h" 32 #include "content/child/webthemeengine_impl_android.h"
33 #endif 33 #endif
34 34
35 namespace base { 35 namespace base {
36 class MessageLoop; 36 class MessageLoop;
37 class WaitableEvent; 37 class WaitableEvent;
38 } 38 }
39 39
40 namespace blink {
40 namespace scheduler { 41 namespace scheduler {
41 class WebThreadBase; 42 class WebThreadBase;
42 } 43 }
44 }
43 45
44 namespace content { 46 namespace content {
45 class BackgroundSyncProvider; 47 class BackgroundSyncProvider;
46 class FlingCurveConfiguration; 48 class FlingCurveConfiguration;
47 class NotificationDispatcher; 49 class NotificationDispatcher;
48 class PermissionDispatcher; 50 class PermissionDispatcher;
49 class PushDispatcher; 51 class PushDispatcher;
50 class ThreadSafeSender; 52 class ThreadSafeSender;
51 class TraceLogObserverAdapter; 53 class TraceLogObserverAdapter;
52 class WebCryptoImpl; 54 class WebCryptoImpl;
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 blink::WebSyncProvider* backgroundSyncProvider() override; 133 blink::WebSyncProvider* backgroundSyncProvider() override;
132 134
133 blink::WebString domCodeStringFromEnum(int dom_code) override; 135 blink::WebString domCodeStringFromEnum(int dom_code) override;
134 int domEnumFromCodeString(const blink::WebString& codeString) override; 136 int domEnumFromCodeString(const blink::WebString& codeString) override;
135 blink::WebString domKeyStringFromEnum(int dom_key) override; 137 blink::WebString domKeyStringFromEnum(int dom_key) override;
136 int domKeyEnumFromString(const blink::WebString& key_string) override; 138 int domKeyEnumFromString(const blink::WebString& key_string) override;
137 139
138 // This class does *not* own the compositor thread. It is the responsibility 140 // This class does *not* own the compositor thread. It is the responsibility
139 // of the caller to ensure that the compositor thread is cleared before it is 141 // of the caller to ensure that the compositor thread is cleared before it is
140 // destructed. 142 // destructed.
141 void SetCompositorThread(scheduler::WebThreadBase* compositor_thread); 143 void SetCompositorThread(blink::scheduler::WebThreadBase* compositor_thread);
142 144
143 private: 145 private:
144 void InternalInit(); 146 void InternalInit();
145 void WaitUntilWebThreadTLSUpdate(scheduler::WebThreadBase* thread); 147 void WaitUntilWebThreadTLSUpdate(blink::scheduler::WebThreadBase* thread);
146 void UpdateWebThreadTLS(blink::WebThread* thread, base::WaitableEvent* event); 148 void UpdateWebThreadTLS(blink::WebThread* thread, base::WaitableEvent* event);
147 149
148 bool IsMainThread() const; 150 bool IsMainThread() const;
149 151
150 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner_; 152 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner_;
151 WebThemeEngineImpl native_theme_engine_; 153 WebThemeEngineImpl native_theme_engine_;
152 WebFallbackThemeEngineImpl fallback_theme_engine_; 154 WebFallbackThemeEngineImpl fallback_theme_engine_;
153 base::ThreadLocalStorage::Slot current_thread_slot_; 155 base::ThreadLocalStorage::Slot current_thread_slot_;
154 webcrypto::WebCryptoImpl web_crypto_; 156 webcrypto::WebCryptoImpl web_crypto_;
155 base::ScopedPtrHashMap<blink::Platform::TraceLogEnabledStateObserver*, 157 base::ScopedPtrHashMap<blink::Platform::TraceLogEnabledStateObserver*,
156 std::unique_ptr<TraceLogObserverAdapter>> 158 std::unique_ptr<TraceLogObserverAdapter>>
157 trace_log_observers_; 159 trace_log_observers_;
158 160
159 scoped_refptr<ThreadSafeSender> thread_safe_sender_; 161 scoped_refptr<ThreadSafeSender> thread_safe_sender_;
160 scoped_refptr<NotificationDispatcher> notification_dispatcher_; 162 scoped_refptr<NotificationDispatcher> notification_dispatcher_;
161 scoped_refptr<PushDispatcher> push_dispatcher_; 163 scoped_refptr<PushDispatcher> push_dispatcher_;
162 std::unique_ptr<PermissionDispatcher> permission_client_; 164 std::unique_ptr<PermissionDispatcher> permission_client_;
163 std::unique_ptr<BackgroundSyncProvider> main_thread_sync_provider_; 165 std::unique_ptr<BackgroundSyncProvider> main_thread_sync_provider_;
164 166
165 scheduler::WebThreadBase* compositor_thread_; 167 blink::scheduler::WebThreadBase* compositor_thread_;
166 }; 168 };
167 169
168 } // namespace content 170 } // namespace content
169 171
170 #endif // CONTENT_CHILD_BLINK_PLATFORM_IMPL_H_ 172 #endif // CONTENT_CHILD_BLINK_PLATFORM_IMPL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698