make RunnerManager a friend so we can do the happy-scripting-dance again

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=804739
This commit is contained in:
Aaron J. Seigo 2008-05-06 20:48:44 +00:00
parent 0d0fe7770d
commit 6ea602b848
2 changed files with 5 additions and 11 deletions

View File

@ -63,7 +63,7 @@ public:
script = Plasma::loadScriptEngine(api, runner); script = Plasma::loadScriptEngine(api, runner);
if (!script) { if (!script) {
kDebug() << "Could not create a" << api << "ScriptEngine for the" kDebug() << "Could not create a" << api << "ScriptEngine for the"
<< runnerDescription.name() << "Runner."; << runnerDescription.name() << "Runner.";
delete package; delete package;
package = 0; package = 0;
} else { } else {
@ -90,8 +90,8 @@ public:
QMutex AbstractRunner::Private::bigLock; QMutex AbstractRunner::Private::bigLock;
AbstractRunner::AbstractRunner(QObject* parent, const QString& serviceId) AbstractRunner::AbstractRunner(QObject* parent, const QString& serviceId)
: QObject(parent), : QObject(parent),
d(new Private(this, KService::serviceByStorageId(serviceId))) d(new Private(this, KService::serviceByStorageId(serviceId)))
{ {
} }

View File

@ -182,6 +182,8 @@ class PLASMA_EXPORT AbstractRunner : public QObject
const Package* package() const; const Package* package() const;
protected: protected:
friend class RunnerManager;
/** /**
* Constructs a Runner object. Since AbstractRunner has pure virtuals, * Constructs a Runner object. Since AbstractRunner has pure virtuals,
* this constructor can not be called directly. Rather a subclass must * this constructor can not be called directly. Rather a subclass must
@ -213,14 +215,6 @@ class PLASMA_EXPORT AbstractRunner : public QObject
*/ */
void setSpeed(Speed newSpeed); void setSpeed(Speed newSpeed);
//For 4.1
// /**
// * Sets the run tier of the runner. Higher tier runners execute only
// * after all lower-level runners execute. Call this method if your runner
// * depends on the output of previous runners.
// */
// void setTier(int tier);
/** /**
* Sets the priority of the runner. Lower priority runners are executed * Sets the priority of the runner. Lower priority runners are executed
* only after higher priority runners. * only after higher priority runners.