OSDN Git Service

[Qt][OpenGL] Don't makeCurrent()/doneCurrent() inside of resizeGL().Fixed crash runni...
[csp-qt/common_source_project-fm7.git] / source / src / qt / gui / gl2 / qt_glutil_gl2_0.cpp
index 3b3dd8e..c5a7dde 100644 (file)
@@ -1017,7 +1017,6 @@ void GLDraw_2_0::resizeGL_SetVertexs(void)
 void GLDraw_2_0::resizeGL(int width, int height)
 {
        //int side = qMin(width, height);
-       p_wid->makeCurrent();
        extfunc_2->glViewport(0, 0, width, height);
        extfunc_2->glOrtho(-1.0f, 1.0f, -1.0f, 1.0f, -1.0, 1.0);
        crt_flag = true;
@@ -1042,7 +1041,6 @@ void GLDraw_2_0::resizeGL(int width, int height)
        if(using_flags->get_max_button() > 0) {
                updateButtonTexture();
        }
-       p_wid->doneCurrent();
 }
 
 void GLDraw_2_0::paintGL(void)