Commit 7dc069c8 authored by Don Gagne's avatar Don Gagne

Combo box showing incorrect value

parent f9874376
...@@ -100,13 +100,15 @@ QGCViewDialog { ...@@ -100,13 +100,15 @@ QGCViewDialog {
QGCComboBox { QGCComboBox {
id: factCombo id: factCombo
width: valueField.width width: valueField.width
visible: fact.enumStrings.length != 0 && !validate visible: _showCombo
model: fact.enumStrings model: fact.enumStrings
property bool _showCombo: fact.enumStrings.length != 0 && !validate
Component.onCompleted: { Component.onCompleted: {
// We can't bind directly to fact.enumIndex since that would add an unknown value // We can't bind directly to fact.enumIndex since that would add an unknown value
// if there are no enum strings. // if there are no enum strings.
if (visible) { if (_showCombo) {
currentIndex = fact.enumIndex currentIndex = fact.enumIndex
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment