dataenginemanager api review: (un)load()->(un)loadEngine()
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=800275
This commit is contained in:
parent
276c7aaa66
commit
afc9290365
@ -130,7 +130,7 @@ public:
|
||||
~Private()
|
||||
{
|
||||
foreach ( const QString& engine, loadedEngines ) {
|
||||
DataEngineManager::self()->unload( engine );
|
||||
DataEngineManager::self()->unloadEngine( engine );
|
||||
}
|
||||
delete background;
|
||||
delete package;
|
||||
@ -566,7 +566,7 @@ DataEngine* Applet::dataEngine(const QString& name) const
|
||||
return DataEngineManager::self()->engine(name);
|
||||
}
|
||||
|
||||
DataEngine* engine = DataEngineManager::self()->load(name);
|
||||
DataEngine* engine = DataEngineManager::self()->loadEngine(name);
|
||||
if (engine->isValid()) {
|
||||
d->loadedEngines.append(name);
|
||||
}
|
||||
|
@ -104,7 +104,7 @@ Plasma::DataEngine* DataEngineManager::engine(const QString& name) const
|
||||
return d->nullEngine();
|
||||
}
|
||||
|
||||
Plasma::DataEngine* DataEngineManager::load(const QString& name)
|
||||
Plasma::DataEngine* DataEngineManager::loadEngine(const QString& name)
|
||||
{
|
||||
Plasma::DataEngine* engine = 0;
|
||||
Plasma::DataEngine::Dict::const_iterator it = d->engines.find(name);
|
||||
@ -144,7 +144,7 @@ Plasma::DataEngine* DataEngineManager::load(const QString& name)
|
||||
return engine;
|
||||
}
|
||||
|
||||
void DataEngineManager::unload(const QString& name)
|
||||
void DataEngineManager::unloadEngine(const QString& name)
|
||||
{
|
||||
Plasma::DataEngine::Dict::iterator it = d->engines.find(name);
|
||||
|
||||
|
@ -66,13 +66,13 @@ class PLASMA_EXPORT DataEngineManager: public QObject
|
||||
* @param name the name of the engine
|
||||
* @return the data engine that was loaded, or the NullEngine on failure.
|
||||
*/
|
||||
Plasma::DataEngine* load(const QString& name);
|
||||
Plasma::DataEngine* loadEngine(const QString& name);
|
||||
|
||||
/**
|
||||
* Decreases the reference count on the engine. If the count reaches
|
||||
* zero, then the engine is deleted to save resources.
|
||||
*/
|
||||
void unload(const QString& name);
|
||||
void unloadEngine(const QString& name);
|
||||
|
||||
/**
|
||||
* Returns a listing of all known engines by name
|
||||
|
Loading…
Reference in New Issue
Block a user