diff options
author | Martin Pejcoch <martin.pejcoch@nokia.com> | 2011-04-07 10:10:24 +0200 |
---|---|---|
committer | Martin Pejcoch <martin.pejcoch@nokia.com> | 2011-04-07 10:10:24 +0200 |
commit | 3d5fac039b8c23ca883b0363b4c9990b639bfa24 (patch) | |
tree | 664c2d10cbdc569d7c059240b2c007f24f295870 | |
parent | 0910317d0f2ac6c4dbe527e1e66f720fcd92334f (diff) |
Use system locale for displaying double values
The double property manager used a hardcoded conversion to QString,
this doesn't match a localized conversion used by the spinbox editor,
when the value is being edited. Since there is no connection to a widget
to provide the application's locale the default system locale is used.
Reviewed-by: Andy Shaw
-rw-r--r-- | qtpropertybrowser/src/qtpropertymanager.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/qtpropertybrowser/src/qtpropertymanager.cpp b/qtpropertybrowser/src/qtpropertymanager.cpp index 6d805d6..a634e6d 100644 --- a/qtpropertybrowser/src/qtpropertymanager.cpp +++ b/qtpropertybrowser/src/qtpropertymanager.cpp @@ -1060,7 +1060,7 @@ QString QtDoublePropertyManager::valueText(const QtProperty *property) const const QtDoublePropertyManagerPrivate::PropertyValueMap::const_iterator it = d_ptr->m_values.constFind(property); if (it == d_ptr->m_values.constEnd()) return QString(); - return QString::number(it.value().val, 'f', it.value().decimals); + return QLocale::system().toString(it.value().val, 'f', it.value().decimals); } /*! |