| OLD | NEW |
| (Empty) | |
| 1 // Copyright (c) 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef UI_GL_GL_SURFACE_EGL_X11_H_ |
| 6 #define UI_GL_GL_SURFACE_EGL_X11_H_ |
| 7 |
| 8 #include <string> |
| 9 |
| 10 #include "base/macros.h" |
| 11 #include "ui/events/platform/platform_event_dispatcher.h" |
| 12 #include "ui/gl/gl_surface_egl.h" |
| 13 |
| 14 namespace gfx { |
| 15 |
| 16 // Encapsulates an EGL surface bound to a view using the X Window System. |
| 17 class GL_EXPORT NativeViewGLSurfaceEGLX11 : public NativeViewGLSurfaceEGL, |
| 18 public ui::PlatformEventDispatcher { |
| 19 public: |
| 20 explicit NativeViewGLSurfaceEGLX11(EGLNativeWindowType window); |
| 21 |
| 22 // NativeViewGLSurfaceEGL overrides. |
| 23 EGLConfig GetConfig() override; |
| 24 void Destroy() override; |
| 25 bool Resize(const gfx::Size& size, float scale_factor) override; |
| 26 bool InitializeNativeWindow() override; |
| 27 |
| 28 private: |
| 29 ~NativeViewGLSurfaceEGLX11() override; |
| 30 |
| 31 EGLNativeWindowType parent_window_; |
| 32 |
| 33 // PlatformEventDispatcher implementation. |
| 34 bool CanDispatchEvent(const ui::PlatformEvent& event) override; |
| 35 uint32_t DispatchEvent(const ui::PlatformEvent& event) override; |
| 36 |
| 37 DISALLOW_COPY_AND_ASSIGN(NativeViewGLSurfaceEGLX11); |
| 38 }; |
| 39 |
| 40 } // namespace gfx |
| 41 |
| 42 #endif // UI_GL_GL_SURFACE_EGL_X11_H_ |
| OLD | NEW |