| Index: content/browser/gpu/gpu_process_host_ui_shim.cc
|
| diff --git a/content/browser/gpu/gpu_process_host_ui_shim.cc b/content/browser/gpu/gpu_process_host_ui_shim.cc
|
| index a7c5b20bd8d8c2127622a58d2b07a9f2393802ce..605ecb9aea23993b3a5705445bef4f4c74f8a367 100644
|
| --- a/content/browser/gpu/gpu_process_host_ui_shim.cc
|
| +++ b/content/browser/gpu/gpu_process_host_ui_shim.cc
|
| @@ -63,6 +63,18 @@ void StopGpuProcessOnIO(int host_id) {
|
| host->StopGpuProcess();
|
| }
|
|
|
| +#if defined(OS_ANDROID)
|
| +void DestroyingVideoSurfaceOnIO(int host_id,
|
| + int32_t surface_id,
|
| + const base::Closure& done_cb) {
|
| + GpuProcessHost* host = GpuProcessHost::FromID(host_id);
|
| + if (host)
|
| + host->DestroyingVideoSurface(surface_id, done_cb);
|
| + else
|
| + done_cb.Run();
|
| +}
|
| +#endif
|
| +
|
| } // namespace
|
|
|
| void RouteToGpuProcessHostUIShimTask(int host_id, const IPC::Message& msg) {
|
| @@ -140,6 +152,19 @@ bool GpuProcessHostUIShim::Send(IPC::Message* msg) {
|
| msg));
|
| }
|
|
|
| +#if defined(OS_ANDROID)
|
| +void GpuProcessHostUIShim::DestroyingVideoSurface(
|
| + int surface_id,
|
| + const base::Closure& done_cb) {
|
| + DCHECK(CalledOnValidThread());
|
| + if (!BrowserThread::PostTask(BrowserThread::IO, FROM_HERE,
|
| + base::Bind(&DestroyingVideoSurfaceOnIO, host_id_,
|
| + surface_id, done_cb))) {
|
| + done_cb.Run();
|
| + }
|
| +}
|
| +#endif
|
| +
|
| bool GpuProcessHostUIShim::OnMessageReceived(const IPC::Message& message) {
|
| DCHECK(CalledOnValidThread());
|
|
|
|
|