GUI: Improve edit application setttings dialog.
Make the editor application settings dialog to look similar than include paths dialog. Move buttons right to the list, not below. And remove unnecessary "application" word from button texts. Rename Modify-button to Edit-button since we are not modifying the application but editing its info. Similarly rename Delete- button to Remove-button since we are not deleting the application but removing from the list.
This commit is contained in:
parent
dd717427e1
commit
b7aa14f0e8
|
@ -17,7 +17,7 @@
|
|||
<item>
|
||||
<widget class="QTabWidget" name="tabWidget">
|
||||
<property name="currentIndex">
|
||||
<number>1</number>
|
||||
<number>2</number>
|
||||
</property>
|
||||
<widget class="QWidget" name="tab">
|
||||
<attribute name="title">
|
||||
|
@ -225,38 +225,59 @@
|
|||
<attribute name="title">
|
||||
<string>Applications</string>
|
||||
</attribute>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||
<item>
|
||||
<widget class="QListWidget" name="mListWidget"/>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="mButtonAdd">
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<item>
|
||||
<widget class="QPushButton" name="mBtnAddApplication">
|
||||
<property name="text">
|
||||
<string>Add application</string>
|
||||
<string>Add...</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="mButtonDelete">
|
||||
<widget class="QPushButton" name="mBtnEditApplication">
|
||||
<property name="text">
|
||||
<string>Delete application</string>
|
||||
<string>Edit...</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="mButtonModify">
|
||||
<widget class="QPushButton" name="mBtnRemoveApplication">
|
||||
<property name="text">
|
||||
<string>Modify application</string>
|
||||
<string>Remove</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="mButtonDefault">
|
||||
<widget class="QPushButton" name="mBtnDefaultApplication">
|
||||
<property name="text">
|
||||
<string>Set as default application</string>
|
||||
<string>Set as default</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="verticalSpacer_4">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="tab_3">
|
||||
|
@ -329,10 +350,9 @@
|
|||
<tabstop>mShowNoErrorsMessage</tabstop>
|
||||
<tabstop>mShowDebugWarnings</tabstop>
|
||||
<tabstop>mListWidget</tabstop>
|
||||
<tabstop>mButtonAdd</tabstop>
|
||||
<tabstop>mButtonDelete</tabstop>
|
||||
<tabstop>mButtonModify</tabstop>
|
||||
<tabstop>mButtonDefault</tabstop>
|
||||
<tabstop>mBtnAddApplication</tabstop>
|
||||
<tabstop>mBtnEditApplication</tabstop>
|
||||
<tabstop>mBtnDefaultApplication</tabstop>
|
||||
<tabstop>mSaveAllErrors</tabstop>
|
||||
<tabstop>mSaveFullPath</tabstop>
|
||||
<tabstop>mButtons</tabstop>
|
||||
|
|
|
@ -57,16 +57,16 @@ SettingsDialog::SettingsDialog(QSettings *programSettings,
|
|||
|
||||
connect(mUI.mButtons, SIGNAL(accepted()), this, SLOT(Ok()));
|
||||
connect(mUI.mButtons, SIGNAL(rejected()), this, SLOT(reject()));
|
||||
connect(mUI.mButtonAdd, SIGNAL(clicked()),
|
||||
connect(mUI.mBtnAddApplication, SIGNAL(clicked()),
|
||||
this, SLOT(AddApplication()));
|
||||
connect(mUI.mButtonDelete, SIGNAL(clicked()),
|
||||
this, SLOT(DeleteApplication()));
|
||||
connect(mUI.mButtonModify, SIGNAL(clicked()),
|
||||
this, SLOT(ModifyApplication()));
|
||||
connect(mUI.mButtonDefault, SIGNAL(clicked()),
|
||||
connect(mUI.mBtnRemoveApplication, SIGNAL(clicked()),
|
||||
this, SLOT(RemoveApplication()));
|
||||
connect(mUI.mBtnEditApplication, SIGNAL(clicked()),
|
||||
this, SLOT(EditApplication()));
|
||||
connect(mUI.mBtnDefaultApplication, SIGNAL(clicked()),
|
||||
this, SLOT(DefaultApplication()));
|
||||
connect(mUI.mListWidget, SIGNAL(itemDoubleClicked(QListWidgetItem *)),
|
||||
this, SLOT(ModifyApplication()));
|
||||
this, SLOT(EditApplication()));
|
||||
connect(mUI.mBtnAddIncludePath, SIGNAL(clicked()),
|
||||
this, SLOT(AddIncludePath()));
|
||||
connect(mUI.mBtnRemoveIncludePath, SIGNAL(clicked()),
|
||||
|
@ -207,7 +207,7 @@ void SettingsDialog::AddApplication()
|
|||
}
|
||||
}
|
||||
|
||||
void SettingsDialog::DeleteApplication()
|
||||
void SettingsDialog::RemoveApplication()
|
||||
{
|
||||
|
||||
QList<QListWidgetItem *> selected = mUI.mListWidget->selectedItems();
|
||||
|
@ -221,7 +221,7 @@ void SettingsDialog::DeleteApplication()
|
|||
}
|
||||
}
|
||||
|
||||
void SettingsDialog::ModifyApplication()
|
||||
void SettingsDialog::EditApplication()
|
||||
{
|
||||
QList<QListWidgetItem *> selected = mUI.mListWidget->selectedItems();
|
||||
QListWidgetItem *item = 0;
|
||||
|
|
|
@ -98,13 +98,13 @@ protected slots:
|
|||
* @brief Slot for deleting an application from the list
|
||||
*
|
||||
*/
|
||||
void DeleteApplication();
|
||||
void RemoveApplication();
|
||||
|
||||
/**
|
||||
* @brief Slot for modifying an application in the list
|
||||
*
|
||||
*/
|
||||
void ModifyApplication();
|
||||
void EditApplication();
|
||||
|
||||
/**
|
||||
* @brief Slot for making the selected application as the default (first)
|
||||
|
|
Loading…
Reference in New Issue