libkdepim
#include <progressmanager.h>
Public Types | |
enum | CryptoStatus { Encrypted, Unencrypted, Unknown } |
Signals | |
void | progressItemAdded (KPIM::ProgressItem *) |
void | progressItemCanceled (KPIM::ProgressItem *) |
void | progressItemCompleted (KPIM::ProgressItem *) |
void | progressItemCryptoStatus (KPIM::ProgressItem *, KPIM::ProgressItem::CryptoStatus) |
void | progressItemLabel (KPIM::ProgressItem *, const QString &) |
void | progressItemProgress (KPIM::ProgressItem *, unsigned int) |
void | progressItemStatus (KPIM::ProgressItem *, const QString &) |
void | progressItemUsesBusyIndicator (KPIM::ProgressItem *item, bool value) |
Public Member Functions | |
void | addChild (ProgressItem *kiddo) |
bool | canBeCanceled () const |
void | cancel () |
bool | canceled () const |
unsigned int | completedItems () const |
CryptoStatus | cryptoStatus () const |
const QString & | id () const |
void | incCompletedItems (unsigned int v=1) |
const QString & | label () const |
ProgressItem * | parent () const |
unsigned int | progress () const |
void | removeChild (ProgressItem *kiddo) |
void | reset () |
void | setCanBeCanceled (bool b) |
void | setComplete () |
void | setCompletedItems (unsigned int v) |
void | setCryptoStatus (ProgressItem::CryptoStatus v) |
void | setLabel (const QString &v) |
void | setProgress (unsigned int v) |
void | setStatus (const QString &v) |
void | setTotalItems (unsigned int v) |
void | setTypeProgressItem (unsigned int) |
void | setUsesBusyIndicator (bool useBusyIndicator) |
const QString & | status () const |
unsigned int | totalItems () const |
unsigned int | typeProgressItem () const |
void | updateProgress () |
bool | usesBusyIndicator () const |
Public Member Functions inherited from QObject | |
QObject (QObject *parent) | |
QObject (QObject *parent, const char *name) | |
virtual | ~QObject () |
bool | blockSignals (bool block) |
QObject * | child (const char *objName, const char *inheritsClass, bool recursiveSearch) const |
const QObjectList & | children () const |
const char * | className () const |
bool | connect (const QObject *sender, const char *signal, const char *method, Qt::ConnectionType type) const |
void | deleteLater () |
void | destroyed (QObject *obj) |
bool | disconnect (const QObject *receiver, const char *method) |
bool | disconnect (const char *signal, const QObject *receiver, const char *method) |
void | dumpObjectInfo () |
void | dumpObjectTree () |
QList< QByteArray > | dynamicPropertyNames () const |
virtual bool | event (QEvent *e) |
virtual bool | eventFilter (QObject *watched, QEvent *event) |
T | findChild (const QString &name) const |
QList< T > | findChildren (const QRegExp ®Exp) const |
QList< T > | findChildren (const QString &name) const |
bool | inherits (const char *className) const |
void | insertChild (QObject *object) |
void | installEventFilter (QObject *filterObj) |
bool | isA (const char *className) const |
bool | isWidgetType () const |
void | killTimer (int id) |
virtual const QMetaObject * | metaObject () const |
void | moveToThread (QThread *targetThread) |
const char * | name () const |
const char * | name (const char *defaultName) const |
QString | objectName () const |
QObject * | parent () const |
QVariant | property (const char *name) const |
void | removeChild (QObject *object) |
void | removeEventFilter (QObject *obj) |
void | setName (const char *name) |
void | setObjectName (const QString &name) |
void | setParent (QObject *parent) |
bool | setProperty (const char *name, const QVariant &value) |
bool | signalsBlocked () const |
int | startTimer (int interval) |
QThread * | thread () const |
Protected Member Functions | |
ProgressItem (ProgressItem *parent, const QString &id, const QString &label, const QString &status, bool isCancellable, CryptoStatus cryptoStatus) | |
virtual | ~ProgressItem () |
Protected Member Functions inherited from QObject | |
bool | checkConnectArgs (const char *signal, const QObject *object, const char *method) |
virtual void | childEvent (QChildEvent *event) |
virtual void | connectNotify (const char *signal) |
virtual void | customEvent (QEvent *event) |
virtual void | disconnectNotify (const char *signal) |
int | receivers (const char *signal) const |
QObject * | sender () const |
int | senderSignalIndex () const |
virtual void | timerEvent (QTimerEvent *event) |
Additional Inherited Members | |
Static Public Member Functions inherited from QObject | |
bool | connect (const QObject *sender, const char *signal, const QObject *receiver, const char *method, Qt::ConnectionType type) |
bool | connect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method, Qt::ConnectionType type) |
bool | disconnect (const QObject *sender, const char *signal, const QObject *receiver, const char *method) |
bool | disconnect (const QObject *sender, const QMetaMethod &signal, const QObject *receiver, const QMetaMethod &method) |
QString | tr (const char *sourceText, const char *disambiguation, int n) |
QString | trUtf8 (const char *sourceText, const char *disambiguation, int n) |
Static Protected Member Functions inherited from QObject | |
QByteArray | normalizeSignalSlot (const char *signalSlot) |
Properties inherited from QObject | |
objectName | |
Detailed Description
Definition at line 45 of file progressmanager.h.
Member Enumeration Documentation
Enumerator | |
---|---|
Encrypted | |
Unencrypted | |
Unknown |
Definition at line 52 of file progressmanager.h.
Constructor & Destructor Documentation
|
protected |
Definition at line 34 of file progressmanager.cpp.
|
protectedvirtual |
Definition at line 54 of file progressmanager.cpp.
Member Function Documentation
void KPIM::ProgressItem::addChild | ( | ProgressItem * | kiddo | ) |
Definition at line 84 of file progressmanager.cpp.
|
inline |
- Returns
- Whether this item can be canceled.
Definition at line 92 of file progressmanager.h.
void KPIM::ProgressItem::cancel | ( | ) |
Definition at line 117 of file progressmanager.cpp.
|
inline |
Definition at line 167 of file progressmanager.h.
|
inline |
Definition at line 157 of file progressmanager.h.
|
inline |
- Returns
- Whether this item uses secure communication (Account uses ssl, for example.).
Definition at line 103 of file progressmanager.h.
|
inline |
- Returns
- The id string which uniquely identifies the operation represented by this item.
Definition at line 62 of file progressmanager.h.
|
inline |
Definition at line 156 of file progressmanager.h.
|
inline |
- Returns
- The user visible string to be used to represent this item.
Definition at line 72 of file progressmanager.h.
|
inline |
- Returns
- The parent item of this one, if there is one.
Definition at line 67 of file progressmanager.h.
|
inline |
- Returns
- The current progress value of this item in percent.
Definition at line 127 of file progressmanager.h.
|
signal |
Emitted when a new ProgressItem is added.
- Parameters
-
The ProgressItem that was added.
|
signal |
Emitted when an item was canceled.
It will not go away immediately, only when the owner sets it complete, which will usually happen. Can be used to visually indicate the canceled status of an item. Should be used by the owner of the item to make sure it is set completed even if it is canceled. There is a ProgressManager::slotStandardCancelHandler which simply sets the item completed and can be used if no other work needs to be done on cancel.
- Parameters
-
The canceled item;
|
signal |
Emitted when a progress item was completed.
The item will be deleted afterwards, so slots connected to this are the last chance to work with this item.
- Parameters
-
The completed item.
|
signal |
Emitted when the crypto status of an item changed.
Should be used by progress dialogs to update the crypto indicator of an item.
- Parameters
-
The updated item. The new state.
|
signal |
Emitted when the label of an item changed.
Should be used by progress dialogs to update the label of an item.
- Parameters
-
The updated item. The new label.
|
signal |
Emitted when the progress value of an item changes.
- Parameters
-
The item which got a new value. The value, for convenience.
|
signal |
Emitted when the status message of an item changed.
Should be used by progress dialogs to update the status message for an item.
- Parameters
-
The updated item. The new message.
|
signal |
Emitted when the busy indicator state of an item changes.
Should be used by progress dialogs so that they can adjust the display of the progress bar to the new mode.
- Parameters
-
item The updated item value True if the item uses a busy indicator now, false otherwise
void KPIM::ProgressItem::removeChild | ( | ProgressItem * | kiddo | ) |
Definition at line 89 of file progressmanager.cpp.
void KPIM::ProgressItem::reset | ( | ) |
Reset the progress value of this item to 0 and the status string to the empty string.
Definition at line 77 of file progressmanager.cpp.
void KPIM::ProgressItem::setCanBeCanceled | ( | bool | b | ) |
- Parameters
-
b Set if can be canceled
Definition at line 163 of file progressmanager.cpp.
void KPIM::ProgressItem::setComplete | ( | ) |
Tell the item it has finished.
This will emit progressItemCompleted() result in the destruction of the item after all slots connected to this signal have executed. This is the only way to get rid of an item and needs to be called even if the item is canceled. Don't use the item after this has been called on it.
Definition at line 58 of file progressmanager.cpp.
|
inline |
Definition at line 155 of file progressmanager.h.
void KPIM::ProgressItem::setCryptoStatus | ( | ProgressItem::CryptoStatus | v | ) |
Set whether this item uses crypted communication, so listeners can display a nice crypto icon.
- Parameters
-
v The value.
Definition at line 168 of file progressmanager.cpp.
void KPIM::ProgressItem::setLabel | ( | const QString & | v | ) |
- Parameters
-
v Set the user visible string identifying this item.
Definition at line 151 of file progressmanager.cpp.
void KPIM::ProgressItem::setProgress | ( | unsigned int | v | ) |
Set the progress (percentage of completion) value of this item.
- Parameters
-
v The percentage value.
Definition at line 144 of file progressmanager.cpp.
void KPIM::ProgressItem::setStatus | ( | const QString & | v | ) |
Set the string to be used for showing this item's current status.
- Parameters
-
v The status string.
Definition at line 157 of file progressmanager.cpp.
|
inline |
Definition at line 153 of file progressmanager.h.
void KPIM::ProgressItem::setTypeProgressItem | ( | unsigned int | type | ) |
Definition at line 112 of file progressmanager.cpp.
void KPIM::ProgressItem::setUsesBusyIndicator | ( | bool | useBusyIndicator | ) |
Sets whether this item uses a busy indicator instead of real progress for its progress bar.
If it uses a busy indicator, you are still responsible for calling setProgress() from time to time to update the busy indicator.
Definition at line 174 of file progressmanager.cpp.
|
inline |
- Returns
- The string to be used for showing this item's current status.
Definition at line 82 of file progressmanager.h.
|
inline |
Definition at line 154 of file progressmanager.h.
unsigned int KPIM::ProgressItem::typeProgressItem | ( | ) | const |
Definition at line 107 of file progressmanager.cpp.
void KPIM::ProgressItem::updateProgress | ( | ) |
Recalculate progress according to total/completed items and update.
Definition at line 139 of file progressmanager.cpp.
|
inline |
- Returns
- whether this item uses a busy indicator instead of real progress display
Definition at line 115 of file progressmanager.h.
The documentation for this class was generated from the following files:
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:33:51 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.