Commit c554dae6 authored by Orgad Shaneh's avatar Orgad Shaneh Committed by Orgad Shaneh

Core: Make parent argument last in ProgressTimer ctor

Change-Id: Id6513c46c72f0f4729783136ba0e9d779af7d147
Reviewed-by: default avatarEike Ziller <eike.ziller@theqtcompany.com>
parent 9d7efda4
......@@ -763,7 +763,7 @@ FutureProgress *ProgressManager::addTimedTask(const QFutureInterface<void> &futu
{
QFutureInterface<void> dummy(futureInterface); // Need mutable to access .future()
FutureProgress *fp = m_instance->doAddTask(dummy.future(), title, type, flags);
(void) new ProgressTimer(fp, futureInterface, expectedSeconds);
(void) new ProgressTimer(futureInterface, expectedSeconds, fp);
return fp;
}
......@@ -779,9 +779,9 @@ void ProgressManager::cancelTasks(Id type)
}
ProgressTimer::ProgressTimer(QObject *parent,
const QFutureInterfaceBase &futureInterface,
int expectedSeconds)
ProgressTimer::ProgressTimer(const QFutureInterfaceBase &futureInterface,
int expectedSeconds,
QObject *parent)
: QObject(parent),
m_futureInterface(futureInterface),
m_expectedTime(expectedSeconds),
......
......@@ -75,7 +75,8 @@ private:
class CORE_EXPORT ProgressTimer : public QObject
{
public:
ProgressTimer(QObject *parent, const QFutureInterfaceBase &futureInterface, int expectedSeconds);
ProgressTimer(const QFutureInterfaceBase &futureInterface, int expectedSeconds,
QObject *parent = 0);
private:
void handleTimeout();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment