remove the no longer used private slot, and add a default start() method so it can be used as is

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=856499
This commit is contained in:
Aaron J. Seigo 2008-09-03 04:25:49 +00:00
parent 2963de33e6
commit bfbd49b438
2 changed files with 11 additions and 7 deletions

View File

@ -40,11 +40,6 @@ public:
QString operation;
QMap<QString, QVariant> parameters;
QVariant result;
void slotStart()
{
q->start();
}
};
ServiceJob::ServiceJob(const QString &destination, const QString &operation,
@ -84,6 +79,11 @@ void ServiceJob::setResult(const QVariant &result)
d->result = result;
}
void ServiceJob::start()
{
setResult(false);
}
} // namespace Plasma
#include "servicejob.moc"

View File

@ -97,6 +97,12 @@ public:
*/
QVariant result() const;
/**
* Default implementation of start, which simply sets the results to false.
* This makes it easy to create a "failure" job.
*/
virtual void start();
protected:
/**
* Sets the result for an operation.
@ -104,8 +110,6 @@ protected:
void setResult(const QVariant &result);
private:
Q_PRIVATE_SLOT(d, void slotStart())
ServiceJobPrivate * const d;
};