From c523a2c752bb7b071715f6c4eac18f36bcd2c162 Mon Sep 17 00:00:00 2001 From: Orochimarufan Date: Wed, 20 Feb 2013 00:07:52 +0100 Subject: implement commandline parsing --- gui/mainwindow.cpp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'gui') diff --git a/gui/mainwindow.cpp b/gui/mainwindow.cpp index 9bbc4c38..0ca9fde1 100644 --- a/gui/mainwindow.cpp +++ b/gui/mainwindow.cpp @@ -1,4 +1,8 @@ /* Copyright 2013 MultiMC Contributors + * + * Authors: Andrew Okin + * Peterix + * Orochimarufan * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -19,9 +23,10 @@ #include #include #include - +#include #include #include +#include #include "util/osutils.h" #include "util/userutil.h" @@ -168,9 +173,9 @@ void MainWindow::on_actionMakeDesktopShortcut_triggered() QString name("Test"); name = QInputDialog::getText(this, tr("MultiMC Shortcut"), tr("Enter a Shortcut Name."), QLineEdit::Normal, name); - Util::createShortCut(Util::getDesktopDir(), "test", QStringList() << "-d" << "lol", name, "application-x-octet-stream"); + Util::createShortCut(Util::getDesktopDir(), QApplication::instance()->applicationFilePath(), QStringList() << "-dl" << QDir::currentPath() << "test", name, "application-x-octet-stream"); - QMessageBox::warning(this, "Stupidness", "A Dummy Shortcut was created. the current instance model doesnt allow for anything more"); + QMessageBox::warning(this, "Not useful", "A Dummy Shortcut was created. it will not do anything productive"); } // BrowserDialog -- cgit v1.2.3