API review: DataContainer clearData()->removeAllData()

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=800558
This commit is contained in:
Anne-Marie Mahfouf 2008-04-24 11:56:32 +00:00
parent fb85325fe6
commit 75ba09738f
3 changed files with 4 additions and 4 deletions

View File

@ -57,7 +57,7 @@ void DataContainer::setData(const QString& key, const QVariant& value)
d->updateTs.start(); d->updateTs.start();
} }
void DataContainer::clearData() void DataContainer::removeAllData()
{ {
if (d->data.count() < 1) { if (d->data.count() < 1) {
// avoid an update if we don't have any data anyways // avoid an update if we don't have any data anyways

View File

@ -71,9 +71,9 @@ class PLASMA_EXPORT DataContainer : public QObject
void setData(const QString& key, const QVariant& value); void setData(const QString& key, const QVariant& value);
/** /**
* Clears all data currently associated with this source * Removes all data currently associated with this source
**/ **/
void clearData(); void removeAllData();
/** /**
* Checks for whether the data has changed and therefore an update * Checks for whether the data has changed and therefore an update

View File

@ -391,7 +391,7 @@ void DataEngine::removeAllData(const QString& source)
{ {
DataContainer* s = d->source(source, false); DataContainer* s = d->source(source, false);
if (s) { if (s) {
s->clearData(); s->removeAllData();
d->queueUpdate(); d->queueUpdate();
} }
} }