Add the FileTransferJob into the globalTracker
This commit is contained in:
parent
f4dce72d41
commit
3b276855a0
1 changed files with 2 additions and 0 deletions
|
@ -26,6 +26,7 @@
|
||||||
#include <KStandardDirs>
|
#include <KStandardDirs>
|
||||||
#include <KSharedConfig>
|
#include <KSharedConfig>
|
||||||
#include <KConfigGroup>
|
#include <KConfigGroup>
|
||||||
|
#include <KJobTrackerInterface>
|
||||||
|
|
||||||
#include <qprocess.h>
|
#include <qprocess.h>
|
||||||
#include <QDir>
|
#include <QDir>
|
||||||
|
@ -91,6 +92,7 @@ bool SharePlugin::receivePackage(const NetworkPackage& np)
|
||||||
destination.addPath(filename);
|
destination.addPath(filename);
|
||||||
FileTransferJob* job = np.createPayloadTransferJob(destination);
|
FileTransferJob* job = np.createPayloadTransferJob(destination);
|
||||||
connect(job, SIGNAL(result(KJob*)), this, SLOT(finished(KJob*)));
|
connect(job, SIGNAL(result(KJob*)), this, SLOT(finished(KJob*)));
|
||||||
|
KIO::getJobTracker()->registerJob(job);
|
||||||
job->start();
|
job->start();
|
||||||
} else if (np.has("text")) {
|
} else if (np.has("text")) {
|
||||||
QString text = np.get<QString>("text");
|
QString text = np.get<QString>("text");
|
||||||
|
|
Loading…
Reference in a new issue