summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAmaury Pouly <amaury.pouly@gmail.com>2015-10-03 23:09:35 +0200
committerAmaury Pouly <amaury.pouly@gmail.com>2015-10-03 23:09:35 +0200
commit3fdb86ea417cae94a7f7df4475989843e644acdc (patch)
tree41bcd68c0691feb653043931ee6f1556e3bd905c
parentf01fb3ca594933b6c193ee4bb23fcfbcfc72d9c8 (diff)
downloadrockbox-3fdb86ea417cae94a7f7df4475989843e644acdc.tar.gz
rockbox-3fdb86ea417cae94a7f7df4475989843e644acdc.tar.bz2
rockbox-3fdb86ea417cae94a7f7df4475989843e644acdc.zip
qeditor: fix uninitialised variable
Change-Id: I12a785e554b7d598b91e526af1b7ebc1fc44f610
-rw-r--r--utils/regtools/qeditor/utils.cpp6
-rw-r--r--utils/regtools/qeditor/utils.h2
2 files changed, 7 insertions, 1 deletions
diff --git a/utils/regtools/qeditor/utils.cpp b/utils/regtools/qeditor/utils.cpp
index 2ee1bc6db5..95b5a80c64 100644
--- a/utils/regtools/qeditor/utils.cpp
+++ b/utils/regtools/qeditor/utils.cpp
@@ -364,6 +364,12 @@ SocFieldCachedValue::SocFieldCachedValue(const soc_reg_field_t& field, uint valu
* SocFieldCachedItemDelegate
*/
+SocFieldCachedItemDelegate::SocFieldCachedItemDelegate(QObject *parent)
+ :QStyledItemDelegate(parent)
+{
+ m_mode = DisplayValueAndName;
+}
+
QString SocFieldCachedItemDelegate::displayText(const QVariant& value, const QLocale& locale) const
{
// FIXME see QTBUG-30392
diff --git a/utils/regtools/qeditor/utils.h b/utils/regtools/qeditor/utils.h
index 078f3a85d7..f3dbd15a22 100644
--- a/utils/regtools/qeditor/utils.h
+++ b/utils/regtools/qeditor/utils.h
@@ -193,7 +193,7 @@ public:
DisplayValue, /* "value" */
};
- SocFieldCachedItemDelegate(QObject *parent = 0):QStyledItemDelegate(parent) {}
+ SocFieldCachedItemDelegate(QObject *parent = 0);
virtual QString displayText(const QVariant& value, const QLocale& locale) const;
void SetMode(DisplayMode mode) { m_mode = mode; }
DisplayMode GetMode() const { return m_mode; }