From e4f9f9bd81b6dc2ca82f5b8913f3a49c616c1dda Mon Sep 17 00:00:00 2001 From: "backer@chromium.org" Date: Mon, 17 Oct 2011 13:22:01 +0000 Subject: Check for extensions in order to fail early. Currently, we're not checking for extensions on EGL path and we're only checking for XComposite extensions browser side. This change checks for extensions early and to fail at context creation (technically GLES2Decoder) creation time. BUG=none TEST=on hardware supporting the extensions Review URL: http://codereview.chromium.org/8293004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@105797 0039d316-1c4b-4281-b951-d872f2087c98 --- ui/gfx/gl/gl_context_cgl.cc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'ui/gfx/gl/gl_context_cgl.cc') diff --git a/ui/gfx/gl/gl_context_cgl.cc b/ui/gfx/gl/gl_context_cgl.cc index a759793..86933b64 100644 --- a/ui/gfx/gl/gl_context_cgl.cc +++ b/ui/gfx/gl/gl_context_cgl.cc @@ -101,7 +101,11 @@ bool GLContextCGL::MakeCurrent(GLSurface* surface) { } SetCurrent(this, surface); - surface->OnMakeCurrent(this); + if (!surface->OnMakeCurrent(this)) { + LOG(ERROR) << "Unable to make gl context current."; + return false; + } + return true; } -- cgit v1.1