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 #include "sky/shell/ui/internals.h" | 5 #include "sky/shell/ui/internals.h" |
6 | 6 |
| 7 #include "base/threading/worker_pool.h" |
7 #include "mojo/public/cpp/application/connect.h" | 8 #include "mojo/public/cpp/application/connect.h" |
8 #include "mojo/public/cpp/bindings/array.h" | 9 #include "mojo/public/cpp/bindings/array.h" |
9 #include "services/asset_bundle/asset_unpacker_impl.h" | 10 #include "services/asset_bundle/asset_unpacker_impl.h" |
10 #include "sky/engine/tonic/dart_builtin.h" | 11 #include "sky/engine/tonic/dart_builtin.h" |
11 #include "sky/engine/tonic/dart_converter.h" | 12 #include "sky/engine/tonic/dart_converter.h" |
12 #include "sky/engine/tonic/dart_error.h" | 13 #include "sky/engine/tonic/dart_error.h" |
13 #include "sky/engine/tonic/dart_state.h" | 14 #include "sky/engine/tonic/dart_state.h" |
14 | 15 |
15 using namespace blink; | 16 using namespace blink; |
16 | 17 |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
100 platform_service_provider_.get()); | 101 platform_service_provider_.get()); |
101 service_provider_impl_.AddService<mojo::asset_bundle::AssetUnpacker>(this); | 102 service_provider_impl_.AddService<mojo::asset_bundle::AssetUnpacker>(this); |
102 } | 103 } |
103 | 104 |
104 Internals::~Internals() { | 105 Internals::~Internals() { |
105 } | 106 } |
106 | 107 |
107 void Internals::Create( | 108 void Internals::Create( |
108 mojo::ApplicationConnection* connection, | 109 mojo::ApplicationConnection* connection, |
109 mojo::InterfaceRequest<mojo::asset_bundle::AssetUnpacker> request) { | 110 mojo::InterfaceRequest<mojo::asset_bundle::AssetUnpacker> request) { |
110 new mojo::asset_bundle::AssetUnpackerImpl(request.Pass()); | 111 new mojo::asset_bundle::AssetUnpackerImpl( |
| 112 request.Pass(), base::WorkerPool::GetTaskRunner(true)); |
111 } | 113 } |
112 | 114 |
113 mojo::Handle Internals::TakeServicesProvidedByEmbedder() { | 115 mojo::Handle Internals::TakeServicesProvidedByEmbedder() { |
114 return service_provider_.PassInterface().PassHandle().release(); | 116 return service_provider_.PassInterface().PassHandle().release(); |
115 } | 117 } |
116 | 118 |
117 } // namespace shell | 119 } // namespace shell |
118 } // namespace sky | 120 } // namespace sky |
OLD | NEW |