libkdepim
statusbarprogresswidget.h00001 #ifndef __KPIM_STATUSBARPROGRESSWIDGET_H
00002 #define __KPIM_STATUSBARPROGRESSWIDGET_H
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00039 #include <kdepimmacros.h>
00040
00041 class KMMainWidget;
00042 class KProgress;
00043 class TQPushButton;
00044 class TQWidgetStack;
00045 class TQBoxLayout;
00046 class TQLabel;
00047 class TQTimer;
00048
00049 namespace KPIM {
00050 class SSLLabel;
00051 class ProgressItem;
00052 class ProgressDialog;
00053
00054 class KDE_EXPORT StatusbarProgressWidget : public TQFrame {
00055
00056 Q_OBJECT
00057
00058 public:
00059
00060 StatusbarProgressWidget( ProgressDialog* progressDialog, TQWidget* parent, bool button = true );
00061
00062 public slots:
00063
00064 void slotClean();
00065 void slotSetSSL( bool );
00066
00067 void slotProgressItemAdded( KPIM::ProgressItem *i );
00068 void slotProgressItemCompleted( KPIM::ProgressItem *i );
00069 void slotProgressItemProgress( KPIM::ProgressItem *i, unsigned int value );
00070
00071 protected slots:
00072 void slotProgressDialogVisible( bool );
00073 void slotShowItemDelayed();
00074 void slotBusyIndicator();
00075 void updateBusyMode();
00076
00077 protected:
00078 void setMode();
00079 void connectSingleItem();
00080 void activateSingleItemMode();
00081
00082 virtual bool eventFilter( TQObject *, TQEvent * );
00083
00084 private:
00085 KProgress* m_pProgressBar;
00086 TQLabel* m_pLabel;
00087 SSLLabel* m_sslLabel;
00088 TQPushButton* m_pButton;
00089
00090 enum Mode { None, Progress };
00091
00092 uint mode;
00093 bool m_bShowButton;
00094
00095 TQBoxLayout *box;
00096 TQWidgetStack *stack;
00097 ProgressItem *mCurrentItem;
00098 ProgressDialog* mProgressDialog;
00099 TQTimer *mDelayTimer;
00100 TQTimer *mBusyTimer;
00101 };
00102
00103 }
00104
00105 #endif
|