-rw-r--r-- | kmicromail/qpe/qdialog.h | 35 | ||||
-rw-r--r-- | kmicromail/qpe/qdialog_hacked.cpp | 30 |
2 files changed, 65 insertions, 0 deletions
diff --git a/kmicromail/qpe/qdialog.h b/kmicromail/qpe/qdialog.h new file mode 100644 index 0000000..d671e34 --- a/dev/null +++ b/kmicromail/qpe/qdialog.h | |||
@@ -0,0 +1,35 @@ | |||
1 | |||
2 | #ifndef MINIKDE_KDIALOG_H | ||
3 | |||
4 | #ifndef DEFINE_QDIALOG_HACK | ||
5 | #define DEFINE_QDIALOG_HACK | ||
6 | #warning call of include <qdialog.h> | ||
7 | #warning including /usr/local/qt/include/qdialog.h | ||
8 | #warning if you get an compiling error please adjust your path her | ||
9 | |||
10 | #include "/usr/local/qt/include/qdialog.h" | ||
11 | class QDialog_hacked : public QDialog | ||
12 | { | ||
13 | //Q__OBJECT | ||
14 | |||
15 | public: | ||
16 | QDialog_hacked ( QWidget * parent=0, const char * name=0, bool modal=true, WFlags f=0 ); | ||
17 | |||
18 | }; | ||
19 | |||
20 | #define QDialog QDialog_hacked | ||
21 | |||
22 | #endif | ||
23 | |||
24 | #else | ||
25 | #warning ****************************************** | ||
26 | #warning ****************************************** | ||
27 | #warning ****************************************** | ||
28 | #warning ****************************************** | ||
29 | #warning ****************************************** | ||
30 | #warning ****************************************** | ||
31 | #warning ****************************************** | ||
32 | #warning ****************************************** | ||
33 | #include "/usr/local/qt/include/qdialog.h" | ||
34 | |||
35 | #endif | ||
diff --git a/kmicromail/qpe/qdialog_hacked.cpp b/kmicromail/qpe/qdialog_hacked.cpp new file mode 100644 index 0000000..e2ce21a --- a/dev/null +++ b/kmicromail/qpe/qdialog_hacked.cpp | |||
@@ -0,0 +1,30 @@ | |||
1 | |||
2 | #include <qdialog.h> | ||
3 | #include <qhbox.h> | ||
4 | #include <qpushbutton.h> | ||
5 | #include <klocale.h> | ||
6 | #ifdef QDialog | ||
7 | #undef QDialog | ||
8 | #endif | ||
9 | QDialog_hacked::QDialog_hacked ( QWidget * parent, const char * name, bool modal, WFlags f ) | ||
10 | : QDialog( parent,name,modal) | ||
11 | { | ||
12 | qDebug("******************** "); | ||
13 | qDebug("******************** "); | ||
14 | qDebug("******************** "); | ||
15 | qDebug("******************** "); | ||
16 | qDebug("New hacked QDialog == KDialogBase "); | ||
17 | //QTimer::singleShot( 1, this,SLOT(addaddbuttons()) ); | ||
18 | |||
19 | setOrientation ( Vertical ); | ||
20 | QHBox * hb = new QHBox ( this ); | ||
21 | QPushButton *ok = new QPushButton( i18n("OK"), hb ); | ||
22 | QPushButton *cancel = new QPushButton( i18n("Cancel"), hb ); | ||
23 | setExtension ( hb ); | ||
24 | showExtension ( true ); | ||
25 | connect ( ok, SIGNAL ( clicked()),this, SLOT (accept() ) ); | ||
26 | connect ( cancel, SIGNAL ( clicked()),this, SLOT (reject() ) ); | ||
27 | |||
28 | } | ||
29 | |||
30 | |||