load* -> load .. simpler, less verbose API

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=779407
This commit is contained in:
Aaron J. Seigo 2008-02-26 01:58:55 +00:00
parent fd705735ca
commit 7cf7109266
6 changed files with 10 additions and 10 deletions

View File

@ -228,7 +228,7 @@ void AbstractRunner::init()
}
}
AbstractRunner::List AbstractRunner::loadRunners(QObject* parent, const QStringList& whitelist)
AbstractRunner::List AbstractRunner::load(QObject* parent, const QStringList& whitelist)
{
List firstRunners;
List runners;

View File

@ -69,7 +69,7 @@ class PLASMA_EXPORT AbstractRunner : public QObject
*
* @param whitelist An optional whitelist of runners to load
*/
static List loadRunners(QObject* parent, const QStringList& whitelist = QStringList() );
static List load(QObject* parent, const QStringList& whitelist = QStringList());
/**
* Constructs a Runner object. Since AbstractRunner has pure virtuals,

View File

@ -434,7 +434,7 @@ Applet* Containment::addApplet(const QString& name, const QVariantList& args, ui
v->setCursor(Qt::BusyCursor);
}
Applet* applet = Applet::loadApplet(name, id, args);
Applet* applet = Applet::load(name, id, args);
if (v) {
v->unsetCursor();
}

View File

@ -394,7 +394,7 @@ Containment* Corona::addContainment(const QString& name, const QVariantList& arg
// default to the desktop containment
pluginName = "desktop";
} else if (pluginName != "null") {
applet = Applet::loadApplet(pluginName, id, args);
applet = Applet::load(pluginName, id, args);
containment = dynamic_cast<Containment*>(applet);
}

View File

@ -92,7 +92,7 @@ DataEngineManager::~DataEngineManager()
delete d;
}
Plasma::DataEngine* DataEngineManager::dataEngine(const QString& name) const
Plasma::DataEngine* DataEngineManager::get(const QString& name) const
{
Plasma::DataEngine::Dict::const_iterator it = d->engines.find(name);
if (it != d->engines.end()) {
@ -104,7 +104,7 @@ Plasma::DataEngine* DataEngineManager::dataEngine(const QString& name) const
return d->nullEngine();
}
Plasma::DataEngine* DataEngineManager::loadDataEngine(const QString& name)
Plasma::DataEngine* DataEngineManager::load(const QString& name)
{
Plasma::DataEngine* engine = 0;
Plasma::DataEngine::Dict::const_iterator it = d->engines.find(name);
@ -143,7 +143,7 @@ Plasma::DataEngine* DataEngineManager::loadDataEngine(const QString& name)
return engine;
}
void DataEngineManager::unloadDataEngine(const QString& name)
void DataEngineManager::unload(const QString& name)
{
Plasma::DataEngine::Dict::iterator it = d->engines.find(name);

View File

@ -55,7 +55,7 @@ class PLASMA_EXPORT DataEngineManager: public QObject
*
* @param name the name of the engine
*/
Plasma::DataEngine* dataEngine(const QString& name) const;
Plasma::DataEngine* get(const QString& name) const;
/**
* Loads a data engine and increases the reference count on it.
@ -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* loadDataEngine(const QString& name);
Plasma::DataEngine* load(const QString& name);
/**
* Decreases the reference count on the engine. If the count reaches
* zero, then the engine is deleted to save resources.
*/
void unloadDataEngine(const QString& name);
void unload(const QString& name);
/**
* Returns a listing of all known engines by name