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 #ifndef SKY_SHELL_UI_PLATFORM_IMPL_H_ | 5 #ifndef SKY_SHELL_UI_PLATFORM_IMPL_H_ |
6 #define SKY_SHELL_UI_PLATFORM_IMPL_H_ | 6 #define SKY_SHELL_UI_PLATFORM_IMPL_H_ |
7 | 7 |
8 #include "base/message_loop/message_loop.h" | 8 #include "base/message_loop/message_loop.h" |
| 9 #include "mojo/public/interfaces/application/service_provider.mojom.h" |
| 10 #include "mojo/services/network/public/interfaces/network_service.mojom.h" |
9 #include "sky/engine/public/platform/Platform.h" | 11 #include "sky/engine/public/platform/Platform.h" |
10 | 12 |
11 namespace sky { | 13 namespace sky { |
12 namespace shell { | 14 namespace shell { |
13 | 15 |
14 class PlatformImpl : public blink::Platform { | 16 class PlatformImpl : public blink::Platform { |
15 public: | 17 public: |
16 PlatformImpl(); | 18 explicit PlatformImpl(mojo::ServiceProviderPtr service_provider); |
17 ~PlatformImpl() override; | 19 ~PlatformImpl() override; |
18 | 20 |
19 // blink::Platform: | 21 // blink::Platform: |
20 blink::WebString defaultLocale() override; | 22 blink::WebString defaultLocale() override; |
21 base::SingleThreadTaskRunner* mainThreadTaskRunner() override; | 23 base::SingleThreadTaskRunner* mainThreadTaskRunner() override; |
| 24 mojo::NetworkService* networkService() override; |
22 | 25 |
23 private: | 26 private: |
24 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner_; | 27 scoped_refptr<base::SingleThreadTaskRunner> main_thread_task_runner_; |
| 28 mojo::ServiceProviderPtr service_provider_; |
| 29 mojo::NetworkServicePtr network_service_; |
25 | 30 |
26 DISALLOW_COPY_AND_ASSIGN(PlatformImpl); | 31 DISALLOW_COPY_AND_ASSIGN(PlatformImpl); |
27 }; | 32 }; |
28 | 33 |
29 } // namespace shell | 34 } // namespace shell |
30 } // namespace sky | 35 } // namespace sky |
31 | 36 |
32 #endif // SKY_SHELL_UI_PLATFORM_IMPL_H_ | 37 #endif // SKY_SHELL_UI_PLATFORM_IMPL_H_ |
OLD | NEW |