summaryrefslogtreecommitdiffstats
path: root/gui/newinstancedialog.cpp
diff options
context:
space:
mode:
authorPetr Mrázek <peterix@gmail.com>2013-09-07 04:00:58 +0200
committerPetr Mrázek <peterix@gmail.com>2013-09-07 04:00:58 +0200
commit6892c11e9f287dcfb1e698f8f46233a01fb7abb6 (patch)
treeee94607e92bcf39faef7f35842499fafbb2e270f /gui/newinstancedialog.cpp
parent3f30055afe757637ae865b2adc7cf021edd9b8b5 (diff)
downloadMultiMC-6892c11e9f287dcfb1e698f8f46233a01fb7abb6.tar
MultiMC-6892c11e9f287dcfb1e698f8f46233a01fb7abb6.tar.gz
MultiMC-6892c11e9f287dcfb1e698f8f46233a01fb7abb6.tar.lz
MultiMC-6892c11e9f287dcfb1e698f8f46233a01fb7abb6.tar.xz
MultiMC-6892c11e9f287dcfb1e698f8f46233a01fb7abb6.zip
Move a good chunk of the singleton objects into a new QApplication subclass.
Diffstat (limited to 'gui/newinstancedialog.cpp')
-rw-r--r--gui/newinstancedialog.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/gui/newinstancedialog.cpp b/gui/newinstancedialog.cpp
index f0a70a1b..ac3bcd7d 100644
--- a/gui/newinstancedialog.cpp
+++ b/gui/newinstancedialog.cpp
@@ -13,12 +13,13 @@
* limitations under the License.
*/
+#include <MultiMC.h>
#include "newinstancedialog.h"
#include "ui_newinstancedialog.h"
#include "logic/InstanceFactory.h"
#include "logic/InstanceVersion.h"
-#include "logic/IconListModel.h"
+#include "logic/lists/IconList.h"
#include "logic/lists/MinecraftVersionList.h"
#include "logic/tasks/Task.h"
@@ -49,8 +50,7 @@ NewInstanceDialog::NewInstanceDialog(QWidget *parent) :
*/
setSelectedVersion(MinecraftVersionList::getMainList().getLatestStable());
InstIconKey = "infinity";
- IconList * list = IconList::instance();
- ui->iconButton->setIcon(list->getIcon(InstIconKey));
+ ui->iconButton->setIcon(MMC->icons()->getIcon(InstIconKey));
}
NewInstanceDialog::~NewInstanceDialog()
@@ -113,9 +113,8 @@ void NewInstanceDialog::on_iconButton_clicked()
if(dlg.result() == QDialog::Accepted)
{
- IconList * list = IconList::instance();
InstIconKey = dlg.selectedIconKey;
- ui->iconButton->setIcon(list->getIcon(InstIconKey));
+ ui->iconButton->setIcon(MMC->icons()->getIcon(InstIconKey));
}
}