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 #include "content/browser/gpu/gpu_process_host.h" | 5 #include "content/browser/gpu/gpu_process_host.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <algorithm> | 9 #include <algorithm> |
10 #include <list> | 10 #include <list> |
(...skipping 314 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
325 private: | 325 private: |
326 // ConnectionFilter: | 326 // ConnectionFilter: |
327 bool OnConnect(const service_manager::Identity& remote_identity, | 327 bool OnConnect(const service_manager::Identity& remote_identity, |
328 service_manager::InterfaceRegistry* registry, | 328 service_manager::InterfaceRegistry* registry, |
329 service_manager::Connector* connector) override { | 329 service_manager::Connector* connector) override { |
330 if (remote_identity.name() != mojom::kGpuServiceName) | 330 if (remote_identity.name() != mojom::kGpuServiceName) |
331 return false; | 331 return false; |
332 | 332 |
333 GetContentClient()->browser()->ExposeInterfacesToGpuProcess(registry, | 333 GetContentClient()->browser()->ExposeInterfacesToGpuProcess(registry, |
334 host_); | 334 host_); |
| 335 |
| 336 #if defined(OS_ANDROID) |
| 337 GpuProcessHostUIShim::RegisterUIThreadMojoInterfaces(registry); |
| 338 #endif |
| 339 |
335 return true; | 340 return true; |
336 } | 341 } |
337 | 342 |
338 GpuProcessHost* host_; | 343 GpuProcessHost* host_; |
339 | 344 |
340 DISALLOW_COPY_AND_ASSIGN(ConnectionFilterImpl); | 345 DISALLOW_COPY_AND_ASSIGN(ConnectionFilterImpl); |
341 }; | 346 }; |
342 | 347 |
343 // static | 348 // static |
344 bool GpuProcessHost::ValidateHost(GpuProcessHost* host) { | 349 bool GpuProcessHost::ValidateHost(GpuProcessHost* host) { |
(...skipping 840 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1185 GetShaderCacheFactorySingleton()->Get(client_id); | 1190 GetShaderCacheFactorySingleton()->Get(client_id); |
1186 if (!cache.get()) | 1191 if (!cache.get()) |
1187 return; | 1192 return; |
1188 | 1193 |
1189 cache->set_shader_loaded_callback(base::Bind(&HostLoadedShader, host_id_)); | 1194 cache->set_shader_loaded_callback(base::Bind(&HostLoadedShader, host_id_)); |
1190 | 1195 |
1191 client_id_to_shader_cache_[client_id] = cache; | 1196 client_id_to_shader_cache_[client_id] = cache; |
1192 } | 1197 } |
1193 | 1198 |
1194 } // namespace content | 1199 } // namespace content |
OLD | NEW |