fixed #107 and added persistent configuration
This commit is contained in:
@@ -1,6 +1,8 @@
|
||||
#include "preferencesdialog.h"
|
||||
#include "ui_preferencesdialog.h"
|
||||
|
||||
#include "io/config.h"
|
||||
|
||||
#include <QMenuBar>
|
||||
#include <QAction>
|
||||
#include <QDebug>
|
||||
@@ -20,6 +22,8 @@ PreferencesDialog::PreferencesDialog(QWidget *parent) :
|
||||
ui(new Ui::PreferencesDialog)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
|
||||
ui->imgSeqFormatEdit->setText(config.img_seq_formats);
|
||||
}
|
||||
|
||||
PreferencesDialog::~PreferencesDialog() {
|
||||
@@ -69,3 +73,7 @@ void PreferencesDialog::setup_kbd_shortcuts(QMenuBar* menubar) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void PreferencesDialog::on_buttonBox_accepted() {
|
||||
config.img_seq_formats = ui->imgSeqFormatEdit->text();
|
||||
}
|
||||
|
||||
@@ -19,6 +19,9 @@ public:
|
||||
|
||||
void setup_kbd_shortcuts(QMenuBar* menu);
|
||||
|
||||
private slots:
|
||||
void on_buttonBox_accepted();
|
||||
|
||||
private:
|
||||
Ui::PreferencesDialog *ui;
|
||||
};
|
||||
|
||||
@@ -17,12 +17,24 @@
|
||||
<item>
|
||||
<widget class="QTabWidget" name="tabWidget">
|
||||
<property name="currentIndex">
|
||||
<number>2</number>
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="QWidget" name="tab">
|
||||
<attribute name="title">
|
||||
<string>General</string>
|
||||
</attribute>
|
||||
<layout class="QGridLayout" name="gridLayout_2">
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="text">
|
||||
<string>Image sequence formats:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QLineEdit" name="imgSeqFormatEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="tab_2">
|
||||
<attribute name="title">
|
||||
|
||||
Reference in New Issue
Block a user