diff options
author | Simon Hausmann <simon.hausmann@theqtcompany.com> | 2015-04-28 10:57:34 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@theqtcompany.com> | 2015-04-28 14:29:59 +0200 |
commit | 94db5de2acefb6e96d4f6cfda2df14905a5e63c5 (patch) | |
tree | c361f5dd4989ee0743e2a9f94b64dbb2127e5dea /src/imports | |
parent | 11f67b80c4eab4b1e3eb8e6b1e8b69e7a60e42a9 (diff) | |
parent | dee67b41b031791c7b6313e935e622ef8d594686 (diff) |
Merge remote-tracking branch 'origin/5.5' into dev
Conflicts:
tests/auto/quick/qquicktext/tst_qquicktext.cpp
Change-Id: I075e742da8396a268d97d3ab34bcd9e0c0cf001f
Diffstat (limited to 'src/imports')
-rw-r--r-- | src/imports/models/models.pro | 2 | ||||
-rw-r--r-- | src/imports/models/plugin.cpp | 4 | ||||
-rw-r--r-- | src/imports/settings/qqmlsettings.cpp | 17 |
3 files changed, 11 insertions, 12 deletions
diff --git a/src/imports/models/models.pro b/src/imports/models/models.pro index 98b0bd617a..6a2952cd82 100644 --- a/src/imports/models/models.pro +++ b/src/imports/models/models.pro @@ -1,7 +1,7 @@ CXX_MODULE = qml TARGET = modelsplugin TARGETPATH = QtQml/Models.2 -IMPORT_VERSION = 2.1 +IMPORT_VERSION = 2.2 SOURCES += \ plugin.cpp diff --git a/src/imports/models/plugin.cpp b/src/imports/models/plugin.cpp index f9999a2223..c2b0d2ae94 100644 --- a/src/imports/models/plugin.cpp +++ b/src/imports/models/plugin.cpp @@ -38,7 +38,7 @@ QT_BEGIN_NAMESPACE /*! - \qmlmodule QtQml.Models 2.1 + \qmlmodule QtQml.Models 2.2 \title Qt QML Models QML Types \ingroup qmlmodules \brief Provides QML types for data models @@ -49,7 +49,7 @@ QT_BEGIN_NAMESPACE To use the types in this module, import the module with the following line: \code - import QtQml.Models 2.1 + import QtQml.Models 2.2 \endcode Note that QtQml.Models module started at version 2.1 to match the version diff --git a/src/imports/settings/qqmlsettings.cpp b/src/imports/settings/qqmlsettings.cpp index e51d6bb148..954161b60b 100644 --- a/src/imports/settings/qqmlsettings.cpp +++ b/src/imports/settings/qqmlsettings.cpp @@ -315,14 +315,15 @@ void QQmlSettingsPrivate::load() void QQmlSettingsPrivate::store() { - QHash<const char *, QVariant>::iterator it = changedProperties.begin(); - while (it != changedProperties.end()) { + QHash<const char *, QVariant>::const_iterator it = changedProperties.constBegin(); + while (it != changedProperties.constEnd()) { instance()->setValue(it.key(), it.value()); #ifdef SETTINGS_DEBUG qDebug() << "QQmlSettings: store" << it.key() << ":" << it.value(); #endif - it = changedProperties.erase(it); + ++it; } + changedProperties.clear(); } void QQmlSettingsPrivate::_q_propertyChanged() @@ -394,12 +395,10 @@ void QQmlSettings::timerEvent(QTimerEvent *event) { Q_D(QQmlSettings); if (event->timerId() == d->timerId) { - if (d->changedProperties.isEmpty()) { - killTimer(d->timerId); - d->timerId = 0; - } else { - d->store(); - } + killTimer(d->timerId); + d->timerId = 0; + + d->store(); } QObject::timerEvent(event); } |