fix bug in WX_GL_DOUBLEBUFFER handling introduced during the last great refactoring
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@46969 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -161,9 +161,6 @@ wxGLCanvasX11::ConvertWXAttrsToGL(const int *wxattrs, int *glattrs, size_t n)
|
|||||||
if ( p >= n - 2 )
|
if ( p >= n - 2 )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
// notice that for boolean attributes we use "continue" in the
|
|
||||||
// switch to skip the assignment of the attribute value at the end
|
|
||||||
// of the loop which is done for integer attributes
|
|
||||||
switch ( wxattrs[arg++] )
|
switch ( wxattrs[arg++] )
|
||||||
{
|
{
|
||||||
case WX_GL_RGBA:
|
case WX_GL_RGBA:
|
||||||
@@ -175,6 +172,9 @@ wxGLCanvasX11::ConvertWXAttrsToGL(const int *wxattrs, int *glattrs, size_t n)
|
|||||||
{
|
{
|
||||||
glattrs[p++] = GLX_RGBA;
|
glattrs[p++] = GLX_RGBA;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// use "continue" to skip the assignment of the attribute
|
||||||
|
// value at the end of the loop
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
case WX_GL_BUFFER_SIZE:
|
case WX_GL_BUFFER_SIZE:
|
||||||
@@ -187,6 +187,10 @@ wxGLCanvasX11::ConvertWXAttrsToGL(const int *wxattrs, int *glattrs, size_t n)
|
|||||||
|
|
||||||
case WX_GL_DOUBLEBUFFER:
|
case WX_GL_DOUBLEBUFFER:
|
||||||
glattrs[p++] = GLX_DOUBLEBUFFER;
|
glattrs[p++] = GLX_DOUBLEBUFFER;
|
||||||
|
glattrs[p++] = True;
|
||||||
|
|
||||||
|
// again, we don't have value for this one in wx list (even
|
||||||
|
// though OpenGL does use it)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
case WX_GL_STEREO:
|
case WX_GL_STEREO:
|
||||||
|
Reference in New Issue
Block a user