diff --git a/examples/opengl/hellowindow/hellowindow.cpp b/examples/opengl/hellowindow/hellowindow.cpp index b1140c4f1dd..998b29b5409 100644 --- a/examples/opengl/hellowindow/hellowindow.cpp +++ b/examples/opengl/hellowindow/hellowindow.cpp @@ -92,7 +92,8 @@ void HelloWindow::mousePressEvent(QMouseEvent *) void HelloWindow::render() { - emit needRender(this, m_color, size()); + if (isExposed()) + emit needRender(this, m_color, size()); } void HelloWindow::updateColor()