aboutsummaryrefslogtreecommitdiff
path: root/launcher/ui/dialogs
diff options
context:
space:
mode:
authorTheKodeToad <TheKodeToad@proton.me>2023-03-01 21:11:04 +0000
committerTheKodeToad <TheKodeToad@proton.me>2023-03-02 10:31:53 +0000
commit0fadb5a2be5f8136a4a5f52f7e5602698b53f09e (patch)
tree963c555b7d0398c2b9c6c41bc3b5cfd9c75d5047 /launcher/ui/dialogs
parent8b897ac714f5317c6544c0fa6058495544301391 (diff)
downloadPrismLauncher-0fadb5a2be5f8136a4a5f52f7e5602698b53f09e.tar.gz
PrismLauncher-0fadb5a2be5f8136a4a5f52f7e5602698b53f09e.tar.bz2
PrismLauncher-0fadb5a2be5f8136a4a5f52f7e5602698b53f09e.zip
Add *basic* interaction
Signed-off-by: TheKodeToad <TheKodeToad@proton.me>
Diffstat (limited to 'launcher/ui/dialogs')
-rw-r--r--launcher/ui/dialogs/ExportMrPackDialog.cpp10
-rw-r--r--launcher/ui/dialogs/ExportMrPackDialog.h2
-rw-r--r--launcher/ui/dialogs/ExportMrPackDialog.ui47
3 files changed, 55 insertions, 4 deletions
diff --git a/launcher/ui/dialogs/ExportMrPackDialog.cpp b/launcher/ui/dialogs/ExportMrPackDialog.cpp
index eb53a61f..735a6245 100644
--- a/launcher/ui/dialogs/ExportMrPackDialog.cpp
+++ b/launcher/ui/dialogs/ExportMrPackDialog.cpp
@@ -23,6 +23,16 @@ ExportMrPackDialog::ExportMrPackDialog(InstancePtr instance, QWidget* parent)
: QDialog(parent), instance(instance), ui(new Ui::ExportMrPackDialog)
{
ui->setupUi(this);
+ ui->name->setText(instance->name());
+}
+
+void ExportMrPackDialog::done(int result) {
+ if (result != Accepted) {
+ QDialog::done(result);
+ return;
+ }
+ QDialog::done(result);
+
}
ExportMrPackDialog::~ExportMrPackDialog()
diff --git a/launcher/ui/dialogs/ExportMrPackDialog.h b/launcher/ui/dialogs/ExportMrPackDialog.h
index 78322a8f..31ab86ff 100644
--- a/launcher/ui/dialogs/ExportMrPackDialog.h
+++ b/launcher/ui/dialogs/ExportMrPackDialog.h
@@ -32,6 +32,8 @@ class ExportMrPackDialog : public QDialog {
explicit ExportMrPackDialog(InstancePtr instance, QWidget* parent = nullptr);
~ExportMrPackDialog();
+ void done(int result) override;
+
private:
InstancePtr instance;
Ui::ExportMrPackDialog* ui;
diff --git a/launcher/ui/dialogs/ExportMrPackDialog.ui b/launcher/ui/dialogs/ExportMrPackDialog.ui
index 2b553987..37c87158 100644
--- a/launcher/ui/dialogs/ExportMrPackDialog.ui
+++ b/launcher/ui/dialogs/ExportMrPackDialog.ui
@@ -28,7 +28,7 @@
</widget>
</item>
<item row="3" column="1">
- <widget class="QLineEdit" name="lineEdit_3"/>
+ <widget class="QLineEdit" name="summary"/>
</item>
<item row="0" column="0">
<widget class="QLabel" name="label">
@@ -45,10 +45,10 @@
</widget>
</item>
<item row="0" column="1">
- <widget class="QLineEdit" name="lineEdit"/>
+ <widget class="QLineEdit" name="name"/>
</item>
<item row="1" column="1">
- <widget class="QLineEdit" name="lineEdit_2"/>
+ <widget class="QLineEdit" name="version"/>
</item>
</layout>
</widget>
@@ -72,6 +72,45 @@
</item>
</layout>
</widget>
+ <tabstops>
+ <tabstop>name</tabstop>
+ <tabstop>version</tabstop>
+ <tabstop>summary</tabstop>
+ <tabstop>treeView</tabstop>
+ </tabstops>
<resources/>
- <connections/>
+ <connections>
+ <connection>
+ <sender>buttonBox</sender>
+ <signal>accepted()</signal>
+ <receiver>ExportMrPackDialog</receiver>
+ <slot>accept()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>324</x>
+ <y>390</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>324</x>
+ <y>206</y>
+ </hint>
+ </hints>
+ </connection>
+ <connection>
+ <sender>buttonBox</sender>
+ <signal>rejected()</signal>
+ <receiver>ExportMrPackDialog</receiver>
+ <slot>reject()</slot>
+ <hints>
+ <hint type="sourcelabel">
+ <x>324</x>
+ <y>390</y>
+ </hint>
+ <hint type="destinationlabel">
+ <x>324</x>
+ <y>206</y>
+ </hint>
+ </hints>
+ </connection>
+ </connections>
</ui>