Added extra check to prevent calling frame() when the window has been closed.
This commit is contained in:
@@ -391,11 +391,14 @@ int main( int argc, char **argv )
|
|||||||
{
|
{
|
||||||
gw->checkEvents();
|
gw->checkEvents();
|
||||||
|
|
||||||
|
if (gw->isRealized() && !exitHandler->done())
|
||||||
|
{
|
||||||
viewer.frame();
|
viewer.frame();
|
||||||
|
|
||||||
// Swap Buffers
|
// Swap Buffers
|
||||||
gw->swapBuffers();
|
gw->swapBuffers();
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user