From ae4caf4a5a2fc9eac1c9c58391dba3bfb76ac5b3 Mon Sep 17 00:00:00 2001 From: "Aaron J. Seigo" Date: Wed, 19 May 2010 20:04:21 +0000 Subject: [PATCH] missing method svn path=/trunk/KDE/kdelibs/; revision=1128639 --- scripting/dataenginescript.cpp | 7 +++++++ scripting/dataenginescript.h | 9 +++++++++ 2 files changed, 16 insertions(+) diff --git a/scripting/dataenginescript.cpp b/scripting/dataenginescript.cpp index 2297ffeb1..616dd202d 100644 --- a/scripting/dataenginescript.cpp +++ b/scripting/dataenginescript.cpp @@ -109,6 +109,13 @@ void DataEngineScript::setData(const QString &source, const QVariant &value) } } +void DataEngineScript::setData(const QString &source, const DataEngine::Data &values) +{ + if (d->dataEngine) { + d->dataEngine->setData(source, values); + } +} + void DataEngineScript::removeAllData(const QString &source) { if (d->dataEngine) { diff --git a/scripting/dataenginescript.h b/scripting/dataenginescript.h index edb05c972..b5ed3ec45 100644 --- a/scripting/dataenginescript.h +++ b/scripting/dataenginescript.h @@ -119,6 +119,15 @@ protected: void setData(const QString &source, const QString &key, const QVariant &value); void setData(const QString &source, const QVariant &value); + + /** + * Adds a set of values to a source + * @param source the name of the source to set the data on + * @values a key/value collection to add to the source + * @since 4.5 + */ + void setData(const QString &source, const DataEngine::Data &values); + void removeAllData(const QString &source); void removeData(const QString &source, const QString &key); void setMaxSourceCount(uint limit);