Changeset ec1b22b in subsurface


Ignore:
Timestamp:
Jul 17, 2017, 7:35:22 AM (3 days ago)
Author:
Dirk Hohndel <dirk@…>
Branches:
master
Children:
695be28
Parents:
2ccfce7
git-author:
Dirk Hohndel <dirk@…> (07/17/17 06:06:22)
git-committer:
Dirk Hohndel <dirk@…> (07/17/17 07:35:22)
Message:

QML UI: only change connection when finding a match

If we can't find a match, just leave it unchanged. This way, if we
mis-recognize a device, the user can correct the product (or even
vendor) without losing the correct connection.

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

File:
1 edited

Legend:

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

    r40223c8 rec1b22b  
    8484                                currentIndex: productidx
    8585                                onCurrentTextChanged: {
    86                                         comboConnection.currentIndex = downloadThread.data().getMatchingAddress(comboVendor.currentText, currentText)
     86                                        var newIdx = downloadThread.data().getMatchingAddress(comboVendor.currentText, currentText)
     87                                        if (newIdx != -1)
     88                                                comboConnection.currentIndex = newIdx
    8789                                }
    8890
Note: See TracChangeset for help on using the changeset viewer.