Changeset 695be28 in subsurface


Ignore:
Timestamp:
Jul 17, 2017, 7:36:44 AM (3 days ago)
Author:
Dirk Hohndel <dirk@…>
Branches:
master
Children:
c7e28436
Parents:
ec1b22b
git-author:
Dirk Hohndel <dirk@…> (07/17/17 06:36:44)
git-committer:
Dirk Hohndel <dirk@…> (07/17/17 07:36:44)
Message:

QML UI: automatically set the Bluetooth checkbox

I wonder if we even need this anymore at all as the connection
clearly determines whether this is a BT download or not.

Signed-off-by: Dirk Hohndel <dirk@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • mobile-widgets/qml/DownloadFromDiveComputer.qml

    rec1b22b r695be28  
    9999                                model: connectionListModel
    100100                                currentIndex: -1
     101                                onCurrentTextChanged: {
     102                                        // pattern that matches BT addresses
     103                                        var btAddr = /[0-9A-Fa-f][0-9A-Fa-f]:[0-9A-Fa-f][0-9A-Fa-f]:[0-9A-Fa-f][0-9A-Fa-f]:[0-9A-Fa-f][0-9A-Fa-f]:[0-9A-Fa-f][0-9A-Fa-f]:[0-9A-Fa-f][0-9A-Fa-f]/ ;
     104                                        if (btAddr.test(currentText))
     105                                                isBluetooth.checked = true
     106                                        else
     107                                                isBluetooth.checked = false
     108                                }
    101109                        }
    102110
Note: See TracChangeset for help on using the changeset viewer.