summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorisanae <14251494+isanae@users.noreply.github.com>2019-06-07 20:08:53 -0400
committerisanae <14251494+isanae@users.noreply.github.com>2019-06-15 14:40:40 -0400
commit5556e2b152decad3392c30c9760a5584454b52e6 (patch)
treec1bffe5bb986093518e082a4fa7138216295ab96
parent840dba26bacd044164d3236218e42f441433252c (diff)
replaced close with ok/cancel
moved add/remove below the list
-rw-r--r--src/editexecutablesdialog.cpp9
-rw-r--r--src/editexecutablesdialog.h3
-rw-r--r--src/editexecutablesdialog.ui218
3 files changed, 125 insertions, 105 deletions
diff --git a/src/editexecutablesdialog.cpp b/src/editexecutablesdialog.cpp
index 559bc8f0..f7348889 100644
--- a/src/editexecutablesdialog.cpp
+++ b/src/editexecutablesdialog.cpp
@@ -370,10 +370,8 @@ void EditExecutablesDialog::on_overwriteAppIDBox_toggled(bool checked)
ui->appIDOverwriteEdit->setEnabled(checked);
}
-void EditExecutablesDialog::on_buttonBox_clicked(QAbstractButton*)
+void EditExecutablesDialog::on_buttonBox_accepted()
{
- // there's only a close button for now, so the actual button doesn't matter
-
if (executableChanged()) {
QMessageBox::StandardButton res = QMessageBox::question(this, tr("Save Changes?"),
tr("You made changes to the current executable, do you want to save them?"),
@@ -391,6 +389,11 @@ void EditExecutablesDialog::on_buttonBox_clicked(QAbstractButton*)
accept();
}
+void EditExecutablesDialog::on_buttonBox_rejected()
+{
+ reject();
+}
+
void EditExecutablesDialog::on_executablesListBox_clicked(const QModelIndex &current)
{
if (current.isValid()) {
diff --git a/src/editexecutablesdialog.h b/src/editexecutablesdialog.h
index 07d6459c..7f389b24 100644
--- a/src/editexecutablesdialog.h
+++ b/src/editexecutablesdialog.h
@@ -89,7 +89,8 @@ private slots:
void on_browseDirButton_clicked();
- void on_buttonBox_clicked(QAbstractButton *button);
+ void on_buttonBox_accepted();
+ void on_buttonBox_rejected();
void delayedRefresh();
diff --git a/src/editexecutablesdialog.ui b/src/editexecutablesdialog.ui
index 1cf1116a..52bbf187 100644
--- a/src/editexecutablesdialog.ui
+++ b/src/editexecutablesdialog.ui
@@ -6,8 +6,8 @@
<rect>
<x>0</x>
<y>0</y>
- <width>524</width>
- <height>366</height>
+ <width>710</width>
+ <height>293</height>
</rect>
</property>
<property name="minimumSize">
@@ -82,6 +82,70 @@
</property>
</widget>
</item>
+ <item>
+ <layout class="QHBoxLayout" name="horizontalLayout_2">
+ <item>
+ <spacer name="horizontalSpacer">
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>40</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ <item>
+ <widget class="QPushButton" name="addButton">
+ <property name="toolTip">
+ <string>Add an executable</string>
+ </property>
+ <property name="whatsThis">
+ <string>Add an executable</string>
+ </property>
+ <property name="text">
+ <string>Add</string>
+ </property>
+ <property name="icon">
+ <iconset>
+ <normaloff>:/new/guiresources/resources/list-add.png</normaloff>:/new/guiresources/resources/list-add.png</iconset>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QPushButton" name="removeButton">
+ <property name="toolTip">
+ <string>Remove the selected executable</string>
+ </property>
+ <property name="whatsThis">
+ <string>Remove the selected executable</string>
+ </property>
+ <property name="text">
+ <string>Remove</string>
+ </property>
+ <property name="icon">
+ <iconset>
+ <normaloff>:/new/guiresources/resources/list-remove.png</normaloff>:/new/guiresources/resources/list-remove.png</iconset>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <spacer name="horizontalSpacer_3">
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ <property name="sizeHint" stdset="0">
+ <size>
+ <width>40</width>
+ <height>20</height>
+ </size>
+ </property>
+ </spacer>
+ </item>
+ </layout>
+ </item>
</layout>
</widget>
<widget class="QWidget" name="widget" native="true">
@@ -99,15 +163,18 @@
<number>0</number>
</property>
<item>
- <layout class="QHBoxLayout" name="horizontalLayout_4">
- <item>
+ <layout class="QFormLayout" name="formLayout">
+ <property name="bottomMargin">
+ <number>20</number>
+ </property>
+ <item row="0" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Title</string>
</property>
</widget>
</item>
- <item>
+ <item row="0" column="1">
<widget class="QLineEdit" name="titleEdit">
<property name="toolTip">
<string>Name of the executable. This is only for display purposes.</string>
@@ -117,73 +184,69 @@
</property>
</widget>
</item>
- </layout>
- </item>
- <item>
- <layout class="QHBoxLayout" name="horizontalLayout">
- <item>
+ <item row="1" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Binary</string>
</property>
</widget>
</item>
- <item>
- <widget class="QLineEdit" name="binaryEdit">
- <property name="toolTip">
- <string>Binary to run</string>
- </property>
- <property name="whatsThis">
- <string>Binary to run</string>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QPushButton" name="browseBinaryButton">
- <property name="toolTip">
- <string>Browse filesystem</string>
- </property>
- <property name="whatsThis">
- <string>Browse filesystem for the executable to run.</string>
- </property>
- <property name="text">
- <string>...</string>
- </property>
- </widget>
+ <item row="1" column="1">
+ <layout class="QHBoxLayout" name="horizontalLayout" stretch="1,0">
+ <item>
+ <widget class="QLineEdit" name="binaryEdit">
+ <property name="toolTip">
+ <string>Binary to run</string>
+ </property>
+ <property name="whatsThis">
+ <string>Binary to run</string>
+ </property>
+ </widget>
+ </item>
+ <item>
+ <widget class="QPushButton" name="browseBinaryButton">
+ <property name="toolTip">
+ <string>Browse filesystem</string>
+ </property>
+ <property name="whatsThis">
+ <string>Browse filesystem for the executable to run.</string>
+ </property>
+ <property name="text">
+ <string>...</string>
+ </property>
+ </widget>
+ </item>
+ </layout>
</item>
- </layout>
- </item>
- <item>
- <layout class="QHBoxLayout" name="horizontalLayout_6">
- <item>
+ <item row="2" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Start in</string>
</property>
</widget>
</item>
- <item>
- <widget class="QLineEdit" name="workingDirEdit"/>
- </item>
- <item>
- <widget class="QPushButton" name="browseDirButton">
- <property name="text">
- <string>...</string>
- </property>
- </widget>
+ <item row="2" column="1">
+ <layout class="QHBoxLayout" name="horizontalLayout_6" stretch="1,0">
+ <item>
+ <widget class="QLineEdit" name="workingDirEdit"/>
+ </item>
+ <item>
+ <widget class="QPushButton" name="browseDirButton">
+ <property name="text">
+ <string>...</string>
+ </property>
+ </widget>
+ </item>
+ </layout>
</item>
- </layout>
- </item>
- <item>
- <layout class="QHBoxLayout" name="horizontalLayout_3">
- <item>
+ <item row="3" column="0">
<widget class="QLabel" name="label_2">
<property name="text">
<string>Arguments</string>
</property>
</widget>
</item>
- <item>
+ <item row="3" column="1">
<widget class="QLineEdit" name="argumentsEdit">
<property name="toolTip">
<string>Arguments to pass to the application</string>
@@ -258,7 +321,7 @@ Right now the only case I know of where this needs to be overwritten is for the
<string>If this is enabled, the configured libraries will be automatically loaded when this executable is launched.</string>
</property>
<property name="text">
- <string>Force Load Libraries (*)</string>
+ <string>Force Load Libraries (Profile Specific)</string>
</property>
</widget>
</item>
@@ -295,51 +358,6 @@ Right now the only case I know of where this needs to be overwritten is for the
</widget>
</item>
<item>
- <widget class="QLabel" name="label_5">
- <property name="text">
- <string>(*) This setting is profile-specific</string>
- </property>
- </widget>
- </item>
- <item>
- <layout class="QHBoxLayout" name="horizontalLayout_2">
- <item>
- <widget class="QPushButton" name="addButton">
- <property name="toolTip">
- <string>Add an executable</string>
- </property>
- <property name="whatsThis">
- <string>Add an executable</string>
- </property>
- <property name="text">
- <string>Add</string>
- </property>
- <property name="icon">
- <iconset>
- <normaloff>:/new/guiresources/resources/list-add.png</normaloff>:/new/guiresources/resources/list-add.png</iconset>
- </property>
- </widget>
- </item>
- <item>
- <widget class="QPushButton" name="removeButton">
- <property name="toolTip">
- <string>Remove the selected executable</string>
- </property>
- <property name="whatsThis">
- <string>Remove the selected executable</string>
- </property>
- <property name="text">
- <string>Remove</string>
- </property>
- <property name="icon">
- <iconset>
- <normaloff>:/new/guiresources/resources/list-remove.png</normaloff>:/new/guiresources/resources/list-remove.png</iconset>
- </property>
- </widget>
- </item>
- </layout>
- </item>
- <item>
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
@@ -362,19 +380,17 @@ Right now the only case I know of where this needs to be overwritten is for the
<item>
<widget class="QDialogButtonBox" name="buttonBox">
<property name="standardButtons">
- <set>QDialogButtonBox::Close</set>
+ <set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
</property>
</widget>
</item>
</layout>
</widget>
<tabstops>
- <tabstop>titleEdit</tabstop>
<tabstop>binaryEdit</tabstop>
<tabstop>browseBinaryButton</tabstop>
<tabstop>workingDirEdit</tabstop>
<tabstop>browseDirButton</tabstop>
- <tabstop>argumentsEdit</tabstop>
<tabstop>overwriteAppIDBox</tabstop>
<tabstop>appIDOverwriteEdit</tabstop>
<tabstop>newFilesModCheckBox</tabstop>