| 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 SKY_VIEWER_PLATFORM_PLATFORM_IMPL_H_ | 5 #ifndef SKY_VIEWER_PLATFORM_PLATFORM_IMPL_H_ |
| 6 #define SKY_VIEWER_PLATFORM_PLATFORM_IMPL_H_ | 6 #define SKY_VIEWER_PLATFORM_PLATFORM_IMPL_H_ |
| 7 | 7 |
| 8 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
| 10 #include "base/threading/thread_local_storage.h" | 10 #include "base/threading/thread_local_storage.h" |
| 11 #include "base/timer/timer.h" | 11 #include "base/timer/timer.h" |
| 12 #include "mojo/services/public/interfaces/network/network_service.mojom.h" | 12 #include "mojo/services/public/interfaces/network/network_service.mojom.h" |
| 13 #include "sky/engine/public/platform/Platform.h" | 13 #include "sky/engine/public/platform/Platform.h" |
| 14 #include "sky/viewer/cc/web_compositor_support_impl.h" | |
| 15 | 14 |
| 16 namespace mojo { | 15 namespace mojo { |
| 17 class ApplicationImpl; | 16 class ApplicationImpl; |
| 18 } | 17 } |
| 19 | 18 |
| 20 namespace sky { | 19 namespace sky { |
| 21 | 20 |
| 22 class PlatformImpl : public blink::Platform { | 21 class PlatformImpl : public blink::Platform { |
| 23 public: | 22 public: |
| 24 explicit PlatformImpl(mojo::ApplicationImpl* app); | 23 explicit PlatformImpl(mojo::ApplicationImpl* app); |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 78 } | 77 } |
| 79 | 78 |
| 80 mojo::NetworkServicePtr network_service_; | 79 mojo::NetworkServicePtr network_service_; |
| 81 base::MessageLoop* main_loop_; | 80 base::MessageLoop* main_loop_; |
| 82 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner_; | 81 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner_; |
| 83 base::OneShotTimer<PlatformImpl> shared_timer_; | 82 base::OneShotTimer<PlatformImpl> shared_timer_; |
| 84 void (*shared_timer_func_)(); | 83 void (*shared_timer_func_)(); |
| 85 double shared_timer_fire_time_; | 84 double shared_timer_fire_time_; |
| 86 bool shared_timer_fire_time_was_set_while_suspended_; | 85 bool shared_timer_fire_time_was_set_while_suspended_; |
| 87 int shared_timer_suspended_; // counter | 86 int shared_timer_suspended_; // counter |
| 88 sky_viewer_cc::WebCompositorSupportImpl compositor_support_; | |
| 89 | 87 |
| 90 DISALLOW_COPY_AND_ASSIGN(PlatformImpl); | 88 DISALLOW_COPY_AND_ASSIGN(PlatformImpl); |
| 91 }; | 89 }; |
| 92 | 90 |
| 93 } // namespace sky | 91 } // namespace sky |
| 94 | 92 |
| 95 #endif // SKY_VIEWER_PLATFORM_PLATFORM_IMPL_H_ | 93 #endif // SKY_VIEWER_PLATFORM_PLATFORM_IMPL_H_ |
| OLD | NEW |