2020-02-24 20:59:45 +01:00
|
|
|
/* This file is part of FediPotato.
|
|
|
|
* Copyright © 2020 tastytea <tastytea@tastytea.de>
|
|
|
|
*
|
|
|
|
* This program is free software: you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU Affero General Public License as published by
|
|
|
|
* the Free Software Foundation, version 3.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU Affero General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU Affero General Public License
|
|
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
*/
|
|
|
|
|
2020-02-25 23:15:21 +01:00
|
|
|
#include "window_main.hpp"
|
2020-02-25 03:22:13 +01:00
|
|
|
|
2020-02-24 20:59:45 +01:00
|
|
|
#include <QGuiApplication>
|
2020-02-25 23:15:21 +01:00
|
|
|
#include <QTranslator>
|
|
|
|
#include <QLibraryInfo>
|
2020-02-25 03:22:13 +01:00
|
|
|
|
|
|
|
using namespace FediPotato;
|
2020-02-24 20:59:45 +01:00
|
|
|
|
|
|
|
int main(int argc, char *argv[])
|
|
|
|
{
|
2020-02-25 23:15:21 +01:00
|
|
|
QApplication app(argc, argv);
|
|
|
|
QGuiApplication::setApplicationName("FediPotato");
|
2020-02-24 20:59:45 +01:00
|
|
|
|
2020-02-25 23:15:21 +01:00
|
|
|
QTranslator qtTranslator;
|
|
|
|
qtTranslator.load("qt_" + QLocale::system().name(),
|
|
|
|
QLibraryInfo::location(QLibraryInfo::TranslationsPath));
|
|
|
|
QGuiApplication::installTranslator(&qtTranslator);
|
2020-02-24 20:59:45 +01:00
|
|
|
|
2020-02-25 23:15:21 +01:00
|
|
|
QTranslator appTranslator;
|
|
|
|
appTranslator.load("FediPotato_" + QLocale::system().name(),
|
|
|
|
QLibraryInfo::location(QLibraryInfo::TranslationsPath));
|
|
|
|
QGuiApplication::installTranslator(&appTranslator);
|
|
|
|
|
2020-02-26 06:29:22 +01:00
|
|
|
MainWindow win;
|
2020-02-25 23:15:21 +01:00
|
|
|
win.show();
|
2020-02-24 20:59:45 +01:00
|
|
|
|
|
|
|
return QGuiApplication::exec();
|
|
|
|
}
|