| Index: ui/gl/gl_surface_egl.cc
|
| diff --git a/ui/gl/gl_surface_egl.cc b/ui/gl/gl_surface_egl.cc
|
| index a1214cf488bc17e7d1877e5a5d74e06b35615244..c1d8af1bf052169a424b5ab20b53a95120eeacd1 100644
|
| --- a/ui/gl/gl_surface_egl.cc
|
| +++ b/ui/gl/gl_surface_egl.cc
|
| @@ -26,12 +26,17 @@ extern "C" {
|
| namespace gfx {
|
|
|
| namespace {
|
| +
|
| EGLConfig g_config;
|
| EGLDisplay g_display;
|
| EGLNativeDisplayType g_native_display;
|
| EGLConfig g_software_config;
|
| EGLDisplay g_software_display;
|
| EGLNativeDisplayType g_software_native_display;
|
| +
|
| +const char* g_egl_extensions = NULL;
|
| +bool g_egl_create_context_robustness_supported = false;
|
| +
|
| }
|
|
|
| GLSurfaceEGL::GLSurfaceEGL() : software_(false) {}
|
| @@ -96,6 +101,10 @@ bool GLSurfaceEGL::InitializeOneOff() {
|
| return false;
|
| }
|
|
|
| + g_egl_extensions = eglQueryString(g_display, EGL_EXTENSIONS);
|
| + g_egl_create_context_robustness_supported =
|
| + HasEGLExtension("EGL_EXT_create_context_robustness");
|
| +
|
| initialized = true;
|
|
|
| #if defined(USE_X11) || defined(OS_ANDROID)
|
| @@ -154,6 +163,18 @@ EGLNativeDisplayType GLSurfaceEGL::GetNativeDisplay() {
|
| return g_native_display;
|
| }
|
|
|
| +const char* GLSurfaceEGL::GetEGLExtensions() {
|
| + return g_egl_extensions;
|
| +}
|
| +
|
| +bool GLSurfaceEGL::HasEGLExtension(const char* name) {
|
| + return ExtensionsContain(GetEGLExtensions(), name);
|
| +}
|
| +
|
| +bool GLSurfaceEGL::IsCreateContextRobustnessSupported() {
|
| + return g_egl_create_context_robustness_supported;
|
| +}
|
| +
|
| GLSurfaceEGL::~GLSurfaceEGL() {}
|
|
|
| NativeViewGLSurfaceEGL::NativeViewGLSurfaceEGL(bool software,
|
|
|