projects
/
pulseview.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
175d657
)
pv::prop::Enum: Do not create a widget if the initial value could not be retrieved
author
Joel Holdsworth
<joel@airwebreathe.org.uk>
Sat, 25 Jan 2014 11:13:33 +0000
(11:13 +0000)
committer
Bert Vermeulen
<bert@biot.com>
Sat, 25 Jan 2014 11:54:10 +0000
(12:54 +0100)
pv/prop/enum.cpp
patch
|
blob
|
history
diff --git
a/pv/prop/enum.cpp
b/pv/prop/enum.cpp
index d4a04cbb748ae066fb66cebe29b244eca52c6a8f..9044c6bae9d3c6335589c26e7be65835186a7b81 100644
(file)
--- a/
pv/prop/enum.cpp
+++ b/
pv/prop/enum.cpp
@@
-51,6
+51,8
@@
QWidget* Enum::get_widget(QWidget *parent, bool auto_commit)
return _selector;
GVariant *const value = _getter ? _getter() : NULL;
+ if (!value)
+ return NULL;
_selector = new QComboBox(parent);
for (unsigned int i = 0; i < _values.size(); i++) {