Skip to content

Commit

Permalink
fixed compiler and runtime error on recent versions of Qt
Browse files Browse the repository at this point in the history
  • Loading branch information
nebomuk committed Apr 1, 2020
1 parent 61670a6 commit b5ff4dc
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 2 additions & 0 deletions src/globalvariables.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
#ifndef __GLOBALVARIABLES_H__
#define __GLOBALVARIABLES_H__

#include <QImage>
#include <QList>
#include <QPixmap>


// all variables here must be const else linker errors will occur
Expand Down
8 changes: 5 additions & 3 deletions src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,15 @@

int main(int argc, char ** argv)
{
QApplication app( argc, argv );

// crashes when trying to use ANGLE and opengl driver might not be available
#ifdef Q_OS_WIN
QCoreApplication::setAttribute(Qt::AA_UseSoftwareOpenGL);
QCoreApplication::setAttribute(Qt::AA_UseSoftwareOpenGL);
#endif

QApplication app( argc, argv );



app.setQuitOnLastWindowClosed(false);

app.setApplicationName("TAsteroids");
Expand Down

0 comments on commit b5ff4dc

Please sign in to comment.