| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 WEBKIT_PLATFORM_SUPPORT_IMPL_H_ | 5 #ifndef WEBKIT_PLATFORM_SUPPORT_IMPL_H_ |
| 6 #define WEBKIT_PLATFORM_SUPPORT_IMPL_H_ | 6 #define WEBKIT_PLATFORM_SUPPORT_IMPL_H_ |
| 7 | 7 |
| 8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
| 9 #include "base/debug/trace_event.h" | 9 #include "base/debug/trace_event.h" |
| 10 #include "base/platform_file.h" | 10 #include "base/platform_file.h" |
| 11 #include "base/threading/thread_local_storage.h" | 11 #include "base/threading/thread_local_storage.h" |
| 12 #include "base/timer.h" | 12 #include "base/timer.h" |
| 13 #include "third_party/WebKit/Source/Platform/chromium/public/Platform.h" | 13 #include "third_party/WebKit/Source/Platform/chromium/public/Platform.h" |
| 14 #include "ui/base/layout.h" | 14 #include "ui/base/layout.h" |
| 15 #include "webkit/glue/resource_loader_bridge.h" | 15 #include "webkit/glue/resource_loader_bridge.h" |
| 16 #include "webkit/glue/webkit_glue_export.h" | 16 #include "webkit/glue/webkit_glue_export.h" |
| 17 | 17 |
| 18 #if defined(USE_DEFAULT_RENDER_THEME) | 18 #if defined(USE_DEFAULT_RENDER_THEME) |
| 19 #include "webkit/glue/webthemeengine_impl_default.h" | 19 #include "webkit/glue/webthemeengine_impl_default.h" |
| 20 #elif defined(OS_WIN) | 20 #elif defined(OS_WIN) |
| 21 #include "webkit/glue/webthemeengine_impl_win.h" | 21 #include "webkit/glue/webthemeengine_impl_win.h" |
| 22 #elif defined(OS_MACOSX) | 22 #elif defined(OS_MACOSX) |
| 23 #include "webkit/glue/webthemeengine_impl_mac.h" | 23 #include "webkit/glue/webthemeengine_impl_mac.h" |
| 24 #elif defined(OS_ANDROID) | 24 #elif defined(OS_ANDROID) |
| 25 #include "webkit/glue/webthemeengine_impl_android.h" | 25 #include "webkit/glue/webthemeengine_impl_android.h" |
| 26 #endif | 26 #endif |
| 27 | 27 |
| 28 namespace base { |
| 28 class MessageLoop; | 29 class MessageLoop; |
| 30 } |
| 29 | 31 |
| 30 namespace webkit { | 32 namespace webkit { |
| 31 class WebCompositorSupportImpl; | 33 class WebCompositorSupportImpl; |
| 32 struct WebPluginInfo; | 34 struct WebPluginInfo; |
| 33 } | 35 } |
| 34 | 36 |
| 35 namespace WebKit { | 37 namespace WebKit { |
| 36 class WebSocketStreamHandle; | 38 class WebSocketStreamHandle; |
| 37 } | 39 } |
| 38 | 40 |
| (...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 170 return compositor_support_.get(); | 172 return compositor_support_.get(); |
| 171 } | 173 } |
| 172 | 174 |
| 173 private: | 175 private: |
| 174 void DoTimeout() { | 176 void DoTimeout() { |
| 175 if (shared_timer_func_ && !shared_timer_suspended_) | 177 if (shared_timer_func_ && !shared_timer_suspended_) |
| 176 shared_timer_func_(); | 178 shared_timer_func_(); |
| 177 } | 179 } |
| 178 static void DestroyCurrentThread(void*); | 180 static void DestroyCurrentThread(void*); |
| 179 | 181 |
| 180 MessageLoop* main_loop_; | 182 base::MessageLoop* main_loop_; |
| 181 base::OneShotTimer<WebKitPlatformSupportImpl> shared_timer_; | 183 base::OneShotTimer<WebKitPlatformSupportImpl> shared_timer_; |
| 182 void (*shared_timer_func_)(); | 184 void (*shared_timer_func_)(); |
| 183 double shared_timer_fire_time_; | 185 double shared_timer_fire_time_; |
| 184 bool shared_timer_fire_time_was_set_while_suspended_; | 186 bool shared_timer_fire_time_was_set_while_suspended_; |
| 185 int shared_timer_suspended_; // counter | 187 int shared_timer_suspended_; // counter |
| 186 WebThemeEngineImpl theme_engine_; | 188 WebThemeEngineImpl theme_engine_; |
| 187 base::ThreadLocalStorage::Slot current_thread_slot_; | 189 base::ThreadLocalStorage::Slot current_thread_slot_; |
| 188 scoped_ptr<webkit::WebCompositorSupportImpl> compositor_support_; | 190 scoped_ptr<webkit::WebCompositorSupportImpl> compositor_support_; |
| 189 scoped_ptr<FlingCurveConfiguration> fling_curve_configuration_; | 191 scoped_ptr<FlingCurveConfiguration> fling_curve_configuration_; |
| 190 }; | 192 }; |
| 191 | 193 |
| 192 } // namespace webkit_glue | 194 } // namespace webkit_glue |
| 193 | 195 |
| 194 #endif // WEBKIT_PLATFORM_SUPPORT_IMPL_H_ | 196 #endif // WEBKIT_PLATFORM_SUPPORT_IMPL_H_ |
| OLD | NEW |