diff options
author | Florent Revest <revestflo@gmail.com> | 2015-12-20 17:50:25 +0100 |
---|---|---|
committer | Florent Revest <revestflo@gmail.com> | 2015-12-20 23:49:55 +0100 |
commit | cdcf5e8496b51091f9d71a6a52a588a97686c49d (patch) | |
tree | 85cca7aaaa2091798739bb55335edf058f5be4b4 /src | |
parent | b3f803532a7c346d03ab72d7a1e0750e69659d21 (diff) |
Removes the colorful settings and sanitize a little bit the code
Diffstat (limited to 'src')
-rwxr-xr-x | src/main.cpp | 46 | ||||
-rwxr-xr-x | src/src.pri | 2 |
2 files changed, 0 insertions, 48 deletions
diff --git a/src/main.cpp b/src/main.cpp deleted file mode 100755 index ec8f2de..0000000 --- a/src/main.cpp +++ /dev/null @@ -1,46 +0,0 @@ -// Copyright © 2015 Florent Revest <revestflo@gmail.com> -// This work is free. You can redistribute it and/or modify it under the -// terms of the Do What The Fuck You Want To Public License, Version 2, -// as published by Sam Hocevar. See http://www.wtfpl.net/ for more details. - -#include <QtQml> -#include <QtQuick/QQuickView> -#include <QtCore/QString> -#include <QScreen> - -#ifndef QT_NO_WIDGETS -#include <QtWidgets/QApplication> -#else -#include <QtGui/QGuiApplication> -#endif - -QT_BEGIN_NAMESPACE - -#ifndef QT_NO_WIDGETS -#define Application QApplication -#else -#define Application QGuiApplication -#endif - -int main(int argc, char *argv[]) -{ - Application app(argc, argv); - QScreen* sc = app.primaryScreen(); - if(sc){ - sc->setOrientationUpdateMask(Qt::LandscapeOrientation - | Qt::PortraitOrientation - | Qt::InvertedLandscapeOrientation - | Qt::InvertedPortraitOrientation); - } - QQmlApplicationEngine engine(QUrl("qrc:/main.qml")); - QObject *topLevel = engine.rootObjects().value(0); - QQuickWindow *window = qobject_cast<QQuickWindow *>(topLevel); - if ( !window ) { - qWarning("Error: Your root item has to be a Window."); - return -1; - } - window->showFullScreen(); - return app.exec(); -} - -QT_END_NAMESPACE diff --git a/src/src.pri b/src/src.pri deleted file mode 100755 index 66d903e..0000000 --- a/src/src.pri +++ /dev/null @@ -1,2 +0,0 @@ -SOURCES += \ - $$PWD/main.cpp |