Changeset View
Changeset View
Standalone View
Standalone View
src/core/simplejob.cpp
Context not available. | |||||
148 | q->connect(slave, SIGNAL(finished()), | 148 | q->connect(slave, SIGNAL(finished()), | ||
---|---|---|---|---|---|
149 | SLOT(slotFinished())); | 149 | SLOT(slotFinished())); | ||
150 | 150 | | |||
151 | q->connect(slave, SIGNAL(dataReq()), | ||||
152 | SLOT(slotDoPrivilegeExecution())); | ||||
153 | | ||||
151 | if ((m_extraFlags & EF_TransferJobDataSent) == 0) { // this is a "get" job | 154 | if ((m_extraFlags & EF_TransferJobDataSent) == 0) { // this is a "get" job | ||
152 | q->connect(slave, SIGNAL(totalSize(KIO::filesize_t)), | 155 | q->connect(slave, SIGNAL(totalSize(KIO::filesize_t)), | ||
153 | SLOT(slotTotalSize(KIO::filesize_t))); | 156 | SLOT(slotTotalSize(KIO::filesize_t))); | ||
Context not available. | |||||
282 | q_func()->emitSpeed(speed); | 285 | q_func()->emitSpeed(speed); | ||
283 | } | 286 | } | ||
284 | 287 | | |||
288 | void SimpleJobPrivate::slotDoPrivilegeExecution() | ||||
289 | { | ||||
290 | if (m_enablePrivilegeExecution | ||||
291 | || (m_parentJob && m_parentJob->isPrivilegeExecutionEnabled())) { | ||||
292 | m_slave->send(MSG_DATA, QByteArray("ElevatePrivilege")); | ||||
293 | } else { | ||||
294 | m_slave->send(MSG_DATA, QByteArray()); //since the slave is waiting, send an empty byte array. | ||||
295 | } | ||||
296 | } | ||||
297 | | ||||
285 | void SimpleJobPrivate::restartAfterRedirection(QUrl *redirectionUrl) | 298 | void SimpleJobPrivate::restartAfterRedirection(QUrl *redirectionUrl) | ||
286 | { | 299 | { | ||
287 | Q_Q(SimpleJob); | 300 | Q_Q(SimpleJob); | ||
Context not available. |