FutureProgress Class

class Core::FutureProgress

The FutureProgress class is used to adapt the appearance of progress indicators that were created through the ProgressManager class. More...

Header: #include <coreplugin/progressmanager/futureprogress.h>

Public Functions

QFuture<void> future() const
bool hasError() const
void setTitle(const QString &title)
void setWidget(QWidget *widget)
QString title() const

Detailed Description

Use the instance of this class that was returned by ProgressManager::addTask() to define a widget that should be shown below the progress bar, or to change the progress title. Also use it to react on the event that the user clicks on the progress indicator (which can be used to e.g. open a more detailed view, or the results of the task).

Member Function Documentation

QFuture<void> FutureProgress::future() const

Returns a QFuture object that represents this running task.

bool FutureProgress::hasError() const

Returns the error state of this progress indicator.

void FutureProgress::setTitle(const QString &title)

Changes the title of the progress indicator.

See also title().

void FutureProgress::setWidget(QWidget *widget)

Sets the widget to show below the progress bar. This will be destroyed when the progress indicator is destroyed. Default is to show no widget below the progress indicator.

QString FutureProgress::title() const

Returns the title of the progress indicator.

See also setTitle().