diff options
author | J-P Nurmi <jpnurmi@theqtcompany.com> | 2015-09-24 16:03:54 +0200 |
---|---|---|
committer | J-P Nurmi <jpnurmi@theqtcompany.com> | 2015-09-24 15:28:18 +0000 |
commit | 7d0ab32ffb5eba1e81032cae3a43750549fb7813 (patch) | |
tree | bd815f17e3aaa6374c1ed4d19605f9946249a258 /src/imports/calendar/qquickdayofweekmodel.cpp | |
parent | 8f1d88448bc8756aac54cfcd7003f0a6c65ff4c7 (diff) |
Fix QQuickDayOfWeekModel::setLocale()
It must emit dataChanged() even if the first day of week of the new
and old locales are the same. The names are most likely different.
Change-Id: I932215821962910ef1fb8a66f2dab81dcc51a3b1
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
Diffstat (limited to 'src/imports/calendar/qquickdayofweekmodel.cpp')
-rw-r--r-- | src/imports/calendar/qquickdayofweekmodel.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/imports/calendar/qquickdayofweekmodel.cpp b/src/imports/calendar/qquickdayofweekmodel.cpp index 7f75f784..11a9bc3e 100644 --- a/src/imports/calendar/qquickdayofweekmodel.cpp +++ b/src/imports/calendar/qquickdayofweekmodel.cpp @@ -63,11 +63,9 @@ void QQuickDayOfWeekModel::setLocale(const QLocale &locale) { Q_D(QQuickDayOfWeekModel); if (d->locale != locale) { - bool changed = d->locale.firstDayOfWeek() != locale.firstDayOfWeek(); d->locale = locale; emit localeChanged(); - if (changed) - emit dataChanged(index(0, 0), index(6, 0)); + emit dataChanged(index(0, 0), index(6, 0)); } } |