Public Member Functions | List of all members
pqAnimationProgressDialog Class Reference

progress dialog for animation progress More...

#include <pqAnimationProgressDialog.h>

Inherits QProgressDialog.

Public Member Functions

 pqAnimationProgressDialog (const QString &labelText, const QString &cancelButtonText, int minimum=0, int maximum=100, QWidget *parent=nullptr, Qt::WindowFlags f=Qt::WindowFlags())
 
 pqAnimationProgressDialog (QWidget *parent=nullptr, Qt::WindowFlags f=Qt::WindowFlags())
 
 ~pqAnimationProgressDialog () override
 
void setAnimationScene (pqAnimationScene *)
 Set the animation scene to monitor. More...
 
void setAnimationScene (vtkSMProxy *)
 Set the animation scene to monitor. More...
 

Detailed Description

progress dialog for animation progress

pqAnimationProgressDialog is a QProgressDialog that hooks itself up to monitor (and show) progress from an animation scene. The dialog uses the cancel button to abort the animation playback.

Typical usage:

"Save animation progress", "Abort", 0, 100, pqCoreUtilities::mainWidget());
progress.setWindowTitle("Saving Animation ...");
progress.setAnimationScene(scene);
progress.show();
auto appcore = pqApplicationCore::instance();
auto pgm = appcore->getProgressManager();
// this is essential since pqProgressManager blocks all interaction
// events when progress events are pending. since we have a QProgressDialog
// as modal, we don't need to that. Plus, we want the cancel button on the
// dialog to work.
const auto prev = pgm->unblockEvents(true);
// ---- do animation playback ---
pgm->unblockEvents(prev);
progress.hide();

Definition at line 44 of file pqAnimationProgressDialog.h.

Constructor & Destructor Documentation

◆ pqAnimationProgressDialog() [1/2]

pqAnimationProgressDialog::pqAnimationProgressDialog ( const QString &  labelText,
const QString &  cancelButtonText,
int  minimum = 0,
int  maximum = 100,
QWidget *  parent = nullptr,
Qt::WindowFlags  f = Qt::WindowFlags() 
)

◆ pqAnimationProgressDialog() [2/2]

pqAnimationProgressDialog::pqAnimationProgressDialog ( QWidget *  parent = nullptr,
Qt::WindowFlags  f = Qt::WindowFlags() 
)

◆ ~pqAnimationProgressDialog()

pqAnimationProgressDialog::~pqAnimationProgressDialog ( )
override

Member Function Documentation

◆ setAnimationScene() [1/2]

void pqAnimationProgressDialog::setAnimationScene ( pqAnimationScene )

Set the animation scene to monitor.

◆ setAnimationScene() [2/2]

void pqAnimationProgressDialog::setAnimationScene ( vtkSMProxy )

Set the animation scene to monitor.


The documentation for this class was generated from the following file: