diff options
author | Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> | 2015-11-05 14:32:25 +0000 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2015-11-05 14:32:25 +0000 |
commit | 09018b99dce7a8ed43b0842055e8775d5021cf04 (patch) | |
tree | 8ab6f1b450eb63f981f9275c0f973695d5a3f7b7 /src/core | |
parent | a5e14c7abf8fddfbcbc3223e093f8acb50c459d5 (diff) | |
parent | 14430b465d39a602d917f2a701218ed56360dc4e (diff) |
Merge "Merge branch '5.5' into 5.6" into refs/staging/5.6
Diffstat (limited to 'src/core')
-rw-r--r-- | src/core/gl_context_qt.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/core/gl_context_qt.cpp b/src/core/gl_context_qt.cpp index b350c3c5b..3c3b8225d 100644 --- a/src/core/gl_context_qt.cpp +++ b/src/core/gl_context_qt.cpp @@ -146,10 +146,14 @@ scoped_refptr<GLContext> GLContext::CreateGLContext(GLShareGroup* share_group, G { #if defined(OS_WIN) scoped_refptr<GLContext> context; - if (GetGLImplementation() == kGLImplementationDesktopGL) + if (GetGLImplementation() == kGLImplementationDesktopGL) { context = new GLContextWGL(share_group); - else + if (!context->Initialize(compatible_surface, gpu_preference)) + return nullptr; + return context; + } else { context = new GLContextEGL(share_group); + } #else scoped_refptr<GLContext> context = new GLContextEGL(share_group); #endif |