summaryrefslogtreecommitdiffstats
path: root/qt-ui
diff options
context:
space:
mode:
authorGravatar Gehad elrobey <gehadelrobey@gmail.com>2014-08-10 07:10:19 +0300
committerGravatar Dirk Hohndel <dirk@hohndel.org>2014-08-11 08:21:13 -0700
commit10e70336c6fc45028c8b25dae99edaeb7b596137 (patch)
treeefbc2688a95201a864cc65bc6e6105ed34d069be /qt-ui
parenta16c2db78da6707f15079612740f9bf9b07b5990 (diff)
downloadsubsurface-10e70336c6fc45028c8b25dae99edaeb7b596137.tar.gz
HTML: Remember General Export Settings.
Set Default values and remember user selected general HTML export settings. Signed-off-by: Gehad elrobey <gehadelrobey@gmail.com> Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui')
-rw-r--r--qt-ui/divelogexportdialog.cpp12
-rw-r--r--qt-ui/divelogexportdialog.ui6
2 files changed, 18 insertions, 0 deletions
diff --git a/qt-ui/divelogexportdialog.cpp b/qt-ui/divelogexportdialog.cpp
index 9156f17ac..f3f32949f 100644
--- a/qt-ui/divelogexportdialog.cpp
+++ b/qt-ui/divelogexportdialog.cpp
@@ -45,6 +45,15 @@ DiveLogExportDialog::DiveLogExportDialog(QWidget *parent) : QDialog(parent),
if (settings.contains("themeSelection")) {
ui->themeSelection->setCurrentIndex(settings.value("themeSelection").toInt());
}
+ if (settings.contains("subsurfaceNumbers")) {
+ ui->exportSubsurfaceNumber->setChecked(settings.value("subsurfaceNumbers").toBool());
+ }
+ if (settings.contains("yearlyStatistics")) {
+ ui->exportStatistics->setChecked(settings.value("yearlyStatistics").toBool());
+ }
+ if (settings.contains("listOnly")) {
+ ui->exportListOnly->setChecked(settings.value("listOnly").toBool());
+ }
settings.endGroup();
}
@@ -122,6 +131,9 @@ void DiveLogExportDialog::exportHTMLsettings(const QString &filename)
settings.setValue("fontSelection", ui->fontSelection->currentIndex());
settings.setValue("fontSizeSelection", ui->fontSizeSelection->currentIndex());
settings.setValue("themeSelection", ui->themeSelection->currentIndex());
+ settings.setValue("subsurfaceNumbers", ui->exportSubsurfaceNumber->isChecked());
+ settings.setValue("yearlyStatistics", ui->exportStatistics->isChecked());
+ settings.setValue("listOnly", ui->exportListOnly->isChecked());
settings.endGroup();
QString fontSize = ui->fontSizeSelection->currentText();
diff --git a/qt-ui/divelogexportdialog.ui b/qt-ui/divelogexportdialog.ui
index 0e8ef4a42..ce1513efb 100644
--- a/qt-ui/divelogexportdialog.ui
+++ b/qt-ui/divelogexportdialog.ui
@@ -194,6 +194,9 @@
<property name="text">
<string>Subsurface numbers</string>
</property>
+ <property name="checked">
+ <bool>true</bool>
+ </property>
</widget>
</item>
<item row="0" column="1">
@@ -220,6 +223,9 @@
<property name="text">
<string>Export Yearly Statistics</string>
</property>
+ <property name="checked">
+ <bool>true</bool>
+ </property>
</widget>
</item>
<item row="1" column="1">