summaryrefslogtreecommitdiffstats
path: root/gui
diff options
context:
space:
mode:
Diffstat (limited to 'gui')
-rw-r--r--gui/mainwindow.cpp5
-rw-r--r--gui/mainwindow.h4
-rw-r--r--gui/mainwindow.ui30
3 files changed, 32 insertions, 7 deletions
diff --git a/gui/mainwindow.cpp b/gui/mainwindow.cpp
index 8f7372c8..87a1dcc0 100644
--- a/gui/mainwindow.cpp
+++ b/gui/mainwindow.cpp
@@ -26,7 +26,8 @@ MainWindow::MainWindow(QWidget *parent) :
ui(new Ui::MainWindow)
{
ui->setupUi(this);
- instList.loadInstances("instances");
+ instList.initialLoad("instances");
+ ui->instanceView->setModel(&instList);
}
MainWindow::~MainWindow()
@@ -46,7 +47,7 @@ void MainWindow::on_actionViewInstanceFolder_triggered()
void MainWindow::on_actionRefresh_triggered()
{
- instList.loadInstances("instances");
+ instList.initialLoad("instances");
}
void MainWindow::on_actionViewCentralModsFolder_triggered()
diff --git a/gui/mainwindow.h b/gui/mainwindow.h
index 09cd0817..77245531 100644
--- a/gui/mainwindow.h
+++ b/gui/mainwindow.h
@@ -18,7 +18,7 @@
#include <QMainWindow>
-#include "../data/instancelist.h"
+#include "../data/instancemodel.h"
namespace Ui
{
@@ -55,7 +55,7 @@ private slots:
private:
Ui::MainWindow *ui;
- InstanceList instList;
+ InstanceModel instList;
};
#endif // MAINWINDOW_H
diff --git a/gui/mainwindow.ui b/gui/mainwindow.ui
index 0ef98d0e..ccc7e777 100644
--- a/gui/mainwindow.ui
+++ b/gui/mainwindow.ui
@@ -6,14 +6,38 @@
<rect>
<x>0</x>
<y>0</y>
- <width>600</width>
- <height>400</height>
+ <width>739</width>
+ <height>657</height>
</rect>
</property>
<property name="windowTitle">
<string>MultiMC 5</string>
</property>
- <widget class="QWidget" name="centralWidget"/>
+ <widget class="QWidget" name="centralWidget">
+ <layout class="QHBoxLayout" name="horizontalLayout">
+ <property name="spacing">
+ <number>0</number>
+ </property>
+ <property name="sizeConstraint">
+ <enum>QLayout::SetDefaultConstraint</enum>
+ </property>
+ <property name="leftMargin">
+ <number>0</number>
+ </property>
+ <property name="topMargin">
+ <number>0</number>
+ </property>
+ <property name="rightMargin">
+ <number>0</number>
+ </property>
+ <property name="bottomMargin">
+ <number>0</number>
+ </property>
+ <item>
+ <widget class="QTreeView" name="instanceView"/>
+ </item>
+ </layout>
+ </widget>
<widget class="QToolBar" name="mainToolBar">
<property name="movable">
<bool>false</bool>