remove DataEngine::init()
with only one ctor is not necessary anymore
This commit is contained in:
parent
4875658944
commit
f9adc7a598
@ -52,6 +52,14 @@ DataEngine::DataEngine(const KPluginInfo &plugin, QObject *parent)
|
|||||||
: QObject(parent),
|
: QObject(parent),
|
||||||
d(new DataEnginePrivate(this, plugin))
|
d(new DataEnginePrivate(this, plugin))
|
||||||
{
|
{
|
||||||
|
if (d->script) {
|
||||||
|
d->setupScriptSupport();
|
||||||
|
d->script->init();
|
||||||
|
} else {
|
||||||
|
// kDebug() << "called";
|
||||||
|
// default implementation does nothing. this is for engines that have to
|
||||||
|
// start things in motion external to themselves before they can work
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
DataEngine::~DataEngine()
|
DataEngine::~DataEngine()
|
||||||
@ -130,18 +138,6 @@ DataContainer *DataEngine::containerForSource(const QString &source)
|
|||||||
return d->source(source, false);
|
return d->source(source, false);
|
||||||
}
|
}
|
||||||
|
|
||||||
void DataEngine::init()
|
|
||||||
{
|
|
||||||
if (d->script) {
|
|
||||||
d->setupScriptSupport();
|
|
||||||
d->script->init();
|
|
||||||
} else {
|
|
||||||
// kDebug() << "called";
|
|
||||||
// default implementation does nothing. this is for engines that have to
|
|
||||||
// start things in motion external to themselves before they can work
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
bool DataEngine::sourceRequestEvent(const QString &name)
|
bool DataEngine::sourceRequestEvent(const QString &name)
|
||||||
{
|
{
|
||||||
if (d->script) {
|
if (d->script) {
|
||||||
|
@ -75,17 +75,6 @@ class PLASMA_EXPORT DataEngine : public QObject
|
|||||||
|
|
||||||
~DataEngine();
|
~DataEngine();
|
||||||
|
|
||||||
/**
|
|
||||||
* This method is called when the DataEngine is started. When this
|
|
||||||
* method is called the DataEngine is fully constructed and ready to be
|
|
||||||
* used. This method should be reimplemented by DataEngine subclasses
|
|
||||||
* which need to perform a startup routine.
|
|
||||||
*
|
|
||||||
* The default implementation does nothing. Reimplementations in
|
|
||||||
* subclasses don't need to call this one.
|
|
||||||
**/
|
|
||||||
virtual void init();
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @return a list of all the data sources available via this DataEngine
|
* @return a list of all the data sources available via this DataEngine
|
||||||
* Whether these sources are currently available (which is what
|
* Whether these sources are currently available (which is what
|
||||||
|
@ -138,7 +138,6 @@ Plasma::DataEngine *DataEngineManager::loadEngine(const QString &name)
|
|||||||
return d->nullEngine();
|
return d->nullEngine();
|
||||||
}
|
}
|
||||||
|
|
||||||
engine->init();
|
|
||||||
d->engines[name] = engine;
|
d->engines[name] = engine;
|
||||||
return engine;
|
return engine;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user