NOISSUE continue debranding...
This commit is contained in:
parent
297d4b4196
commit
5b3dffce62
1
.gitignore
vendored
1
.gitignore
vendored
@ -3,7 +3,6 @@ Thumbs.db
|
||||
.user
|
||||
.directory
|
||||
resources/CMakeFiles
|
||||
resources/MultiMCLauncher.jar
|
||||
*~
|
||||
*.swp
|
||||
html/
|
||||
|
@ -5,6 +5,16 @@ const Config BuildConfig;
|
||||
|
||||
Config::Config()
|
||||
{
|
||||
// Name and copyright
|
||||
LAUNCHER_NAME = "@Launcher_Name@";
|
||||
LAUNCHER_DISPLAYNAME = "@Launcher_DisplayName@";
|
||||
LAUNCHER_COPYRIGHT = "@Launcher_Copyright@";
|
||||
LAUNCHER_DOMAIN = "@Launcher_Domain@";
|
||||
LAUNCHER_CONFIGFILE = "@Launcher_ConfigFile@";
|
||||
|
||||
USER_AGENT = "@Launcher_UserAgent@";
|
||||
USER_AGENT_UNCACHED = USER_AGENT + " (Uncached)";
|
||||
|
||||
// Version information
|
||||
VERSION_MAJOR = @Launcher_VERSION_MAJOR@;
|
||||
VERSION_MINOR = @Launcher_VERSION_MINOR@;
|
||||
|
@ -8,6 +8,12 @@ class Config
|
||||
{
|
||||
public:
|
||||
Config();
|
||||
QString LAUNCHER_NAME;
|
||||
QString LAUNCHER_DISPLAYNAME;
|
||||
QString LAUNCHER_COPYRIGHT;
|
||||
QString LAUNCHER_DOMAIN;
|
||||
QString LAUNCHER_CONFIGFILE;
|
||||
|
||||
/// The major version number.
|
||||
int VERSION_MAJOR;
|
||||
/// The minor version number.
|
||||
@ -31,10 +37,13 @@ public:
|
||||
/// URL for the updater's channel
|
||||
QString UPDATER_BASE;
|
||||
|
||||
|
||||
/// User-Agent to use.
|
||||
QString USER_AGENT = "MultiMC/5.0";
|
||||
QString USER_AGENT;
|
||||
|
||||
/// User-Agent to use for uncached requests.
|
||||
QString USER_AGENT_UNCACHED = "MultiMC/5.0 (Uncached)";
|
||||
QString USER_AGENT_UNCACHED;
|
||||
|
||||
|
||||
/// Google analytics ID
|
||||
QString ANALYTICS_ID;
|
||||
@ -71,7 +80,7 @@ public:
|
||||
QString IMGUR_CLIENT_ID;
|
||||
|
||||
/**
|
||||
* MultiMC Metadata repository URL prefix
|
||||
* Metadata repository URL prefix
|
||||
*/
|
||||
QString META_URL;
|
||||
|
||||
|
@ -23,6 +23,6 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
#define MULTIMC_GET_TEST_FILE(file) TestsInternal::readFile(QFINDTESTDATA(file))
|
||||
#define MULTIMC_GET_TEST_FILE_UTF8(file) TestsInternal::readFileUtf8(QFINDTESTDATA(file))
|
||||
#define GET_TEST_FILE(file) TestsInternal::readFile(QFINDTESTDATA(file))
|
||||
#define GET_TEST_FILE_UTF8(file) TestsInternal::readFileUtf8(QFINDTESTDATA(file))
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3">
|
||||
<assemblyIdentity name="MultiMC.Test.0" type="win32" version="5.0.0.0" />
|
||||
<assemblyIdentity name="Launcher.Test.0" type="win32" version="5.0.0.0" />
|
||||
<trustInfo xmlns="urn:schemas-microsoft-com:asm.v3">
|
||||
<security>
|
||||
<requestedPrivileges>
|
||||
|
@ -17,7 +17,7 @@ BEGIN
|
||||
VALUE "CompanyName", "MultiMC Contributors"
|
||||
VALUE "FileDescription", "Testcase"
|
||||
VALUE "FileVersion", "1.0.0.0"
|
||||
VALUE "ProductName", "MultiMC Testcase"
|
||||
VALUE "ProductName", "Launcher Testcase"
|
||||
VALUE "ProductVersion", "5"
|
||||
END
|
||||
END
|
||||
|
@ -25,6 +25,7 @@
|
||||
|
||||
#include "FileSystem.h"
|
||||
#include "Commandline.h"
|
||||
#include "BuildConfig.h"
|
||||
|
||||
BaseInstance::BaseInstance(SettingsObjectPtr globalSettings, SettingsObjectPtr settings, const QString &rootDir)
|
||||
: QObject()
|
||||
@ -260,7 +261,7 @@ QString BaseInstance::name() const
|
||||
|
||||
QString BaseInstance::windowTitle() const
|
||||
{
|
||||
return "MultiMC: " + name().replace(QRegExp("[ \n\r\t]+"), " ");
|
||||
return BuildConfig.LAUNCHER_NAME + ": " + name().replace(QRegExp("[ \n\r\t]+"), " ");
|
||||
}
|
||||
|
||||
// FIXME: why is this here? move it to MinecraftInstance!!!
|
||||
|
@ -71,7 +71,7 @@ public:
|
||||
virtual void saveNow() = 0;
|
||||
|
||||
/***
|
||||
* the instance has been invalidated - it is no longer tracked by MultiMC for some reason,
|
||||
* the instance has been invalidated - it is no longer tracked by the launcher for some reason,
|
||||
* but it has not necessarily been deleted.
|
||||
*
|
||||
* Happens when the instance folder changes to some other location, or the instance is removed by external means.
|
||||
|
@ -555,7 +555,7 @@ set(LOGIC_SOURCES
|
||||
${ATLAUNCHER_SOURCES}
|
||||
)
|
||||
|
||||
SET(MULTIMC_SOURCES
|
||||
SET(LAUNCHER_SOURCES
|
||||
# Application base
|
||||
Launcher.h
|
||||
Launcher.cpp
|
||||
@ -812,7 +812,7 @@ SET(MULTIMC_SOURCES
|
||||
)
|
||||
|
||||
######## UIs ########
|
||||
SET(MULTIMC_UIS
|
||||
SET(LAUNCHER_UIS
|
||||
# Instance pages
|
||||
pages/instance/GameOptionsPage.ui
|
||||
pages/instance/VersionPage.ui
|
||||
@ -868,7 +868,7 @@ SET(MULTIMC_UIS
|
||||
widgets/MCModInfoFrame.ui
|
||||
)
|
||||
|
||||
set(MULTIMC_QRCS
|
||||
set(LAUNCHER_QRCS
|
||||
resources/backgrounds/backgrounds.qrc
|
||||
resources/multimc/multimc.qrc
|
||||
resources/pe_dark/pe_dark.qrc
|
||||
@ -879,19 +879,20 @@ set(MULTIMC_QRCS
|
||||
resources/iOS/iOS.qrc
|
||||
resources/flat/flat.qrc
|
||||
resources/documents/documents.qrc
|
||||
../${Launcher_Branding_LogoQRC}
|
||||
)
|
||||
|
||||
######## Windows resource files ########
|
||||
if(WIN32)
|
||||
set(MULTIMC_RCS ../${Launcher_Branding_WindowsRC})
|
||||
set(LAUNCHER_RCS ../${Launcher_Branding_WindowsRC})
|
||||
endif()
|
||||
|
||||
# Qt 5 stuff
|
||||
qt5_wrap_ui(MULTIMC_UI ${MULTIMC_UIS})
|
||||
qt5_add_resources(MULTIMC_RESOURCES ${MULTIMC_QRCS})
|
||||
qt5_wrap_ui(LAUNCHER_UI ${LAUNCHER_UIS})
|
||||
qt5_add_resources(LAUNCHER_RESOURCES ${LAUNCHER_QRCS})
|
||||
|
||||
# Add executable
|
||||
add_library(Launcher_logic STATIC ${LOGIC_SOURCES} ${MULTIMC_SOURCES} ${MULTIMC_UI} ${MULTIMC_RESOURCES})
|
||||
add_library(Launcher_logic STATIC ${LOGIC_SOURCES} ${LAUNCHER_SOURCES} ${LAUNCHER_UI} ${LAUNCHER_RESOURCES})
|
||||
target_link_libraries(Launcher_logic
|
||||
systeminfo
|
||||
Launcher_quazip
|
||||
@ -921,7 +922,7 @@ target_link_libraries(Launcher_logic
|
||||
|
||||
target_link_libraries(Launcher_logic secrets)
|
||||
|
||||
add_executable(${Launcher_Name} MACOSX_BUNDLE WIN32 main.cpp ${MULTIMC_RCS})
|
||||
add_executable(${Launcher_Name} MACOSX_BUNDLE WIN32 main.cpp ${LAUNCHER_RCS})
|
||||
target_link_libraries(${Launcher_Name} Launcher_logic)
|
||||
|
||||
if(DEFINED Launcher_APP_BINARY_NAME)
|
||||
|
@ -91,7 +91,7 @@ public:
|
||||
LogColorCache(QColor front, QColor back)
|
||||
: ColorCache(front, back, 1.0)
|
||||
{
|
||||
addColor((int)MessageLevel::MultiMC, QColor("purple"));
|
||||
addColor((int)MessageLevel::Launcher, QColor("purple"));
|
||||
addColor((int)MessageLevel::Debug, QColor("green"));
|
||||
addColor((int)MessageLevel::Warning, QColor("orange"));
|
||||
addColor((int)MessageLevel::Error, QColor("red"));
|
||||
|
@ -135,7 +135,7 @@ slots:
|
||||
<< "asdf"
|
||||
<< QString()
|
||||
#if defined(Q_OS_LINUX)
|
||||
<< MULTIMC_GET_TEST_FILE("data/FileSystem-test_createShortcut-unix")
|
||||
<< GET_TEST_FILE("data/FileSystem-test_createShortcut-unix")
|
||||
#elif defined(Q_OS_WIN)
|
||||
<< QByteArray()
|
||||
#endif
|
||||
|
@ -259,7 +259,7 @@ void InstanceList::deleteInstance(const InstanceId& id)
|
||||
return;
|
||||
}
|
||||
|
||||
qDebug() << "Instance" << id << "has been deleted by MultiMC.";
|
||||
qDebug() << "Instance" << id << "has been deleted by the launcher.";
|
||||
}
|
||||
|
||||
static QMap<InstanceId, InstanceLocator> getIdMapping(const QList<InstancePtr> &list)
|
||||
@ -799,7 +799,7 @@ private slots:
|
||||
private:
|
||||
/*
|
||||
* WHY: the whole reason why this uses an exponential backoff retry scheme is antivirus on Windows.
|
||||
* Basically, it starts messing things up while MultiMC is extracting/creating instances
|
||||
* Basically, it starts messing things up while the launcher is extracting/creating instances
|
||||
* and causes that horrible failure that is NTFS to lock files in place because they are open.
|
||||
*/
|
||||
ExponentialSeries backoff;
|
||||
|
@ -47,7 +47,7 @@ void LaunchController::login() {
|
||||
m_parentWidget,
|
||||
tr("No Accounts"),
|
||||
tr("In order to play Minecraft, you must have at least one Mojang or Minecraft "
|
||||
"account logged in to MultiMC."
|
||||
"account logged in."
|
||||
"Would you like to open the account manager to add an account now?"),
|
||||
QMessageBox::Information,
|
||||
QMessageBox::Yes | QMessageBox::No
|
||||
@ -286,7 +286,7 @@ void LaunchController::launchInstance()
|
||||
}
|
||||
resolved_servers = resolved_servers + "]\n\n";
|
||||
}
|
||||
m_launcher->prependStep(new TextPrint(m_launcher.get(), resolved_servers, MessageLevel::MultiMC));
|
||||
m_launcher->prependStep(new TextPrint(m_launcher.get(), resolved_servers, MessageLevel::Launcher));
|
||||
} else {
|
||||
online_mode = "offline";
|
||||
}
|
||||
@ -298,10 +298,10 @@ void LaunchController::launchInstance()
|
||||
auth_server_status = "offline";
|
||||
}
|
||||
|
||||
m_launcher->prependStep(new TextPrint(m_launcher.get(), "Launched instance in " + online_mode + " mode\nAuthentication server is " + auth_server_status + "\n", MessageLevel::MultiMC));
|
||||
m_launcher->prependStep(new TextPrint(m_launcher.get(), "Launched instance in " + online_mode + " mode\nAuthentication server is " + auth_server_status + "\n", MessageLevel::Launcher));
|
||||
|
||||
// Prepend Version
|
||||
m_launcher->prependStep(new TextPrint(m_launcher.get(), "MultiMC version: " + BuildConfig.printableVersionString() + "\n\n", MessageLevel::MultiMC));
|
||||
m_launcher->prependStep(new TextPrint(m_launcher.get(), BuildConfig.LAUNCHER_NAME + " version: " + BuildConfig.printableVersionString() + "\n\n", MessageLevel::Launcher));
|
||||
m_launcher->start();
|
||||
}
|
||||
|
||||
|
@ -87,7 +87,7 @@ static const QLatin1String liveCheckFile("live.check");
|
||||
|
||||
using namespace Commandline;
|
||||
|
||||
#define MACOS_HINT "If you are on macOS Sierra, you might have to move MultiMC.app to your /Applications or ~/Applications folder. "\
|
||||
#define MACOS_HINT "If you are on macOS Sierra, you might have to move the app to your /Applications or ~/Applications folder. "\
|
||||
"This usually fixes the problem and you can move the application elsewhere afterwards.\n"\
|
||||
"\n"
|
||||
|
||||
@ -179,10 +179,10 @@ Launcher::Launcher(int &argc, char **argv) : QApplication(argc, argv)
|
||||
consoleAttached = true;
|
||||
}
|
||||
#endif
|
||||
setOrganizationName("MultiMC");
|
||||
setOrganizationDomain("multimc.org");
|
||||
setApplicationName("MultiMC5");
|
||||
setApplicationDisplayName("MultiMC 5");
|
||||
setOrganizationName(BuildConfig.LAUNCHER_NAME);
|
||||
setOrganizationDomain(BuildConfig.LAUNCHER_DOMAIN);
|
||||
setApplicationName(BuildConfig.LAUNCHER_NAME);
|
||||
setApplicationDisplayName(BuildConfig.LAUNCHER_DISPLAYNAME);
|
||||
setApplicationVersion(BuildConfig.printableVersionString());
|
||||
|
||||
startTime = QDateTime::currentDateTime();
|
||||
@ -200,7 +200,7 @@ Launcher::Launcher(int &argc, char **argv) : QApplication(argc, argv)
|
||||
showFatalErrorMessage(
|
||||
"Unsupported system detected!",
|
||||
"Linux-on-Windows distributions are not supported.\n\n"
|
||||
"Please use the Windows MultiMC binary when playing on Windows."
|
||||
"Please use the Windows binary when playing on Windows."
|
||||
);
|
||||
return;
|
||||
}
|
||||
@ -227,7 +227,7 @@ Launcher::Launcher(int &argc, char **argv) : QApplication(argc, argv)
|
||||
// --dir
|
||||
parser.addOption("dir");
|
||||
parser.addShortOpt("dir", 'd');
|
||||
parser.addDocumentation("dir", "Use the supplied folder as MultiMC root instead of "
|
||||
parser.addDocumentation("dir", "Use the supplied folder as application root instead of "
|
||||
"the binary location (use '.' for current)");
|
||||
// --launch
|
||||
parser.addOption("launch");
|
||||
@ -240,7 +240,7 @@ Launcher::Launcher(int &argc, char **argv) : QApplication(argc, argv)
|
||||
"(only valid in combination with --launch)");
|
||||
// --alive
|
||||
parser.addSwitch("alive");
|
||||
parser.addDocumentation("alive", "Write a small '" + liveCheckFile + "' file after MultiMC starts");
|
||||
parser.addDocumentation("alive", "Write a small '" + liveCheckFile + "' file after the launcher starts");
|
||||
// --import
|
||||
parser.addOption("import");
|
||||
parser.addShortOpt("import", 'I');
|
||||
@ -255,7 +255,7 @@ Launcher::Launcher(int &argc, char **argv) : QApplication(argc, argv)
|
||||
{
|
||||
std::cerr << "CommandLineError: " << e.what() << std::endl;
|
||||
if(argc > 0)
|
||||
std::cerr << "Try '" << argv[0] << " -h' to get help on MultiMC's command line parameters."
|
||||
std::cerr << "Try '" << argv[0] << " -h' to get help on command line parameters."
|
||||
<< std::endl;
|
||||
m_status = Launcher::Failed;
|
||||
return;
|
||||
@ -298,13 +298,7 @@ Launcher::Launcher(int &argc, char **argv) : QApplication(argc, argv)
|
||||
}
|
||||
else
|
||||
{
|
||||
#ifdef MULTIMC_LINUX_DATADIR
|
||||
QString xdgDataHome = QFile::decodeName(qgetenv("XDG_DATA_HOME"));
|
||||
if (xdgDataHome.isEmpty())
|
||||
xdgDataHome = QDir::homePath() + QLatin1String("/.local/share");
|
||||
dataPath = xdgDataHome + "/multimc";
|
||||
adjustedBy += "XDG standard " + dataPath;
|
||||
#elif defined(Q_OS_MAC)
|
||||
#if defined(Q_OS_MAC)
|
||||
QDir foo(FS::PathCombine(applicationDirPath(), "../../Data"));
|
||||
dataPath = foo.absolutePath();
|
||||
adjustedBy += "Fallback to special Mac location " + dataPath;
|
||||
@ -317,30 +311,30 @@ Launcher::Launcher(int &argc, char **argv) : QApplication(argc, argv)
|
||||
if (!FS::ensureFolderPathExists(dataPath))
|
||||
{
|
||||
showFatalErrorMessage(
|
||||
"MultiMC data folder could not be created.",
|
||||
"MultiMC data folder could not be created.\n"
|
||||
"The launcher data folder could not be created.",
|
||||
"The launcher data folder could not be created.\n"
|
||||
"\n"
|
||||
#if defined(Q_OS_MAC)
|
||||
MACOS_HINT
|
||||
#endif
|
||||
"Make sure you have the right permissions to the MultiMC data folder and any folder needed to access it.\n"
|
||||
"Make sure you have the right permissions to the launcher data folder and any folder needed to access it.\n"
|
||||
"\n"
|
||||
"MultiMC cannot continue until you fix this problem."
|
||||
"The launcher cannot continue until you fix this problem."
|
||||
);
|
||||
return;
|
||||
}
|
||||
if (!QDir::setCurrent(dataPath))
|
||||
{
|
||||
showFatalErrorMessage(
|
||||
"MultiMC data folder could not be opened.",
|
||||
"MultiMC data folder could not be opened.\n"
|
||||
"The launcher data folder could not be opened.",
|
||||
"The launcher data folder could not be opened.\n"
|
||||
"\n"
|
||||
#if defined(Q_OS_MAC)
|
||||
MACOS_HINT
|
||||
#endif
|
||||
"Make sure you have the right permissions to the MultiMC data folder.\n"
|
||||
"Make sure you have the right permissions to the launcher data folder.\n"
|
||||
"\n"
|
||||
"MultiMC cannot continue until you fix this problem."
|
||||
"The launcher cannot continue until you fix this problem."
|
||||
);
|
||||
return;
|
||||
}
|
||||
@ -357,18 +351,24 @@ Launcher::Launcher(int &argc, char **argv) : QApplication(argc, argv)
|
||||
QDir fi(applicationDirPath());
|
||||
QString originalData = fi.absolutePath();
|
||||
// if the config file exists in Contents/MacOS, then user data is still there and needs to moved
|
||||
if (QFileInfo::exists(FS::PathCombine(originalData, "multimc.cfg")))
|
||||
if (QFileInfo::exists(FS::PathCombine(originalData, BuildConfig.LAUNCHER_CONFIGFILE)))
|
||||
{
|
||||
if (!QFileInfo::exists(FS::PathCombine(originalData, "dontmovemacdata")))
|
||||
{
|
||||
QMessageBox::StandardButton askMoveDialogue;
|
||||
askMoveDialogue = QMessageBox::question(nullptr, "MultiMC 5", "Would you like to move application data to a new data location? It will improve MultiMC's performance, but if you switch to older versions it will look like instances have disappeared. If you select no, you can migrate later in settings. You should select yes unless you're commonly switching between different versions of MultiMC (eg. develop and stable).", QMessageBox::Yes | QMessageBox::No, QMessageBox::Yes);
|
||||
askMoveDialogue = QMessageBox::question(
|
||||
nullptr,
|
||||
BuildConfig.LAUNCHER_DISPLAYNAME,
|
||||
"Would you like to move application data to a new data location? It will improve the launcher's performance, but if you switch to older versions it will look like instances have disappeared. If you select no, you can migrate later in settings. You should select yes unless you're commonly switching between different versions (eg. develop and stable).",
|
||||
QMessageBox::Yes | QMessageBox::No,
|
||||
QMessageBox::Yes
|
||||
);
|
||||
if (askMoveDialogue == QMessageBox::Yes)
|
||||
{
|
||||
qDebug() << "On macOS and found config file in old location, moving user data...";
|
||||
QDir dir;
|
||||
QStringList dataFiles {
|
||||
"*.log", // MultiMC-@.log
|
||||
"*.log", // Launcher log files: ${Launcher_Name}-@.log
|
||||
"accounts.json",
|
||||
"accounts",
|
||||
"assets",
|
||||
@ -379,7 +379,7 @@ Launcher::Launcher(int &argc, char **argv) : QApplication(argc, argv)
|
||||
"meta",
|
||||
"metacache",
|
||||
"mods",
|
||||
"multimc.cfg",
|
||||
BuildConfig.LAUNCHER_CONFIGFILE,
|
||||
"themes",
|
||||
"translations"
|
||||
};
|
||||
@ -451,7 +451,7 @@ Launcher::Launcher(int &argc, char **argv) : QApplication(argc, argv)
|
||||
|
||||
// init the logger
|
||||
{
|
||||
static const QString logBase = "MultiMC-%0.log";
|
||||
static const QString logBase = BuildConfig.LAUNCHER_NAME + "-%0.log";
|
||||
auto moveFile = [](const QString &oldName, const QString &newName)
|
||||
{
|
||||
QFile::remove(newName);
|
||||
@ -468,15 +468,15 @@ Launcher::Launcher(int &argc, char **argv) : QApplication(argc, argv)
|
||||
if(!logFile->open(QIODevice::WriteOnly | QIODevice::Text | QIODevice::Truncate))
|
||||
{
|
||||
showFatalErrorMessage(
|
||||
"MultiMC data folder is not writable!",
|
||||
"MultiMC couldn't create a log file - the MultiMC data folder is not writable.\n"
|
||||
"The launcher data folder is not writable!",
|
||||
"The launcher couldn't create a log file - the data folder is not writable.\n"
|
||||
"\n"
|
||||
#if defined(Q_OS_MAC)
|
||||
MACOS_HINT
|
||||
#endif
|
||||
"Make sure you have write permissions to the MultiMC data folder.\n"
|
||||
"Make sure you have write permissions to the data folder.\n"
|
||||
"\n"
|
||||
"MultiMC cannot continue until you fix this problem."
|
||||
"The launcher cannot continue until you fix this problem."
|
||||
);
|
||||
return;
|
||||
}
|
||||
@ -503,7 +503,7 @@ Launcher::Launcher(int &argc, char **argv) : QApplication(argc, argv)
|
||||
ENV.setJarsPath( TOSTRING(MULTIMC_JARS_LOCATION) );
|
||||
#endif
|
||||
|
||||
qDebug() << "MultiMC 5, (c) 2013-2021 MultiMC Contributors";
|
||||
qDebug() << BuildConfig.LAUNCHER_DISPLAYNAME << ", (c) 2013-2021 " << BuildConfig.LAUNCHER_COPYRIGHT;
|
||||
qDebug() << "Version : " << BuildConfig.printableVersionString();
|
||||
qDebug() << "Git commit : " << BuildConfig.GIT_COMMIT;
|
||||
qDebug() << "Git refspec : " << BuildConfig.GIT_REFSPEC;
|
||||
@ -553,7 +553,7 @@ Launcher::Launcher(int &argc, char **argv) : QApplication(argc, argv)
|
||||
|
||||
// Initialize application settings
|
||||
{
|
||||
m_settings.reset(new INISettingsObject("multimc.cfg", this));
|
||||
m_settings.reset(new INISettingsObject(BuildConfig.LAUNCHER_CONFIGFILE, this));
|
||||
// Updates
|
||||
m_settings->registerSetting("UpdateChannel", BuildConfig.VERSION_CHANNEL);
|
||||
m_settings->registerSetting("AutoUpdate", true);
|
||||
@ -1164,6 +1164,9 @@ void Launcher::setIconTheme(const QString& name)
|
||||
|
||||
QIcon Launcher::getThemedIcon(const QString& name)
|
||||
{
|
||||
if(name == "logo") {
|
||||
return QIcon(":/logo.svg");
|
||||
}
|
||||
return XdgIcon::fromTheme(name);
|
||||
}
|
||||
|
||||
|
@ -221,7 +221,7 @@ private:
|
||||
// main window, if any
|
||||
MainWindow * m_mainWindow = nullptr;
|
||||
|
||||
// peer MultiMC instance connector - used to implement single instance MultiMC and signalling
|
||||
// peer launcher instance connector - used to implement single instance launcher and signalling
|
||||
LocalPeer * m_peerInstance = nullptr;
|
||||
|
||||
GAnalytics * m_analytics = nullptr;
|
||||
|
@ -65,16 +65,16 @@ void LoggedProcess::on_exit(int exit_code, QProcess::ExitStatus status)
|
||||
if (status == QProcess::NormalExit)
|
||||
{
|
||||
//: Message displayed on instance exit
|
||||
emit log({tr("Process exited with code %1.").arg(exit_code)}, MessageLevel::MultiMC);
|
||||
emit log({tr("Process exited with code %1.").arg(exit_code)}, MessageLevel::Launcher);
|
||||
changeState(LoggedProcess::Finished);
|
||||
}
|
||||
else
|
||||
{
|
||||
//: Message displayed on instance crashed
|
||||
if(exit_code == -1)
|
||||
emit log({tr("Process crashed.")}, MessageLevel::MultiMC);
|
||||
emit log({tr("Process crashed.")}, MessageLevel::Launcher);
|
||||
else
|
||||
emit log({tr("Process crashed with exitcode %1.").arg(exit_code)}, MessageLevel::MultiMC);
|
||||
emit log({tr("Process crashed with exitcode %1.").arg(exit_code)}, MessageLevel::Launcher);
|
||||
changeState(LoggedProcess::Crashed);
|
||||
}
|
||||
}
|
||||
|
@ -133,11 +133,21 @@ public:
|
||||
{
|
||||
if(m_text)
|
||||
{
|
||||
m_contained->setText(QApplication::translate("MainWindow", m_text));
|
||||
QString result;
|
||||
result = QApplication::translate("MainWindow", m_text);
|
||||
if(result.contains("%1")) {
|
||||
result = result.arg(BuildConfig.LAUNCHER_NAME);
|
||||
}
|
||||
m_contained->setText(result);
|
||||
}
|
||||
if(m_tooltip)
|
||||
{
|
||||
m_contained->setToolTip(QApplication::translate("MainWindow", m_tooltip));
|
||||
QString result;
|
||||
result = QApplication::translate("MainWindow", m_tooltip);
|
||||
if(result.contains("%1")) {
|
||||
result = result.arg(BuildConfig.LAUNCHER_NAME);
|
||||
}
|
||||
m_contained->setToolTip(result);
|
||||
}
|
||||
}
|
||||
private:
|
||||
@ -324,7 +334,7 @@ public:
|
||||
actionReportBug->setObjectName(QStringLiteral("actionReportBug"));
|
||||
actionReportBug->setIcon(LAUNCHER->getThemedIcon("bug"));
|
||||
actionReportBug.setTextId(QT_TRANSLATE_NOOP("MainWindow", "Report a Bug"));
|
||||
actionReportBug.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Open the bug tracker to report a bug with MultiMC."));
|
||||
actionReportBug.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Open the bug tracker to report a bug with %1."));
|
||||
all_actions.append(&actionReportBug);
|
||||
helpMenu->addAction(actionReportBug);
|
||||
}
|
||||
@ -334,7 +344,7 @@ public:
|
||||
actionDISCORD->setObjectName(QStringLiteral("actionDISCORD"));
|
||||
actionDISCORD->setIcon(LAUNCHER->getThemedIcon("discord"));
|
||||
actionDISCORD.setTextId(QT_TRANSLATE_NOOP("MainWindow", "Discord"));
|
||||
actionDISCORD.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Open MultiMC discord voice chat."));
|
||||
actionDISCORD.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Open %1 discord voice chat."));
|
||||
all_actions.append(&actionDISCORD);
|
||||
helpMenu->addAction(actionDISCORD);
|
||||
}
|
||||
@ -344,7 +354,7 @@ public:
|
||||
actionREDDIT->setObjectName(QStringLiteral("actionREDDIT"));
|
||||
actionREDDIT->setIcon(LAUNCHER->getThemedIcon("reddit-alien"));
|
||||
actionREDDIT.setTextId(QT_TRANSLATE_NOOP("MainWindow", "Reddit"));
|
||||
actionREDDIT.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Open MultiMC subreddit."));
|
||||
actionREDDIT.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Open %1 subreddit."));
|
||||
all_actions.append(&actionREDDIT);
|
||||
helpMenu->addAction(actionREDDIT);
|
||||
}
|
||||
@ -353,14 +363,14 @@ public:
|
||||
actionAbout->setObjectName(QStringLiteral("actionAbout"));
|
||||
actionAbout->setIcon(LAUNCHER->getThemedIcon("about"));
|
||||
actionAbout->setMenuRole(QAction::AboutRole);
|
||||
actionAbout.setTextId(QT_TRANSLATE_NOOP("MainWindow", "About MultiMC"));
|
||||
actionAbout.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "View information about MultiMC."));
|
||||
actionAbout.setTextId(QT_TRANSLATE_NOOP("MainWindow", "About %1"));
|
||||
actionAbout.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "View information about %1."));
|
||||
all_actions.append(&actionAbout);
|
||||
helpMenu->addAction(actionAbout);
|
||||
|
||||
helpMenuButton = TranslatedToolButton(MainWindow);
|
||||
helpMenuButton.setTextId(QT_TRANSLATE_NOOP("MainWindow", "Help"));
|
||||
helpMenuButton.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Get help with MultiMC or Minecraft."));
|
||||
helpMenuButton.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Get help with %1 or Minecraft."));
|
||||
helpMenuButton->setMenu(helpMenu);
|
||||
helpMenuButton->setPopupMode(QToolButton::InstantPopup);
|
||||
helpMenuButton->setToolButtonStyle(Qt::ToolButtonTextBesideIcon);
|
||||
@ -377,7 +387,7 @@ public:
|
||||
actionCheckUpdate->setObjectName(QStringLiteral("actionCheckUpdate"));
|
||||
actionCheckUpdate->setIcon(LAUNCHER->getThemedIcon("checkupdate"));
|
||||
actionCheckUpdate.setTextId(QT_TRANSLATE_NOOP("MainWindow", "Update"));
|
||||
actionCheckUpdate.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Check for new updates for MultiMC."));
|
||||
actionCheckUpdate.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Check for new updates for %1."));
|
||||
all_actions.append(&actionCheckUpdate);
|
||||
mainToolBar->addAction(actionCheckUpdate);
|
||||
}
|
||||
@ -387,8 +397,8 @@ public:
|
||||
actionPatreon = TranslatedAction(MainWindow);
|
||||
actionPatreon->setObjectName(QStringLiteral("actionPatreon"));
|
||||
actionPatreon->setIcon(LAUNCHER->getThemedIcon("patreon"));
|
||||
actionPatreon.setTextId(QT_TRANSLATE_NOOP("MainWindow", "Support MultiMC"));
|
||||
actionPatreon.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Open the MultiMC Patreon page."));
|
||||
actionPatreon.setTextId(QT_TRANSLATE_NOOP("MainWindow", "Support %1"));
|
||||
actionPatreon.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Open the %1 Patreon page."));
|
||||
all_actions.append(&actionPatreon);
|
||||
mainToolBar->addAction(actionPatreon);
|
||||
|
||||
@ -437,7 +447,7 @@ public:
|
||||
actionMoreNews->setObjectName(QStringLiteral("actionMoreNews"));
|
||||
actionMoreNews->setIcon(LAUNCHER->getThemedIcon("news"));
|
||||
actionMoreNews.setTextId(QT_TRANSLATE_NOOP("MainWindow", "More news..."));
|
||||
actionMoreNews.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Open the MultiMC development blog to read more news about MultiMC."));
|
||||
actionMoreNews.setTooltipId(QT_TRANSLATE_NOOP("MainWindow", "Open the development blog to read more news about %1."));
|
||||
all_actions.append(&actionMoreNews);
|
||||
newsToolBar->addAction(actionMoreNews);
|
||||
|
||||
@ -596,9 +606,9 @@ public:
|
||||
}
|
||||
MainWindow->resize(800, 600);
|
||||
MainWindow->setWindowIcon(LAUNCHER->getThemedIcon("logo"));
|
||||
MainWindow->setWindowTitle("MultiMC 5");
|
||||
MainWindow->setWindowTitle(BuildConfig.LAUNCHER_DISPLAYNAME);
|
||||
#ifndef QT_NO_ACCESSIBILITY
|
||||
MainWindow->setAccessibleName("MultiMC");
|
||||
MainWindow->setAccessibleName(BuildConfig.LAUNCHER_NAME);
|
||||
#endif
|
||||
|
||||
createMainToolbar(MainWindow);
|
||||
@ -623,7 +633,7 @@ public:
|
||||
|
||||
void retranslateUi(QMainWindow *MainWindow)
|
||||
{
|
||||
QString winTitle = tr("MultiMC 5 - Version %1").arg(BuildConfig.printableVersionString());
|
||||
QString winTitle = tr("%1 - Version %2", "Launcher - Version X").arg(BuildConfig.LAUNCHER_DISPLAYNAME, BuildConfig.printableVersionString());
|
||||
if (!BuildConfig.BUILD_PLATFORM.isEmpty())
|
||||
{
|
||||
winTitle += tr(" on %1", "on platform, as in operating system").arg(BuildConfig.BUILD_PLATFORM);
|
||||
@ -897,7 +907,7 @@ void MainWindow::showInstanceContextMenu(const QPoint &pos)
|
||||
{
|
||||
auto group = view->groupNameAt(pos);
|
||||
|
||||
QAction *actionVoid = new QAction("MultiMC", this);
|
||||
QAction *actionVoid = new QAction(BuildConfig.LAUNCHER_NAME, this);
|
||||
actionVoid->setEnabled(false);
|
||||
|
||||
QAction *actionCreateInstance = new QAction(tr("Create instance"), this);
|
||||
@ -1381,10 +1391,13 @@ void MainWindow::finalizeInstance(InstancePtr inst)
|
||||
}
|
||||
else
|
||||
{
|
||||
CustomMessageBox::selectable(this, tr("Error"), tr("MultiMC cannot download Minecraft or update instances unless you have at least "
|
||||
"one account added.\nPlease add your Mojang or Minecraft account."),
|
||||
QMessageBox::Warning)
|
||||
->show();
|
||||
CustomMessageBox::selectable(
|
||||
this,
|
||||
tr("Error"),
|
||||
tr("The launcher cannot download Minecraft or update instances unless you have at least "
|
||||
"one account added.\nPlease add your Mojang or Minecraft account."),
|
||||
QMessageBox::Warning
|
||||
)->show();
|
||||
}
|
||||
}
|
||||
|
||||
@ -1879,20 +1892,24 @@ void MainWindow::checkInstancePathForProblems()
|
||||
{
|
||||
QMessageBox warning(this);
|
||||
warning.setText(tr("Your instance folder contains \'!\' and this is known to cause Java problems!"));
|
||||
warning.setInformativeText(tr("You have now two options: <br/>"
|
||||
" - change the instance folder in the settings <br/>"
|
||||
" - move this installation of MultiMC5 to a different folder"));
|
||||
warning.setInformativeText(
|
||||
tr(
|
||||
"You have now two options: <br/>"
|
||||
" - change the instance folder in the settings <br/>"
|
||||
" - move this installation of %1 to a different folder"
|
||||
).arg(BuildConfig.LAUNCHER_NAME)
|
||||
);
|
||||
warning.setDefaultButton(QMessageBox::Ok);
|
||||
warning.exec();
|
||||
}
|
||||
auto tempFolderText = tr("This is a problem: <br/>"
|
||||
" - MultiMC will likely be deleted without warning by the operating system <br/>"
|
||||
" - close MultiMC now and extract it to a real location, not a temporary folder");
|
||||
" - The launcher will likely be deleted without warning by the operating system <br/>"
|
||||
" - close the launcher now and extract it to a real location, not a temporary folder");
|
||||
QString pathfoldername = QDir(instanceFolder).absolutePath();
|
||||
if (pathfoldername.contains("Rar$", Qt::CaseInsensitive))
|
||||
{
|
||||
QMessageBox warning(this);
|
||||
warning.setText(tr("Your instance folder contains \'Rar$\' - that means you haven't extracted the MultiMC zip!"));
|
||||
warning.setText(tr("Your instance folder contains \'Rar$\' - that means you haven't extracted the launcher archive!"));
|
||||
warning.setInformativeText(tempFolderText);
|
||||
warning.setDefaultButton(QMessageBox::Ok);
|
||||
warning.exec();
|
||||
|
@ -2,8 +2,8 @@
|
||||
|
||||
MessageLevel::Enum MessageLevel::getLevel(const QString& levelName)
|
||||
{
|
||||
if (levelName == "MultiMC")
|
||||
return MessageLevel::MultiMC;
|
||||
if (levelName == "Launcher")
|
||||
return MessageLevel::Launcher;
|
||||
else if (levelName == "Debug")
|
||||
return MessageLevel::Debug;
|
||||
else if (levelName == "Info")
|
||||
|
@ -13,7 +13,7 @@ enum Enum
|
||||
Unknown, /**< No idea what this is or where it came from */
|
||||
StdOut, /**< Undetermined stderr messages */
|
||||
StdErr, /**< Undetermined stdout messages */
|
||||
MultiMC, /**< MultiMC Messages */
|
||||
Launcher, /**< Launcher Messages */
|
||||
Debug, /**< Debug Messages */
|
||||
Info, /**< Info Messages */
|
||||
Message, /**< Standard Messages */
|
||||
|
@ -8,6 +8,9 @@
|
||||
#include <chrono>
|
||||
#include <LocalPeer.h>
|
||||
|
||||
#include "BuildConfig.h"
|
||||
|
||||
|
||||
// from <sys/stat.h>
|
||||
#ifndef S_IRUSR
|
||||
#define __S_IREAD 0400 /* Read by owner. */
|
||||
@ -91,7 +94,7 @@ void UpdateController::installUpdates()
|
||||
#ifdef Q_OS_WIN
|
||||
QString finishCmd = QApplication::applicationFilePath();
|
||||
#elif defined Q_OS_LINUX
|
||||
QString finishCmd = FS::PathCombine(m_root, "MultiMC");
|
||||
QString finishCmd = FS::PathCombine(m_root, BuildConfig.LAUNCHER_NAME);
|
||||
#elif defined Q_OS_MAC
|
||||
QString finishCmd = QApplication::applicationFilePath();
|
||||
#else
|
||||
@ -127,8 +130,9 @@ void UpdateController::installUpdates()
|
||||
case GoUpdate::Operation::OP_REPLACE:
|
||||
{
|
||||
#ifdef Q_OS_WIN32
|
||||
QString windowsExeName = BuildConfig.LAUNCHER_NAME + ".exe";
|
||||
// hack for people renaming the .exe because ... reasons :)
|
||||
if(op.destination == "MultiMC.exe")
|
||||
if(op.destination == windowsExeName)
|
||||
{
|
||||
op.destination = QFileInfo(QApplication::applicationFilePath()).fileName();
|
||||
}
|
||||
@ -137,7 +141,7 @@ void UpdateController::installUpdates()
|
||||
#ifdef Q_OS_WIN32
|
||||
if(QSysInfo::windowsVersion() < QSysInfo::WV_VISTA)
|
||||
{
|
||||
if(destination.fileName() == "MultiMC.exe")
|
||||
if(destination.fileName() == windowsExeName)
|
||||
{
|
||||
QDir rootDir(m_root);
|
||||
exeOrigin = rootDir.relativeFilePath(op.source);
|
||||
@ -365,16 +369,20 @@ void UpdateController::fail()
|
||||
{
|
||||
case Replace:
|
||||
{
|
||||
msg = QObject::tr("Couldn't replace file %1. Changes will be reverted.\n"
|
||||
"See the MultiMC log file for details.").arg(m_failedFile);
|
||||
msg = QObject::tr(
|
||||
"Couldn't replace file %1. Changes will be reverted.\n"
|
||||
"See the %2 log file for details."
|
||||
).arg(m_failedFile, BuildConfig.LAUNCHER_NAME);
|
||||
doRollback = true;
|
||||
QMessageBox::critical(m_parent, failTitle, msg);
|
||||
break;
|
||||
}
|
||||
case Delete:
|
||||
{
|
||||
msg = QObject::tr("Couldn't remove file %1. Changes will be reverted.\n"
|
||||
"See the MultiMC log file for details.").arg(m_failedFile);
|
||||
msg = QObject::tr(
|
||||
"Couldn't remove file %1. Changes will be reverted.\n"
|
||||
"See the %2 log file for details."
|
||||
).arg(m_failedFile, BuildConfig.LAUNCHER_NAME);
|
||||
doRollback = true;
|
||||
QMessageBox::critical(m_parent, failTitle, msg);
|
||||
break;
|
||||
@ -404,8 +412,8 @@ void UpdateController::fail()
|
||||
if(!rollbackOK)
|
||||
{
|
||||
msg = QObject::tr("The rollback failed too.\n"
|
||||
"You will have to repair MultiMC manually.\n"
|
||||
"Please let us know why and how this happened.").arg(m_failedFile);
|
||||
"You will have to repair %1 manually.\n"
|
||||
"Please let us know why and how this happened.").arg(BuildConfig.LAUNCHER_NAME);
|
||||
QMessageBox::critical(m_parent, rollFailTitle, msg);
|
||||
qApp->quit();
|
||||
}
|
||||
|
@ -31,9 +31,10 @@ QString getCreditsHtml(QStringList patrons)
|
||||
QString patronsHeading = QObject::tr("Patrons", "About Credits");
|
||||
QString output;
|
||||
QTextStream stream(&output);
|
||||
stream.setCodec(QTextCodec::codecForName("UTF-8"));
|
||||
stream << "<center>\n";
|
||||
// TODO: possibly retrieve from git history at build time?
|
||||
stream << "<h3>" << QObject::tr("MultiMC Developers", "About Credits") << "</h3>\n";
|
||||
stream << "<h3>" << QObject::tr("Developers", "About Credits") << "</h3>\n";
|
||||
stream << "<p>Andrew Okin <<a href='mailto:forkk@forkk.net'>forkk@forkk.net</a>></p>\n";
|
||||
stream << "<p>Petr Mrázek <<a href='mailto:peterix@gmail.com'>peterix@gmail.com</a>></p>\n";
|
||||
stream << "<p>Sky Welch <<a href='mailto:multimc@bunnies.io'>multimc@bunnies.io</a>></p>\n";
|
||||
@ -75,6 +76,10 @@ AboutDialog::AboutDialog(QWidget *parent) : QDialog(parent), ui(new Ui::AboutDia
|
||||
{
|
||||
ui->setupUi(this);
|
||||
|
||||
QString launcherName = BuildConfig.LAUNCHER_NAME;
|
||||
|
||||
setWindowTitle(tr("About %1").arg(launcherName));
|
||||
|
||||
QString chtml = getCreditsHtml(QStringList());
|
||||
ui->creditsText->setHtml(chtml);
|
||||
|
||||
@ -84,7 +89,7 @@ AboutDialog::AboutDialog(QWidget *parent) : QDialog(parent), ui(new Ui::AboutDia
|
||||
ui->urlLabel->setOpenExternalLinks(true);
|
||||
|
||||
ui->icon->setPixmap(LAUNCHER->getThemedIcon("logo").pixmap(64));
|
||||
ui->title->setText("MultiMC 5");
|
||||
ui->title->setText(launcherName);
|
||||
|
||||
ui->versionLabel->setText(tr("Version") +": " + BuildConfig.printableVersionString());
|
||||
ui->platformLabel->setText(tr("Platform") +": " + BuildConfig.BUILD_PLATFORM);
|
||||
|
@ -16,9 +16,6 @@
|
||||
<height>400</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>About MultiMC</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
|
@ -48,7 +48,7 @@ void CheckJava::executeTask()
|
||||
}
|
||||
else
|
||||
{
|
||||
emit logLine("Java path is:\n" + m_javaPath + "\n\n", MessageLevel::MultiMC);
|
||||
emit logLine("Java path is:\n" + m_javaPath + "\n\n", MessageLevel::Launcher);
|
||||
}
|
||||
|
||||
QFileInfo javaInfo(realJavaPath);
|
||||
@ -62,7 +62,7 @@ void CheckJava::executeTask()
|
||||
if (javaUnixTime != storedUnixTime || storedVersion.size() == 0 || storedArchitecture.size() == 0 || storedVendor.size() == 0)
|
||||
{
|
||||
m_JavaChecker = new JavaChecker();
|
||||
emit logLine(QString("Checking Java version..."), MessageLevel::MultiMC);
|
||||
emit logLine(QString("Checking Java version..."), MessageLevel::Launcher);
|
||||
connect(m_JavaChecker.get(), &JavaChecker::checkFinished, this, &CheckJava::checkJavaFinished);
|
||||
m_JavaChecker->m_path = realJavaPath;
|
||||
m_JavaChecker->performCheck();
|
||||
@ -87,7 +87,7 @@ void CheckJava::checkJavaFinished(JavaCheckResult result)
|
||||
// Error message displayed if java can't start
|
||||
emit logLine(QString("Could not start java:"), MessageLevel::Error);
|
||||
emit logLines(result.errorLog.split('\n'), MessageLevel::Error);
|
||||
emit logLine("\nCheck your MultiMC Java settings.", MessageLevel::MultiMC);
|
||||
emit logLine("\nCheck your MultiMC Java settings.", MessageLevel::Launcher);
|
||||
printSystemInfo(false, false);
|
||||
emitFailed(QString("Could not start java!"));
|
||||
return;
|
||||
@ -96,7 +96,7 @@ void CheckJava::checkJavaFinished(JavaCheckResult result)
|
||||
{
|
||||
emit logLine(QString("Java checker returned some invalid data MultiMC doesn't understand:"), MessageLevel::Error);
|
||||
emit logLines(result.outLog.split('\n'), MessageLevel::Warning);
|
||||
emit logLine("\nMinecraft might not start properly.", MessageLevel::MultiMC);
|
||||
emit logLine("\nMinecraft might not start properly.", MessageLevel::Launcher);
|
||||
printSystemInfo(false, false);
|
||||
emitSucceeded();
|
||||
return;
|
||||
@ -117,7 +117,7 @@ void CheckJava::checkJavaFinished(JavaCheckResult result)
|
||||
|
||||
void CheckJava::printJavaInfo(const QString& version, const QString& architecture, const QString & vendor)
|
||||
{
|
||||
emit logLine(QString("Java is version %1, using %2-bit architecture, from %3.\n\n").arg(version, architecture, vendor), MessageLevel::MultiMC);
|
||||
emit logLine(QString("Java is version %1, using %2-bit architecture, from %3.\n\n").arg(version, architecture, vendor), MessageLevel::Launcher);
|
||||
printSystemInfo(true, architecture == "64");
|
||||
}
|
||||
|
||||
|
@ -103,8 +103,8 @@ signals:
|
||||
void requestLogging();
|
||||
|
||||
public slots:
|
||||
void onLogLines(const QStringList& lines, MessageLevel::Enum defaultLevel = MessageLevel::MultiMC);
|
||||
void onLogLine(QString line, MessageLevel::Enum defaultLevel = MessageLevel::MultiMC);
|
||||
void onLogLines(const QStringList& lines, MessageLevel::Enum defaultLevel = MessageLevel::Launcher);
|
||||
void onLogLine(QString line, MessageLevel::Enum defaultLevel = MessageLevel::Launcher);
|
||||
void onReadyForLaunch();
|
||||
void onStepFinished();
|
||||
void onProgressReportingRequested();
|
||||
|
@ -60,7 +60,7 @@ void LookupServerAddress::on_dnsLookupFinished()
|
||||
if (m_dnsLookup->error() != QDnsLookup::NoError)
|
||||
{
|
||||
emit logLine(QString("Failed to resolve server address (this is NOT an error!) %1: %2\n")
|
||||
.arg(m_dnsLookup->name(), m_dnsLookup->errorString()), MessageLevel::MultiMC);
|
||||
.arg(m_dnsLookup->name(), m_dnsLookup->errorString()), MessageLevel::Launcher);
|
||||
resolve(m_lookupAddress, 25565); // Technically the task failed, however, we don't abort the launch
|
||||
// and leave it up to minecraft to fail (or maybe not) when connecting
|
||||
return;
|
||||
@ -81,7 +81,7 @@ void LookupServerAddress::on_dnsLookupFinished()
|
||||
quint16 port = firstRecord.port();
|
||||
|
||||
emit logLine(QString("Resolved server address %1 to %2 with port %3\n").arg(
|
||||
m_dnsLookup->name(), firstRecord.target(), QString::number(port)),MessageLevel::MultiMC);
|
||||
m_dnsLookup->name(), firstRecord.target(), QString::number(port)),MessageLevel::Launcher);
|
||||
resolve(firstRecord.target(), port);
|
||||
}
|
||||
|
||||
|
@ -28,7 +28,7 @@ PostLaunchCommand::PostLaunchCommand(LaunchTask *parent) : LaunchStep(parent)
|
||||
void PostLaunchCommand::executeTask()
|
||||
{
|
||||
QString postlaunch_cmd = m_parent->substituteVariables(m_command);
|
||||
emit logLine(tr("Running Post-Launch command: %1").arg(postlaunch_cmd), MessageLevel::MultiMC);
|
||||
emit logLine(tr("Running Post-Launch command: %1").arg(postlaunch_cmd), MessageLevel::Launcher);
|
||||
m_process.start(postlaunch_cmd);
|
||||
}
|
||||
|
||||
@ -59,7 +59,7 @@ void PostLaunchCommand::on_state(LoggedProcess::State state)
|
||||
}
|
||||
else
|
||||
{
|
||||
emit logLine(tr("Post-Launch command ran successfully.\n\n"), MessageLevel::MultiMC);
|
||||
emit logLine(tr("Post-Launch command ran successfully.\n\n"), MessageLevel::Launcher);
|
||||
emitSucceeded();
|
||||
}
|
||||
}
|
||||
|
@ -29,7 +29,7 @@ void PreLaunchCommand::executeTask()
|
||||
{
|
||||
//FIXME: where to put this?
|
||||
QString prelaunch_cmd = m_parent->substituteVariables(m_command);
|
||||
emit logLine(tr("Running Pre-Launch command: %1").arg(prelaunch_cmd), MessageLevel::MultiMC);
|
||||
emit logLine(tr("Running Pre-Launch command: %1").arg(prelaunch_cmd), MessageLevel::Launcher);
|
||||
m_process.start(prelaunch_cmd);
|
||||
}
|
||||
|
||||
@ -60,7 +60,7 @@ void PreLaunchCommand::on_state(LoggedProcess::State state)
|
||||
}
|
||||
else
|
||||
{
|
||||
emit logLine(tr("Pre-Launch command ran successfully.\n\n"), MessageLevel::MultiMC);
|
||||
emit logLine(tr("Pre-Launch command ran successfully.\n\n"), MessageLevel::Launcher);
|
||||
emitSucceeded();
|
||||
}
|
||||
}
|
||||
|
@ -43,6 +43,8 @@ int main(int argc, char *argv[])
|
||||
{
|
||||
Q_INIT_RESOURCE(multimc);
|
||||
Q_INIT_RESOURCE(backgrounds);
|
||||
Q_INIT_RESOURCE(documents);
|
||||
Q_INIT_RESOURCE(logo);
|
||||
|
||||
Q_INIT_RESOURCE(pe_dark);
|
||||
Q_INIT_RESOURCE(pe_light);
|
||||
@ -51,7 +53,6 @@ int main(int argc, char *argv[])
|
||||
Q_INIT_RESOURCE(OSX);
|
||||
Q_INIT_RESOURCE(iOS);
|
||||
Q_INIT_RESOURCE(flat);
|
||||
Q_INIT_RESOURCE(documents);
|
||||
return app.exec();
|
||||
}
|
||||
case Launcher::Failed:
|
||||
|
@ -838,7 +838,7 @@ shared_qobject_ptr<LaunchTask> MinecraftInstance::createLaunchTask(AuthSessionPt
|
||||
|
||||
// print a header
|
||||
{
|
||||
process->appendStep(new TextPrint(pptr, "Minecraft folder is:\n" + gameRoot() + "\n\n", MessageLevel::MultiMC));
|
||||
process->appendStep(new TextPrint(pptr, "Minecraft folder is:\n" + gameRoot() + "\n\n", MessageLevel::Launcher));
|
||||
}
|
||||
|
||||
// check java
|
||||
|
@ -5,6 +5,7 @@
|
||||
#include "Json.h"
|
||||
using namespace Json;
|
||||
#include "ParseUtils.h"
|
||||
#include <BuildConfig.h>
|
||||
|
||||
static const int CURRENT_MINIMUM_LAUNCHER_VERSION = 18;
|
||||
|
||||
@ -175,9 +176,11 @@ void MojangVersionFormat::readVersionProperties(const QJsonObject &in, VersionFi
|
||||
{
|
||||
out->addProblem(
|
||||
ProblemSeverity::Warning,
|
||||
QObject::tr("The 'minimumLauncherVersion' value of this version (%1) is higher than supported by MultiMC (%2). It might not work properly!")
|
||||
QObject::tr("The 'minimumLauncherVersion' value of this version (%1) is higher than supported by %3 (%2). It might not work properly!")
|
||||
.arg(out->minimumLauncherVersion)
|
||||
.arg(CURRENT_MINIMUM_LAUNCHER_VERSION));
|
||||
.arg(CURRENT_MINIMUM_LAUNCHER_VERSION)
|
||||
.arg(BuildConfig.LAUNCHER_NAME)
|
||||
);
|
||||
}
|
||||
}
|
||||
if(in.contains("downloads"))
|
||||
|
@ -241,13 +241,16 @@ void Yggdrasil::processReply()
|
||||
case QNetworkReply::SslHandshakeFailedError:
|
||||
changeState(
|
||||
STATE_FAILED_SOFT,
|
||||
tr("<b>SSL Handshake failed.</b><br/>There might be a few causes for it:<br/>"
|
||||
"<ul>"
|
||||
"<li>You use Windows and need to update your root certificates, please install any outstanding updates.</li>"
|
||||
"<li>Some device on your network is interfering with SSL traffic. In that case, "
|
||||
"you have bigger worries than Minecraft not starting.</li>"
|
||||
"<li>Possibly something else. Check the MultiMC log file for details</li>"
|
||||
"</ul>"));
|
||||
tr(
|
||||
"<b>SSL Handshake failed.</b><br/>There might be a few causes for it:<br/>"
|
||||
"<ul>"
|
||||
"<li>You use Windows and need to update your root certificates, please install any outstanding updates.</li>"
|
||||
"<li>Some device on your network is interfering with SSL traffic. In that case, "
|
||||
"you have bigger worries than Minecraft not starting.</li>"
|
||||
"<li>Possibly something else. Check the %1 log file for details</li>"
|
||||
"</ul>"
|
||||
).arg(BuildConfig.LAUNCHER_NAME)
|
||||
);
|
||||
return;
|
||||
// used for invalid credentials and similar errors. Fall through.
|
||||
case QNetworkReply::ContentAccessDenied:
|
||||
|
@ -46,7 +46,7 @@ void DirectJavaLaunch::executeTask()
|
||||
args.append(minecraftInstance->getMainClass());
|
||||
|
||||
QString allArgs = args.join(", ");
|
||||
emit logLine("Java Arguments:\n[" + m_parent->censorPrivateInfo(allArgs) + "]\n\n", MessageLevel::MultiMC);
|
||||
emit logLine("Java Arguments:\n[" + m_parent->censorPrivateInfo(allArgs) + "]\n\n", MessageLevel::Launcher);
|
||||
|
||||
auto javaPath = FS::ResolveExecutable(instance->settings()->get("JavaPath").toString());
|
||||
|
||||
@ -71,7 +71,7 @@ void DirectJavaLaunch::executeTask()
|
||||
emitFailed(tr(reason).arg(wrapperCommand));
|
||||
return;
|
||||
}
|
||||
emit logLine("Wrapper command is:\n" + wrapperCommandStr + "\n\n", MessageLevel::MultiMC);
|
||||
emit logLine("Wrapper command is:\n" + wrapperCommandStr + "\n\n", MessageLevel::Launcher);
|
||||
args.prepend(javaPath);
|
||||
m_process.start(wrapperCommand, wrapperArgs + args);
|
||||
}
|
||||
@ -117,7 +117,7 @@ void DirectJavaLaunch::on_state(LoggedProcess::State state)
|
||||
break;
|
||||
}
|
||||
case LoggedProcess::Running:
|
||||
emit logLine(QString("Minecraft process ID: %1\n\n").arg(m_process.processId()), MessageLevel::MultiMC);
|
||||
emit logLine(QString("Minecraft process ID: %1\n\n").arg(m_process.processId()), MessageLevel::Launcher);
|
||||
m_parent->setPid(m_process.processId());
|
||||
m_parent->instance()->setLastLaunch();
|
||||
break;
|
||||
|
@ -62,7 +62,7 @@ void LauncherPartLaunch::executeTask()
|
||||
m_launchScript = minecraftInstance->createLaunchScript(m_session, m_serverToJoin);
|
||||
QStringList args = minecraftInstance->javaArguments();
|
||||
QString allArgs = args.join(", ");
|
||||
emit logLine("Java Arguments:\n[" + m_parent->censorPrivateInfo(allArgs) + "]\n\n", MessageLevel::MultiMC);
|
||||
emit logLine("Java Arguments:\n[" + m_parent->censorPrivateInfo(allArgs) + "]\n\n", MessageLevel::Launcher);
|
||||
|
||||
auto javaPath = FS::ResolveExecutable(instance->settings()->get("JavaPath").toString());
|
||||
|
||||
@ -123,7 +123,7 @@ void LauncherPartLaunch::executeTask()
|
||||
emitFailed(tr(reason).arg(wrapperCommand));
|
||||
return;
|
||||
}
|
||||
emit logLine("Wrapper command is:\n" + wrapperCommandStr + "\n\n", MessageLevel::MultiMC);
|
||||
emit logLine("Wrapper command is:\n" + wrapperCommandStr + "\n\n", MessageLevel::Launcher);
|
||||
args.prepend(javaPath);
|
||||
m_process.start(wrapperCommand, wrapperArgs + args);
|
||||
}
|
||||
@ -169,7 +169,7 @@ void LauncherPartLaunch::on_state(LoggedProcess::State state)
|
||||
break;
|
||||
}
|
||||
case LoggedProcess::Running:
|
||||
emit logLine(QString("Minecraft process ID: %1\n\n").arg(m_process.processId()), MessageLevel::MultiMC);
|
||||
emit logLine(QString("Minecraft process ID: %1\n\n").arg(m_process.processId()), MessageLevel::Launcher);
|
||||
m_parent->setPid(m_process.processId());
|
||||
m_parent->instance()->setLastLaunch();
|
||||
// send the launch script to the launcher part
|
||||
|
@ -100,7 +100,7 @@ void PrintInstanceInfo::executeTask()
|
||||
::runGlxinfo(log);
|
||||
#endif
|
||||
|
||||
logLines(log, MessageLevel::MultiMC);
|
||||
logLines(instance->verboseDescription(m_session, m_serverToJoin), MessageLevel::MultiMC);
|
||||
logLines(log, MessageLevel::Launcher);
|
||||
logLines(instance->verboseDescription(m_session, m_serverToJoin), MessageLevel::Launcher);
|
||||
emitSucceeded();
|
||||
}
|
||||
|
@ -16,7 +16,7 @@ PasteUpload::PasteUpload(QWidget *window, QString text, QString key) : m_window(
|
||||
sectionObject.insert("contents", text);
|
||||
QJsonArray sectionArray;
|
||||
sectionArray.append(sectionObject);
|
||||
topLevelObj.insert("description", "MultiMC Log Upload");
|
||||
topLevelObj.insert("description", "Log Upload");
|
||||
topLevelObj.insert("sections", sectionArray);
|
||||
QJsonDocument docOut;
|
||||
docOut.setObject(topLevelObj);
|
||||
|
@ -39,7 +39,7 @@
|
||||
<item>
|
||||
<widget class="QLabel" name="proxyPlainTextWarningLabel_2">
|
||||
<property name="text">
|
||||
<string>This only applies to MultiMC. Minecraft does not accept proxy settings.</string>
|
||||
<string>This only applies to the launcher. Minecraft does not accept proxy settings.</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignCenter</set>
|
||||
@ -166,7 +166,7 @@
|
||||
<item row="2" column="0" colspan="2">
|
||||
<widget class="QLabel" name="proxyPlainTextWarningLabel">
|
||||
<property name="text">
|
||||
<string>Note: Proxy username and password are stored in plain text inside MultiMC's configuration file!</string>
|
||||
<string>Note: Proxy username and password are stored in plain text inside the launcher's configuration file!</string>
|
||||
</property>
|
||||
<property name="wordWrap">
|
||||
<bool>true</bool>
|
||||
|
@ -11,6 +11,7 @@
|
||||
#include <settings/Setting.h>
|
||||
#include "GuiUtil.h"
|
||||
#include <ColorCache.h>
|
||||
#include <BuildConfig.h>
|
||||
|
||||
class LogFormatProxyModel : public QIdentityProxyModel
|
||||
{
|
||||
@ -236,15 +237,30 @@ void LogPage::on_btnPaste_clicked()
|
||||
return;
|
||||
|
||||
//FIXME: turn this into a proper task and move the upload logic out of GuiUtil!
|
||||
m_model->append(MessageLevel::MultiMC, QString("MultiMC: Log upload triggered at: %1").arg(QDateTime::currentDateTime().toString(Qt::RFC2822Date)));
|
||||
m_model->append(
|
||||
MessageLevel::Launcher,
|
||||
QString("%2: Log upload triggered at: %1").arg(
|
||||
QDateTime::currentDateTime().toString(Qt::RFC2822Date),
|
||||
BuildConfig.LAUNCHER_NAME
|
||||
)
|
||||
);
|
||||
auto url = GuiUtil::uploadPaste(m_model->toPlainText(), this);
|
||||
if(!url.isEmpty())
|
||||
{
|
||||
m_model->append(MessageLevel::MultiMC, QString("MultiMC: Log uploaded to: %1").arg(url));
|
||||
m_model->append(
|
||||
MessageLevel::Launcher,
|
||||
QString("%2: Log uploaded to: %1").arg(
|
||||
url,
|
||||
BuildConfig.LAUNCHER_NAME
|
||||
)
|
||||
);
|
||||
}
|
||||
else
|
||||
{
|
||||
m_model->append(MessageLevel::Error, "MultiMC: Log upload failed!");
|
||||
m_model->append(
|
||||
MessageLevel::Error,
|
||||
QString("%1: Log upload failed!").arg(BuildConfig.LAUNCHER_NAME)
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@ -252,7 +268,7 @@ void LogPage::on_btnCopy_clicked()
|
||||
{
|
||||
if(!m_model)
|
||||
return;
|
||||
m_model->append(MessageLevel::MultiMC, QString("Clipboard copy at: %1").arg(QDateTime::currentDateTime().toString(Qt::RFC2822Date)));
|
||||
m_model->append(MessageLevel::Launcher, QString("Clipboard copy at: %1").arg(QDateTime::currentDateTime().toString(Qt::RFC2822Date)));
|
||||
GuiUtil::setClipboardText(m_model->toPlainText());
|
||||
}
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
[Icon Theme]
|
||||
Name=multimc
|
||||
Comment=MultiMC Default Icons
|
||||
Comment=Default Icons
|
||||
Inherits=default
|
||||
Directories=8x8,16x16,22x22,24x24,32x32,32x32/instances,48x48,50x50/instances,64x64,128x128/instances,256x256,scalable,scalable/instances
|
||||
|
||||
|
@ -47,13 +47,13 @@ void AnalyticsWizardPage::retranslate()
|
||||
setSubTitle(tr("We track some anonymous statistics about users."));
|
||||
textBrowser->setHtml(tr(
|
||||
"<html><body>"
|
||||
"<p>MultiMC sends anonymous usage statistics on every start of the application. This helps us decide what platforms and issues to focus on.</p>"
|
||||
"<p>The launcher sends anonymous usage statistics on every start of the application. This helps us decide what platforms and issues to focus on.</p>"
|
||||
"<p>The data is processed by Google Analytics, see their <a href=\"https://support.google.com/analytics/answer/6004245?hl=en\">article on the "
|
||||
"matter</a>.</p>"
|
||||
"<p>The following data is collected:</p>"
|
||||
"<ul><li>A random unique ID of the MultiMC installation.<br />It is stored in the application settings (multimc.cfg).</li>"
|
||||
"<ul><li>A random unique ID of the installation.<br />It is stored in the application settings file.</li>"
|
||||
"<li>Anonymized (partial) IP address.</li>"
|
||||
"<li>MultiMC version.</li>"
|
||||
"<li>Launcher version.</li>"
|
||||
"<li>Operating system name, version and architecture.</li>"
|
||||
"<li>CPU architecture (kernel architecture on linux).</li>"
|
||||
"<li>Size of system memory.</li>"
|
||||
|
@ -4,6 +4,7 @@
|
||||
|
||||
#include "widgets/LanguageSelectionWidget.h"
|
||||
#include <QVBoxLayout>
|
||||
#include <BuildConfig.h>
|
||||
|
||||
LanguageWizardPage::LanguageWizardPage(QWidget *parent)
|
||||
: BaseWizardPage(parent)
|
||||
@ -43,6 +44,6 @@ bool LanguageWizardPage::validatePage()
|
||||
void LanguageWizardPage::retranslate()
|
||||
{
|
||||
setTitle(tr("Language"));
|
||||
setSubTitle(tr("Select the language to use in MultiMC"));
|
||||
setSubTitle(tr("Select the language to use in %1").arg(BuildConfig.LAUNCHER_NAME));
|
||||
mainWidget->retranslate();
|
||||
}
|
||||
|
@ -10,6 +10,7 @@
|
||||
#include <ganalytics.h>
|
||||
|
||||
#include <QAbstractButton>
|
||||
#include <BuildConfig.h>
|
||||
|
||||
SetupWizard::SetupWizard(QWidget *parent) : QWizard(parent)
|
||||
{
|
||||
@ -30,7 +31,7 @@ void SetupWizard::retranslate()
|
||||
setButtonText(QWizard::BackButton, tr("< &Back"));
|
||||
setButtonText(QWizard::FinishButton, tr("&Finish"));
|
||||
setButtonText(QWizard::CustomButton1, tr("&Refresh"));
|
||||
setWindowTitle(tr("MultiMC Quick Setup"));
|
||||
setWindowTitle(tr("%1 Quick Setup").arg(BuildConfig.LAUNCHER_NAME));
|
||||
}
|
||||
|
||||
BaseWizardPage * SetupWizard::getBasePage(int id)
|
||||
|
@ -63,7 +63,7 @@ void Task::start()
|
||||
}
|
||||
case State::Running:
|
||||
{
|
||||
qWarning() << "MultiMC tried to start task" << describe() << "while it was already running!";
|
||||
qWarning() << "The launcher tried to start task" << describe() << "while it was already running!";
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
@ -77,7 +77,7 @@ slots:
|
||||
QTest::addColumn<bool>("ret");
|
||||
|
||||
QTest::newRow("one")
|
||||
<< MULTIMC_GET_TEST_FILE("data/1.json")
|
||||
<< GET_TEST_FILE("data/1.json")
|
||||
<< (VersionFileList()
|
||||
<< VersionFileEntry{"fileOne",
|
||||
493,
|
||||
@ -93,7 +93,7 @@ slots:
|
||||
"f12df554b21e320be6471d7154130e70"})
|
||||
<< QString() << true;
|
||||
QTest::newRow("two")
|
||||
<< MULTIMC_GET_TEST_FILE("data/2.json")
|
||||
<< GET_TEST_FILE("data/2.json")
|
||||
<< (VersionFileList()
|
||||
<< VersionFileEntry{"fileOne",
|
||||
493,
|
||||
|
@ -190,14 +190,6 @@ void UpdateChecker::updateChanList(bool notifyNoUpdate)
|
||||
return;
|
||||
}
|
||||
|
||||
if (m_channelUrl.isEmpty())
|
||||
{
|
||||
qCritical() << "Failed to update channel list. No channel list URL set."
|
||||
<< "If you'd like to use MultiMC's update system, please pass the channel "
|
||||
"list URL to CMake at compile time.";
|
||||
return;
|
||||
}
|
||||
|
||||
m_chanListLoading = true;
|
||||
NetJob *job = new NetJob("Update System Channel List");
|
||||
job->addNetAction(Net::Download::makeByteArray(QUrl(m_channelUrl), &chanlistData));
|
||||
|
@ -74,7 +74,7 @@
|
||||
<item>
|
||||
<widget class="QLabel" name="labelCustomCmdsDescription">
|
||||
<property name="text">
|
||||
<string><html><head/><body><p>Pre-launch command runs before the instance launches and post-exit command runs after it exits.</p><p>Both will be run in MultiMC's working folder with extra environment variables:</p><ul><li>$INST_NAME - Name of the instance</li><li>$INST_ID - ID of the instance (its folder name)</li><li>$INST_DIR - absolute path of the instance</li><li>$INST_MC_DIR - absolute path of minecraft</li><li>$INST_JAVA - java binary used for launch</li><li>$INST_JAVA_ARGS - command-line parameters used for launch</li></ul><p>Wrapper command allows launching using an extra wrapper program (like 'optirun' on Linux)</p></body></html></string>
|
||||
<string><html><head/><body><p>Pre-launch command runs before the instance launches and post-exit command runs after it exits.</p><p>Both will be run in the launcher's working folder with extra environment variables:</p><ul><li>$INST_NAME - Name of the instance</li><li>$INST_ID - ID of the instance (its folder name)</li><li>$INST_DIR - absolute path of the instance</li><li>$INST_MC_DIR - absolute path of minecraft</li><li>$INST_JAVA - java binary used for launch</li><li>$INST_JAVA_ARGS - command-line parameters used for launch</li></ul><p>Wrapper command allows launching using an extra wrapper program (like 'optirun' on Linux)</p></body></html></string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>
|
||||
|
@ -16,6 +16,7 @@
|
||||
#include <widgets/VersionSelectWidget.h>
|
||||
#include <FileSystem.h>
|
||||
#include <QFileDialog>
|
||||
#include <BuildConfig.h>
|
||||
|
||||
JavaSettingsWidget::JavaSettingsWidget(QWidget* parent) : QWidget(parent)
|
||||
{
|
||||
@ -146,11 +147,11 @@ JavaSettingsWidget::ValidationStatus JavaSettingsWidget::validate()
|
||||
this,
|
||||
tr("No Java version selected"),
|
||||
tr("You didn't select a Java version or selected something that doesn't work.\n"
|
||||
"MultiMC will not be able to start Minecraft.\n"
|
||||
"%1 will not be able to start Minecraft.\n"
|
||||
"Do you wish to proceed without any Java?"
|
||||
"\n\n"
|
||||
"You can change the Java version in the settings later.\n"
|
||||
),
|
||||
).arg(BuildConfig.LAUNCHER_NAME),
|
||||
QMessageBox::Warning,
|
||||
QMessageBox::Yes | QMessageBox::No,
|
||||
QMessageBox::NoButton
|
||||
|
@ -135,7 +135,7 @@ public class EntryPoint
|
||||
}
|
||||
if(isAborted)
|
||||
{
|
||||
System.err.println("Launch aborted by MultiMC.");
|
||||
System.err.println("Launch aborted by the launcher.");
|
||||
return 1;
|
||||
}
|
||||
if(m_launcher != null)
|
||||
|
@ -94,7 +94,7 @@ public class Utils
|
||||
}
|
||||
|
||||
/**
|
||||
* Log to the MultiMC console
|
||||
* Log to the launcher console
|
||||
*
|
||||
* @param message A String containing the message
|
||||
* @param level A String containing the level name. See MinecraftLauncher::getLevel()
|
||||
@ -108,7 +108,7 @@ public class Utils
|
||||
|
||||
public static void log(String message)
|
||||
{
|
||||
log(message, "MultiMC");
|
||||
log(message, "Launcher");
|
||||
}
|
||||
|
||||
public static void log()
|
||||
|
@ -3,8 +3,15 @@ target_link_libraries(secrets Qt5::Core)
|
||||
target_compile_definitions(secrets PUBLIC -DEMBED_SECRETS)
|
||||
target_include_directories(secrets PUBLIC .)
|
||||
|
||||
set(Launcher_Name "Launcher" PARENT_SCOPE)
|
||||
set(Launcher_CommonName "DevLauncher")
|
||||
|
||||
set(Launcher_Copyright "MultiMC Contributors" PARENT_SCOPE)
|
||||
set(Launcher_Domain "multimc.org" PARENT_SCOPE)
|
||||
set(Launcher_Name "${Launcher_CommonName}" PARENT_SCOPE)
|
||||
set(Launcher_DisplayName "${Launcher_CommonName} 5" PARENT_SCOPE)
|
||||
set(Launcher_UserAgent "${Launcher_CommonName}/5.0" PARENT_SCOPE)
|
||||
set(Launcher_ConfigFile "devlauncher.cfg" PARENT_SCOPE)
|
||||
|
||||
set(Launcher_Branding_ICNS "notsecrets/Launcher.icns" PARENT_SCOPE)
|
||||
set(Launcher_Branding_WindowsRC "notsecrets/launcher.rc" PARENT_SCOPE)
|
||||
set(Launcher_Branding_LogoQRC "notsecrets/logo.qrc" PARENT_SCOPE)
|
||||
|
8
notsecrets/logo.qrc
Normal file
8
notsecrets/logo.qrc
Normal file
@ -0,0 +1,8 @@
|
||||
<!DOCTYPE RCC>
|
||||
<RCC version="1.0">
|
||||
<qresource prefix="/">
|
||||
<file>logo.svg</file>
|
||||
</qresource>
|
||||
</RCC>
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user