| 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 #ifndef UI_GL_GL_SURFACE_GLX_H_ | 5 #ifndef UI_GL_GL_SURFACE_GLX_H_ |
| 6 #define UI_GL_GL_SURFACE_GLX_H_ | 6 #define UI_GL_GL_SURFACE_GLX_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 52 | 52 |
| 53 // A surface used to render to a view. | 53 // A surface used to render to a view. |
| 54 class GL_EXPORT NativeViewGLSurfaceGLX : public GLSurfaceGLX, | 54 class GL_EXPORT NativeViewGLSurfaceGLX : public GLSurfaceGLX, |
| 55 public ui::PlatformEventDispatcher { | 55 public ui::PlatformEventDispatcher { |
| 56 public: | 56 public: |
| 57 explicit NativeViewGLSurfaceGLX(gfx::AcceleratedWidget window); | 57 explicit NativeViewGLSurfaceGLX(gfx::AcceleratedWidget window); |
| 58 | 58 |
| 59 // Implement GLSurfaceGLX. | 59 // Implement GLSurfaceGLX. |
| 60 bool Initialize() override; | 60 bool Initialize() override; |
| 61 void Destroy() override; | 61 void Destroy() override; |
| 62 bool Resize(const gfx::Size& size) override; | 62 bool Resize(const gfx::Size& size, float scale_factor) override; |
| 63 bool IsOffscreen() override; | 63 bool IsOffscreen() override; |
| 64 gfx::SwapResult SwapBuffers() override; | 64 gfx::SwapResult SwapBuffers() override; |
| 65 gfx::Size GetSize() override; | 65 gfx::Size GetSize() override; |
| 66 void* GetHandle() override; | 66 void* GetHandle() override; |
| 67 bool SupportsPostSubBuffer() override; | 67 bool SupportsPostSubBuffer() override; |
| 68 void* GetConfig() override; | 68 void* GetConfig() override; |
| 69 gfx::SwapResult PostSubBuffer(int x, int y, int width, int height) override; | 69 gfx::SwapResult PostSubBuffer(int x, int y, int width, int height) override; |
| 70 VSyncProvider* GetVSyncProvider() override; | 70 VSyncProvider* GetVSyncProvider() override; |
| 71 | 71 |
| 72 protected: | 72 protected: |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 116 void* config_; | 116 void* config_; |
| 117 // Unmapped dummy window, used to provide a compatible surface. | 117 // Unmapped dummy window, used to provide a compatible surface. |
| 118 gfx::AcceleratedWidget window_; | 118 gfx::AcceleratedWidget window_; |
| 119 | 119 |
| 120 DISALLOW_COPY_AND_ASSIGN(UnmappedNativeViewGLSurfaceGLX); | 120 DISALLOW_COPY_AND_ASSIGN(UnmappedNativeViewGLSurfaceGLX); |
| 121 }; | 121 }; |
| 122 | 122 |
| 123 } // namespace gfx | 123 } // namespace gfx |
| 124 | 124 |
| 125 #endif // UI_GL_GL_SURFACE_GLX_H_ | 125 #endif // UI_GL_GL_SURFACE_GLX_H_ |
| OLD | NEW |