diff options
Diffstat (limited to 'src/imports/settings/qqmlsettings.cpp')
-rw-r--r-- | src/imports/settings/qqmlsettings.cpp | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/imports/settings/qqmlsettings.cpp b/src/imports/settings/qqmlsettings.cpp index f7a7d8b055..287a70363a 100644 --- a/src/imports/settings/qqmlsettings.cpp +++ b/src/imports/settings/qqmlsettings.cpp @@ -487,6 +487,25 @@ void QQmlSettings::setValue(const QString &key, const QVariant &value) qCDebug(lcSettings) << "QQmlSettings: setValue" << key << ":" << value; } +/*! + \qmlmethod Settings::sync() + + Writes any unsaved changes to permanent storage, and reloads any + settings that have been changed in the meantime by another + application. + + This function is called automatically from QSettings's destructor and + by the event loop at regular intervals, so you normally don't need to + call it yourself. + + \sa QSettings::sync +*/ +void QQmlSettings::sync() +{ + Q_D(QQmlSettings); + d->instance()->sync(); +} + void QQmlSettings::classBegin() { } |