| Index: content/common/gpu/gpu_channel_manager.cc
|
| diff --git a/content/common/gpu/gpu_channel_manager.cc b/content/common/gpu/gpu_channel_manager.cc
|
| index be60a19413468e7bca9090760b360de78b511651..1da6aecf2f3c82608fc57654592fc22c5d557c85 100644
|
| --- a/content/common/gpu/gpu_channel_manager.cc
|
| +++ b/content/common/gpu/gpu_channel_manager.cc
|
| @@ -38,6 +38,10 @@ GpuChannelManager::GpuChannelManager(ChildThread* gpu_child_thread,
|
|
|
| GpuChannelManager::~GpuChannelManager() {
|
| gpu_channels_.clear();
|
| + if (default_offscreen_surface_.get()) {
|
| + default_offscreen_surface_->Destroy();
|
| + default_offscreen_surface_ = NULL;
|
| + }
|
| }
|
|
|
| gpu::gles2::ProgramCache* GpuChannelManager::program_cache() {
|
| @@ -175,3 +179,11 @@ void GpuChannelManager::LoseAllContexts() {
|
| void GpuChannelManager::OnLoseAllContexts() {
|
| gpu_channels_.clear();
|
| }
|
| +
|
| +gfx::GLSurface* GpuChannelManager::GetDefaultOffscreenSurface() {
|
| + if (!default_offscreen_surface_.get()) {
|
| + default_offscreen_surface_ = gfx::GLSurface::CreateOffscreenGLSurface(
|
| + false, gfx::Size(1, 1));
|
| + }
|
| + return default_offscreen_surface_.get();
|
| +}
|
|
|