| 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/common/gpu/gpu_channel_manager.h" | 5 #include "content/common/gpu/gpu_channel_manager.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "content/common/gpu/gpu_channel.h" | 9 #include "content/common/gpu/gpu_channel.h" |
| 10 #include "content/common/gpu/gpu_memory_manager.h" | 10 #include "content/common/gpu/gpu_memory_manager.h" |
| (...skipping 279 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 290 weak_factory_.GetWeakPtr())); | 290 weak_factory_.GetWeakPtr())); |
| 291 } | 291 } |
| 292 | 292 |
| 293 void GpuChannelManager::OnLoseAllContexts() { | 293 void GpuChannelManager::OnLoseAllContexts() { |
| 294 gpu_channels_.clear(); | 294 gpu_channels_.clear(); |
| 295 } | 295 } |
| 296 | 296 |
| 297 gfx::GLSurface* GpuChannelManager::GetDefaultOffscreenSurface() { | 297 gfx::GLSurface* GpuChannelManager::GetDefaultOffscreenSurface() { |
| 298 if (!default_offscreen_surface_.get()) { | 298 if (!default_offscreen_surface_.get()) { |
| 299 default_offscreen_surface_ = | 299 default_offscreen_surface_ = |
| 300 gfx::GLSurface::CreateOffscreenGLSurface(gfx::Size()); | 300 gfx::GLSurface::CreateOffscreenGLSurface(gfx::Size(1, 1)); |
| 301 } | 301 } |
| 302 return default_offscreen_surface_.get(); | 302 return default_offscreen_surface_.get(); |
| 303 } | 303 } |
| 304 | 304 |
| 305 } // namespace content | 305 } // namespace content |
| OLD | NEW |