diff options
Diffstat (limited to 'examples/opengl/cube/main.cpp')
-rw-r--r-- | examples/opengl/cube/main.cpp | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/examples/opengl/cube/main.cpp b/examples/opengl/cube/main.cpp index fbc1d93e4a..fdae1caa16 100644 --- a/examples/opengl/cube/main.cpp +++ b/examples/opengl/cube/main.cpp @@ -47,16 +47,15 @@ int main(int argc, char *argv[]) { - QApplication a(argc, argv); - a.setApplicationName("cube"); - a.setApplicationVersion("0.1"); -#ifndef QT_NO_OPENGL - MainWidget w; - w.resize(640, 480); - w.show(); + QApplication app(argc, argv); + app.setApplicationName("cube"); + app.setApplicationVersion("0.1"); +#ifdef QT_NO_OPENGL + MainWidget widget; + widget.show(); #else - QLabel * notifyLabel = new QLabel("OpenGL Support required"); - notifyLabel->show(); + QLabel note("OpenGL Support required"); + note.show(); #endif - return a.exec(); + return app.exec(); } |