diff options
author | Tomaz Canabrava <tcanabrava@kde.org> | 2017-05-12 18:17:23 +0200 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2017-05-27 11:07:19 -0700 |
commit | f78fdf3d0fea3a426f07f24d0ce2d98a1cae0bf0 (patch) | |
tree | 362fe28654f0449da6931b8031238821d05087ea | |
parent | 9951592216366edf181ebf94355fe445fd74b87a (diff) | |
download | subsurface-f78fdf3d0fea3a426f07f24d0ce2d98a1cae0bf0.tar.gz |
QML UI: show the VendorList on the Download from DC
Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
-rw-r--r-- | mobile-widgets/qml/DownloadFromDiveComputer.qml | 6 | ||||
-rw-r--r-- | subsurface-mobile-helper.cpp | 3 |
2 files changed, 8 insertions, 1 deletions
diff --git a/mobile-widgets/qml/DownloadFromDiveComputer.qml b/mobile-widgets/qml/DownloadFromDiveComputer.qml index a5ccb9b6f..5788ab571 100644 --- a/mobile-widgets/qml/DownloadFromDiveComputer.qml +++ b/mobile-widgets/qml/DownloadFromDiveComputer.qml @@ -35,7 +35,11 @@ Kirigami.Page { Layout.fillWidth: true GridLayout { columns: 2 - Kirigami.Label { text: qsTr(" Vendor name: ") } ComboBox { Layout.fillWidth: true } + Kirigami.Label { text: qsTr(" Vendor name: ") } + ComboBox { + Layout.fillWidth: true + model: vendorList + } Kirigami.Label { text: qsTr(" Dive Computer:") } ComboBox { Layout.fillWidth: true } } diff --git a/subsurface-mobile-helper.cpp b/subsurface-mobile-helper.cpp index faaa31667..4d960181c 100644 --- a/subsurface-mobile-helper.cpp +++ b/subsurface-mobile-helper.cpp @@ -21,6 +21,7 @@ #include "qt-models/divelistmodel.h" #include "qt-models/gpslistmodel.h" #include "mobile-widgets/qmlprofile.h" +#include "core/downloadfromdcthread.h" #include "mobile-widgets/qml/kirigami/src/kirigamiplugin.h" @@ -67,6 +68,8 @@ void run_ui() QQmlContext *ctxt = engine.rootContext(); ctxt->setContextProperty("diveModel", sortModel); ctxt->setContextProperty("gpsModel", gpsSortModel); + ctxt->setContextProperty("vendorList", vendorList); + engine.load(QUrl(QStringLiteral("qrc:///qml/main.qml"))); qqWindowObject = engine.rootObjects().value(0); if (!qqWindowObject) { |