| 1 |
/* dvbcut |
| 2 |
Copyright (c) 2005 Sven Over <[email protected]> |
| 3 |
|
| 4 |
This program is free software; you can redistribute it and/or modify |
| 5 |
it under the terms of the GNU General Public License as published by |
| 6 |
the Free Software Foundation; either version 2 of the License, or |
| 7 |
(at your option) any later version. |
| 8 |
|
| 9 |
This program is distributed in the hope that it will be useful, |
| 10 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 12 |
GNU General Public License for more details. |
| 13 |
|
| 14 |
You should have received a copy of the GNU General Public License |
| 15 |
along with this program; if not, write to the Free Software |
| 16 |
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
| 17 |
*/ |
| 18 |
|
| 19 |
/* $Id$ */ |
| 20 |
|
| 21 |
#ifndef _DVBCUT_PROGRESSSTATUSBAR_H |
| 22 |
#define _DVBCUT_PROGRESSSTATUSBAR_H |
| 23 |
|
| 24 |
#include <qobject.h> |
| 25 |
#include "logoutput.h" |
| 26 |
|
| 27 |
class QStatusBar; |
| 28 |
class QProgressBar; |
| 29 |
class QPushButton; |
| 30 |
class QLabel; |
| 31 |
|
| 32 |
/** |
| 33 |
@author Sven Over |
| 34 |
*/ |
| 35 |
class progressstatusbar : public QObject, public logoutput |
| 36 |
{ |
| 37 |
Q_OBJECT |
| 38 |
|
| 39 |
protected: |
| 40 |
bool cancelwasclicked; |
| 41 |
QStatusBar *statusbar; |
| 42 |
QProgressBar *progressbar; |
| 43 |
QPushButton *cancelbutton; |
| 44 |
QLabel *label; |
| 45 |
|
| 46 |
public: |
| 47 |
progressstatusbar(QStatusBar *bar); |
| 48 |
~progressstatusbar(); |
| 49 |
|
| 50 |
virtual bool cancelled() |
| 51 |
{ |
| 52 |
return cancelwasclicked; |
| 53 |
} |
| 54 |
virtual void finish(); |
| 55 |
virtual void print(const QString &str); |
| 56 |
|
| 57 |
public slots: |
| 58 |
virtual void setprogress(int permille); |
| 59 |
virtual void clickedcancel(); |
| 60 |
}; |
| 61 |
|
| 62 |
#endif |