diff widgets/PropertyBox.cpp @ 979:98827470ada2 3.0-integration

Merge from branch normalize_hybrid_option
author Chris Cannam
date Fri, 26 Jun 2015 14:13:31 +0100
parents 4a578a360011 1986c9b0d9c3
children 3f7cdfc56dce
line wrap: on
line diff
--- a/widgets/PropertyBox.cpp	Fri Jun 26 14:10:40 2015 +0100
+++ b/widgets/PropertyBox.cpp	Fri Jun 26 14:13:31 2015 +0100
@@ -443,7 +443,16 @@
             if (type == PropertyContainer::ValueProperty) {
 
                 for (int i = min; i <= max; ++i) {
-                    cb->addItem(m_container->getPropertyValueLabel(name, i));
+
+                    QString label = m_container->getPropertyValueLabel(name, i);
+                    QString iname = m_container->getPropertyValueIconName(name, i);
+
+                    if (iname != "") {
+                        QIcon icon(IconLoader().load(iname));
+                        cb->addItem(icon, label);
+                    } else {
+                        cb->addItem(label);
+                    }
                 }
 
             } else if (type == PropertyContainer::UnitsProperty) {