| 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 "ui/gl/gl_surface.h" | 5 #include "ui/gl/gl_surface.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/lazy_instance.h" | 10 #include "base/lazy_instance.h" |
| (...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 216 } | 216 } |
| 217 | 217 |
| 218 bool GLSurface::IsSurfaceless() const { | 218 bool GLSurface::IsSurfaceless() const { |
| 219 return false; | 219 return false; |
| 220 } | 220 } |
| 221 | 221 |
| 222 bool GLSurface::FlipsVertically() const { | 222 bool GLSurface::FlipsVertically() const { |
| 223 return false; | 223 return false; |
| 224 } | 224 } |
| 225 | 225 |
| 226 bool GLSurface::BuffersFlipped() const { |
| 227 return false; |
| 228 } |
| 229 |
| 226 GLSurface* GLSurface::GetCurrent() { | 230 GLSurface* GLSurface::GetCurrent() { |
| 227 return current_surface_.Pointer()->Get(); | 231 return current_surface_.Pointer()->Get(); |
| 228 } | 232 } |
| 229 | 233 |
| 230 GLSurface::~GLSurface() { | 234 GLSurface::~GLSurface() { |
| 231 if (GetCurrent() == this) | 235 if (GetCurrent() == this) |
| 232 SetCurrent(NULL); | 236 SetCurrent(NULL); |
| 233 } | 237 } |
| 234 | 238 |
| 235 void GLSurface::SetCurrent(GLSurface* surface) { | 239 void GLSurface::SetCurrent(GLSurface* surface) { |
| (...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 380 } | 384 } |
| 381 | 385 |
| 382 bool GLSurfaceAdapter::IsSurfaceless() const { | 386 bool GLSurfaceAdapter::IsSurfaceless() const { |
| 383 return surface_->IsSurfaceless(); | 387 return surface_->IsSurfaceless(); |
| 384 } | 388 } |
| 385 | 389 |
| 386 bool GLSurfaceAdapter::FlipsVertically() const { | 390 bool GLSurfaceAdapter::FlipsVertically() const { |
| 387 return surface_->FlipsVertically(); | 391 return surface_->FlipsVertically(); |
| 388 } | 392 } |
| 389 | 393 |
| 394 bool GLSurfaceAdapter::BuffersFlipped() const { |
| 395 return surface_->BuffersFlipped(); |
| 396 } |
| 397 |
| 390 GLSurfaceAdapter::~GLSurfaceAdapter() {} | 398 GLSurfaceAdapter::~GLSurfaceAdapter() {} |
| 391 | 399 |
| 392 } // namespace gfx | 400 } // namespace gfx |
| OLD | NEW |