aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--qt-ui/divelogexportdialog.cpp16
-rw-r--r--qt-ui/divelogexportdialog.h2
-rw-r--r--qt-ui/divelogexportdialog.ui50
3 files changed, 65 insertions, 3 deletions
diff --git a/qt-ui/divelogexportdialog.cpp b/qt-ui/divelogexportdialog.cpp
index 7f77cef2f..94b9c9fc9 100644
--- a/qt-ui/divelogexportdialog.cpp
+++ b/qt-ui/divelogexportdialog.cpp
@@ -1,6 +1,9 @@
#include <QFileDialog>
#include <QString>
#include <QShortcut>
+#include <QAbstractButton>
+#include <QDebug>
+#include <QButtonGroup>
#include "mainwindow.h"
#include "divelogexportdialog.h"
@@ -23,6 +26,19 @@ DiveLogExportDialog::~DiveLogExportDialog()
delete ui;
}
+void DiveLogExportDialog::on_exportGroup_buttonClicked(QAbstractButton *button)
+{
+ if (ui->exportUDDF->isChecked()) {
+ ui->description->setText("UDDF is a generic format that enables communication among many dive computers and computer programs");
+ } else if (ui->exportCSV->isChecked()) {
+ ui->description->setText("CSV format, that includes the most critical information of the dive profile.");
+ } else if (ui->exportDivelogs->isChecked()) {
+ ui->description->setText("Subsurface XML format. This is the native format used by Subsurface.");
+ } else if (ui->exportWorldMap->isChecked()) {
+ ui->description->setText("Export the currently open dive logbook locations in HTML format and draw these on a world map.");
+ }
+}
+
void DiveLogExportDialog::on_buttonBox_accepted()
{
QFileInfo fi(system_default_filename());
diff --git a/qt-ui/divelogexportdialog.h b/qt-ui/divelogexportdialog.h
index 998df4971..8020b481c 100644
--- a/qt-ui/divelogexportdialog.h
+++ b/qt-ui/divelogexportdialog.h
@@ -2,6 +2,7 @@
#define DIVELOGEXPORTDIALOG_H
#include <QDialog>
+#include <QAbstractButton>
namespace Ui {
class DiveLogExportDialog;
@@ -17,6 +18,7 @@ public:
private
slots:
void on_buttonBox_accepted();
+ void on_exportGroup_buttonClicked(QAbstractButton *);
private:
Ui::DiveLogExportDialog *ui;
diff --git a/qt-ui/divelogexportdialog.ui b/qt-ui/divelogexportdialog.ui
index 38e23932b..e5dc77083 100644
--- a/qt-ui/divelogexportdialog.ui
+++ b/qt-ui/divelogexportdialog.ui
@@ -7,7 +7,7 @@
<x>0</x>
<y>0</y>
<width>400</width>
- <height>300</height>
+ <height>419</height>
</rect>
</property>
<property name="windowTitle">
@@ -16,8 +16,8 @@
<widget class="QDialogButtonBox" name="buttonBox">
<property name="geometry">
<rect>
- <x>30</x>
- <y>240</y>
+ <x>20</x>
+ <y>360</y>
<width>341</width>
<height>32</height>
</rect>
@@ -83,6 +83,9 @@
<property name="checked">
<bool>true</bool>
</property>
+ <attribute name="buttonGroup">
+ <string notr="true">exportGroup</string>
+ </attribute>
</widget>
<widget class="QRadioButton" name="exportDivelogs">
<property name="geometry">
@@ -96,6 +99,9 @@
<property name="text">
<string>divelogs</string>
</property>
+ <attribute name="buttonGroup">
+ <string notr="true">exportGroup</string>
+ </attribute>
</widget>
<widget class="QRadioButton" name="exportCSV">
<property name="geometry">
@@ -109,6 +115,9 @@
<property name="text">
<string>CSV</string>
</property>
+ <attribute name="buttonGroup">
+ <string notr="true">exportGroup</string>
+ </attribute>
</widget>
<widget class="QRadioButton" name="exportWorldMap">
<property name="geometry">
@@ -122,6 +131,9 @@
<property name="text">
<string>Worldmap</string>
</property>
+ <attribute name="buttonGroup">
+ <string notr="true">exportGroup</string>
+ </attribute>
</widget>
</widget>
<widget class="QGroupBox" name="exportSelection">
@@ -169,6 +181,35 @@
</property>
</widget>
</widget>
+ <widget class="Line" name="line">
+ <property name="geometry">
+ <rect>
+ <x>60</x>
+ <y>240</y>
+ <width>231</width>
+ <height>16</height>
+ </rect>
+ </property>
+ <property name="orientation">
+ <enum>Qt::Horizontal</enum>
+ </property>
+ </widget>
+ <widget class="QLabel" name="description">
+ <property name="geometry">
+ <rect>
+ <x>40</x>
+ <y>270</y>
+ <width>271</width>
+ <height>71</height>
+ </rect>
+ </property>
+ <property name="text">
+ <string/>
+ </property>
+ <property name="wordWrap">
+ <bool>true</bool>
+ </property>
+ </widget>
</widget>
<resources/>
<connections>
@@ -205,4 +246,7 @@
</hints>
</connection>
</connections>
+ <buttongroups>
+ <buttongroup name="exportGroup"/>
+ </buttongroups>
</ui>