aboutsummaryrefslogtreecommitdiffstats
path: root/ui/qt
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2022-10-07 16:30:26 -0700
committerGerald Combs <gerald@wireshark.org>2022-10-09 00:44:27 +0000
commita820b439b492fd0896a56ed5e64c1b9ae03eca6c (patch)
tree90708ae1db58a1a0402b748b56e5f3f3d931c5fc /ui/qt
parent80656552c77fad38cfbc1e2076187d7e869a985d (diff)
Qt+extcap: editselect value fixups.
Fix our value handling.
Diffstat (limited to 'ui/qt')
-rw-r--r--ui/qt/extcap_argument.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/ui/qt/extcap_argument.cpp b/ui/qt/extcap_argument.cpp
index c598120981..16b3c12dad 100644
--- a/ui/qt/extcap_argument.cpp
+++ b/ui/qt/extcap_argument.cpp
@@ -282,6 +282,10 @@ QString ExtArgEditSelector::value()
return QString();
}
+ if (boxSelection->currentIndex() > -1) {
+ return ExtArgSelector::value();
+ }
+
return boxSelection->currentText();
}
@@ -298,12 +302,11 @@ void ExtArgEditSelector::setDefaultValue()
QVariant data = boxSelection->currentData();
if (data.toString() != stored) {
- // Apparently createEditor hasn't been called at this point.
+ // createEditor may not have been called at this point?
boxSelection->setEditable(true);
boxSelection->setInsertPolicy(QComboBox::NoInsert);
boxSelection->setEditText(stored);
}
-
}