diff options
author | Dirk Hohndel <dirk@hohndel.org> | 2017-07-17 05:32:29 -0700 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2017-07-17 07:32:29 -0700 |
commit | 2ccfce7cf062d2ef83d111e343bff4fbd67c1598 (patch) | |
tree | 7fb98e447753af4f8e27283a7af00d7b0a991c90 /subsurface-mobile-helper.cpp | |
parent | 40223c8a5fb921efdc237528c0aa9fff54899b35 (diff) | |
download | subsurface-2ccfce7cf062d2ef83d111e343bff4fbd67c1598.tar.gz |
QML UI: add serial interfaces to connection list
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'subsurface-mobile-helper.cpp')
-rw-r--r-- | subsurface-mobile-helper.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/subsurface-mobile-helper.cpp b/subsurface-mobile-helper.cpp index e84fd82d1..68dd228ba 100644 --- a/subsurface-mobile-helper.cpp +++ b/subsurface-mobile-helper.cpp @@ -75,6 +75,14 @@ void run_ui() ctxt->setContextProperty("diveModel", sortModel); ctxt->setContextProperty("gpsModel", gpsSortModel); ctxt->setContextProperty("vendorList", vendorList); +#if defined(Q_OS_ANDROID) + connectionListModel.addAddress("FTDI"); +#elif defined(Q_OS_LINUX) // since this is in the else, it does NOT include Android + connectionListModel.addAddress("/dev/ttyS0"); + connectionListModel.addAddress("/dev/ttyS1"); + connectionListModel.addAddress("/dev/ttyS2"); + connectionListModel.addAddress("/dev/ttyS3"); +#endif ctxt->setContextProperty("connectionListModel", &connectionListModel); ctxt->setContextProperty("logModel", MessageHandlerModel::self()); |