started qt6 migration

This commit is contained in:
Johannes Lenzen
2021-04-26 10:03:03 +02:00
parent c6833ff28a
commit 6d344047fa
15 changed files with 90 additions and 42 deletions

View File

@@ -51,13 +51,20 @@
#include <QApplication>
#include <QMessageBox>
#include "SubdivideWidget.hh"
#if QT_VERSION_MAJOR > 5
#include <QOpenGLContext>
#endif
int main(int argc, char **argv)
{
// OpenGL check
QApplication app(argc,argv);
#if QT_VERSION_MAJOR < 6
if ( !QGLFormat::hasOpenGL() ) {
#else
if ( QOpenGLContext::openGLModuleType() != QOpenGLContext::LibGL ) {
#endif
QString msg = "System has no OpenGL support!";
QMessageBox::critical( nullptr, "OpenGL", msg + argv[1], QMessageBox::Ok );
return -1;