From c1b974c611f963c8f46bdea0aada1b7f6565fc56 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Tue, 15 Jan 2013 16:20:09 +0100 Subject: Fix crash in hellowindow example when minimizing. Task-number: QTBUG-28439 Change-Id: Idcea2712afdbb08b4da2fa230fd8ba6aebd380b7 Reviewed-by: Joerg Bornemann --- examples/opengl/hellowindow/hellowindow.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'examples') diff --git a/examples/opengl/hellowindow/hellowindow.cpp b/examples/opengl/hellowindow/hellowindow.cpp index b1140c4f1d..998b29b540 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() -- cgit v1.2.3