1
Fork 0
mirror of https://github.com/redstrate/Novus.git synced 2025-04-21 19:57:44 +00:00
novus/armoury/src/main.cpp

31 lines
954 B
C++
Raw Normal View History

// SPDX-FileCopyrightText: 2023 Joshua Goins <josh@redstrate.com>
// SPDX-License-Identifier: GPL-3.0-or-later
2022-04-11 21:59:37 -04:00
#include <QApplication>
2022-08-10 14:52:28 -04:00
#include <physis.hpp>
2022-04-11 21:59:37 -04:00
#include "aboutdata.h"
2022-04-11 21:59:37 -04:00
#include "mainwindow.h"
2023-10-10 16:45:17 -04:00
#include "physis_logger.h"
#include "settings.h"
2022-04-11 21:59:37 -04:00
int main(int argc, char* argv[]) {
QApplication app(argc, argv);
customizeAboutData(
QStringLiteral("armoury"), QStringLiteral("Armoury"), QStringLiteral("Program to view FFXIV gear."));
2023-10-10 16:45:17 -04:00
// Default to a sensible message pattern
if (qEnvironmentVariableIsEmpty("QT_MESSAGE_PATTERN")) {
qputenv("QT_MESSAGE_PATTERN", "[%{time yyyy-MM-dd h:mm:ss.zzz}] %{if-category}[%{category}] %{endif}[%{type}] %{message}");
}
setup_physis_logging();
const QString gameDir{getGameDirectory()};
const std::string gameDirStd{gameDir.toStdString()};
MainWindow w(physis_gamedata_initialize(gameDirStd.c_str()));
2022-04-11 21:59:37 -04:00
w.show();
return QApplication::exec();
2022-04-11 21:59:37 -04:00
}