casa
$Rev:20696$
|
GUI for displaying progress information. More...
#include <QtProgressWidget.qo.h>
Public Slots | |
void | initialize (const QString &operationName) |
Initializes the GUI with the given operation name. | |
void | setStatus (const QString &status) |
Sets the status to the given. | |
void | setProgress (unsigned int progress) |
Sets the progress percentage (0 - 100) to the given. | |
void | setProgress (unsigned int progress, const QString &status) |
Sets the progress percentage (0 - 100) and the status to the given. | |
void | finalize () |
Finalizes the GUI. | |
Signals | |
void | backgroundRequested () |
Signal for when the user requests "background" for the thread. | |
void | pauseRequested () |
Signal for when the user requests "pause" for the thread. | |
void | resumeRequested () |
Signal for when the user requests "resume" for the thread. | |
void | cancelRequested () |
Signal for when the user requests "cancel" for the thread. | |
Public Member Functions | |
QtProgressWidget (bool allowBackground=true, bool allowPauseResume=true, bool allowCancel=true, bool isDialog=true, bool useCompact=false, QWidget *parent=NULL) | |
Constructor which takes the PlotMS parent an optional parent widget. | |
~QtProgressWidget () | |
Destructor. | |
void | setAllowedOperations (bool background, bool pauseResume, bool cancel) |
Sets which operations the user can request using this widget. | |
QMutex & | mutex () |
Returns the mutex used for this widget. | |
Protected Member Functions | |
void | closeEvent (QCloseEvent *event) |
Overrides QWidget::closeEvent(). | |
Private Slots | |
void | background () |
For the "background" button. | |
void | pauseResume (bool pause) |
For the "pause"/"resume" button. | |
void | cancel () |
For the "cancel" button. | |
Private Attributes | |
QMutex | itsMutex_ |
Mutex. | |
Ui::ProgressWidget * | itsProgress_ |
Normal widget. | |
Ui::ProgressCompactWidget * | itsCompactProgress_ |
Compact widget. |
GUI for displaying progress information.
It also shows "background", "cancel", and "pause/resume" buttons for the user. The parent of this widget is responsible for implementing these behaviors as needed.
Definition at line 40 of file QtProgressWidget.qo.h.
casa::QtProgressWidget::QtProgressWidget | ( | bool | allowBackground = true , |
bool | allowPauseResume = true , |
||
bool | allowCancel = true , |
||
bool | isDialog = true , |
||
bool | useCompact = false , |
||
QWidget * | parent = NULL |
||
) |
Constructor which takes the PlotMS parent an optional parent widget.
Destructor.
void casa::QtProgressWidget::background | ( | ) | [private, slot] |
For the "background" button.
void casa::QtProgressWidget::backgroundRequested | ( | ) | [signal] |
Signal for when the user requests "background" for the thread.
void casa::QtProgressWidget::cancel | ( | ) | [private, slot] |
For the "cancel" button.
void casa::QtProgressWidget::cancelRequested | ( | ) | [signal] |
Signal for when the user requests "cancel" for the thread.
void casa::QtProgressWidget::closeEvent | ( | QCloseEvent * | event | ) | [protected] |
Overrides QWidget::closeEvent().
Connects closing to the "background" signal.
void casa::QtProgressWidget::finalize | ( | ) | [slot] |
Finalizes the GUI.
Should be called after the operation ends.
void casa::QtProgressWidget::initialize | ( | const QString & | operationName | ) | [slot] |
Initializes the GUI with the given operation name.
Should be called before the operation starts.
QMutex& casa::QtProgressWidget::mutex | ( | ) |
Returns the mutex used for this widget.
void casa::QtProgressWidget::pauseRequested | ( | ) | [signal] |
Signal for when the user requests "pause" for the thread.
void casa::QtProgressWidget::pauseResume | ( | bool | pause | ) | [private, slot] |
For the "pause"/"resume" button.
void casa::QtProgressWidget::resumeRequested | ( | ) | [signal] |
Signal for when the user requests "resume" for the thread.
void casa::QtProgressWidget::setAllowedOperations | ( | bool | background, |
bool | pauseResume, | ||
bool | cancel | ||
) |
Sets which operations the user can request using this widget.
void casa::QtProgressWidget::setProgress | ( | unsigned int | progress | ) | [slot] |
Sets the progress percentage (0 - 100) to the given.
void casa::QtProgressWidget::setProgress | ( | unsigned int | progress, |
const QString & | status | ||
) | [slot] |
Sets the progress percentage (0 - 100) and the status to the given.
void casa::QtProgressWidget::setStatus | ( | const QString & | status | ) | [slot] |
Sets the status to the given.
Ui::ProgressCompactWidget* casa::QtProgressWidget::itsCompactProgress_ [private] |
Compact widget.
Definition at line 103 of file QtProgressWidget.qo.h.
QMutex casa::QtProgressWidget::itsMutex_ [private] |
Definition at line 97 of file QtProgressWidget.qo.h.
Ui::ProgressWidget* casa::QtProgressWidget::itsProgress_ [private] |
Normal widget.
Definition at line 100 of file QtProgressWidget.qo.h.