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 315 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
326 bool GLSurfaceAdapter::FlipsVertically() const { | 326 bool GLSurfaceAdapter::FlipsVertically() const { |
327 return surface_->FlipsVertically(); | 327 return surface_->FlipsVertically(); |
328 } | 328 } |
329 | 329 |
330 bool GLSurfaceAdapter::BuffersFlipped() const { | 330 bool GLSurfaceAdapter::BuffersFlipped() const { |
331 return surface_->BuffersFlipped(); | 331 return surface_->BuffersFlipped(); |
332 } | 332 } |
333 | 333 |
334 GLSurfaceAdapter::~GLSurfaceAdapter() {} | 334 GLSurfaceAdapter::~GLSurfaceAdapter() {} |
335 | 335 |
| 336 scoped_refptr<GLSurface> InitializeGLSurface(scoped_refptr<GLSurface> surface) { |
| 337 if (!surface->Initialize()) |
| 338 return nullptr; |
| 339 return surface; |
| 340 } |
| 341 |
336 } // namespace gl | 342 } // namespace gl |
OLD | NEW |