diff options
author | Alexandru Croitor <alexandru.croitor@qt.io> | 2019-10-14 17:46:16 +0200 |
---|---|---|
committer | Alexandru Croitor <alexandru.croitor@qt.io> | 2019-10-14 17:46:34 +0200 |
commit | 440286655e0ca271506cf7cc02ad0dbf4baef9ca (patch) | |
tree | 896fa81adb8b14a69355a3a6cf64d06ec8173c9a /examples/widgets/graphicsview/boxes/main.cpp | |
parent | 1e27ad1697187549151657ba187928e439300db7 (diff) | |
parent | e164d61ca8263fc4b46fdd916e1ea77c7dd2b735 (diff) |
Merge remote-tracking branch 'origin/dev' into wip/cmake
Change-Id: I4a78428a8ea273b6960792e3b8043f816fa37fcf
Diffstat (limited to 'examples/widgets/graphicsview/boxes/main.cpp')
-rw-r--r-- | examples/widgets/graphicsview/boxes/main.cpp | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/examples/widgets/graphicsview/boxes/main.cpp b/examples/widgets/graphicsview/boxes/main.cpp index b7242d529b..2b3e6d3389 100644 --- a/examples/widgets/graphicsview/boxes/main.cpp +++ b/examples/widgets/graphicsview/boxes/main.cpp @@ -48,13 +48,11 @@ ** ****************************************************************************/ -//#include <GL/glew.h> #include "glextensions.h" - #include "scene.h" -#include <QtWidgets> #include <QGLWidget> +#include <QtWidgets> class GraphicsView : public QGraphicsView { @@ -114,7 +112,7 @@ int main(int argc, char **argv) QApplication app(argc, argv); if ((QGLFormat::openGLVersionFlags() & QGLFormat::OpenGL_Version_1_5) == 0) { - QMessageBox::critical(0, "OpenGL features missing", + QMessageBox::critical(nullptr, "OpenGL features missing", "OpenGL version 1.5 or higher is required to run this demo.\n" "The program will now exit."); return -1; @@ -125,7 +123,7 @@ int main(int argc, char **argv) widget->makeCurrent(); if (!necessaryExtensionsSupported()) { - QMessageBox::critical(0, "OpenGL features missing", + QMessageBox::critical(nullptr, "OpenGL features missing", "The OpenGL extensions required to run this demo are missing.\n" "The program will now exit."); delete widget; @@ -134,7 +132,7 @@ int main(int argc, char **argv) // Check if all the necessary functions are resolved. if (!getGLExtensionFunctions().resolve(widget->context())) { - QMessageBox::critical(0, "OpenGL features missing", + QMessageBox::critical(nullptr, "OpenGL features missing", "Failed to resolve OpenGL functions required to run this demo.\n" "The program will now exit."); delete widget; @@ -142,7 +140,7 @@ int main(int argc, char **argv) } // TODO: Make conditional for final release - QMessageBox::information(0, "For your information", + QMessageBox::information(nullptr, "For your information", "This demo can be GPU and CPU intensive and may\n" "work poorly or not at all on your system."); |