-rw-r--r-- | microkde/kdeui/kbuttonbox.cpp | 2 | ||||
-rw-r--r-- | microkde/kdeui/kpopupmenu.cpp | 19 | ||||
-rw-r--r-- | microkde/kdeui/kpopupmenu.h | 22 | ||||
-rw-r--r-- | microkde/microkde.pro | 2 | ||||
-rw-r--r-- | microkde/microkdeE.pro | 2 |
5 files changed, 44 insertions, 3 deletions
diff --git a/microkde/kdeui/kbuttonbox.cpp b/microkde/kdeui/kbuttonbox.cpp index 16206e8..83d622a 100644 --- a/microkde/kdeui/kbuttonbox.cpp +++ b/microkde/kdeui/kbuttonbox.cpp @@ -48,3 +48,3 @@ //US #include "kbuttonbox.moc" - + #include <kbuttonbox.h> diff --git a/microkde/kdeui/kpopupmenu.cpp b/microkde/kdeui/kpopupmenu.cpp new file mode 100644 index 0000000..96d2a87 --- a/dev/null +++ b/microkde/kdeui/kpopupmenu.cpp @@ -0,0 +1,19 @@ + +#include <kpopupmenu.h> +#include <qtimer.h> + + +KPopupMenu::KPopupMenu ( QWidget * parent, const char * name ) + : QPopupMenu ( parent, name ) {;} + + + +KMenuBar::KMenuBar ( QWidget * parent, const char * name ) + : QPEMenuBar ( parent, name ) {} + +void KMenuBar::focusOutEvent ( QFocusEvent * e) +{ + QPEMenuBar::focusOutEvent( e ); + QTimer::singleShot( 100, this, SIGNAL ( lostFocus() ) ); + +} diff --git a/microkde/kdeui/kpopupmenu.h b/microkde/kdeui/kpopupmenu.h index 1352429..f16ce77 100644 --- a/microkde/kdeui/kpopupmenu.h +++ b/microkde/kdeui/kpopupmenu.h @@ -4,2 +4,8 @@ #include <qpopupmenu.h> +#ifdef DESKTOP_VERSION +#include <qmenubar.h> +#define QPEMenuBar QMenubar +#else +#include <qpe/qpemenubar.h> +#endif @@ -7,6 +13,18 @@ class KPopupMenu : public QPopupMenu { +Q_OBJECT public: - KPopupMenu ( QWidget * parent=0, const char * name=0 ) - : QPopupMenu ( parent, name ) {} + KPopupMenu ( QWidget * parent=0, const char * name=0 ); + +}; + +class KMenuBar : public QPEMenuBar +{ +Q_OBJECT + public: + KMenuBar ( QWidget * parent=0, const char * name=0 ); + signals: + void lostFocus(); + protected: + void focusOutEvent ( QFocusEvent * e); }; diff --git a/microkde/microkde.pro b/microkde/microkde.pro index 44e5f9d..7120bdd 100644 --- a/microkde/microkde.pro +++ b/microkde/microkde.pro @@ -105,2 +105,3 @@ KDGanttMinimizeSplitter.h \ kdeui/kaction.h \ + kdeui/kpopupmenu.h \ kdeui/kactionclasses.h \ @@ -167,2 +168,3 @@ KDGanttMinimizeSplitter.cpp \ kdeui/kaction.cpp \ + kdeui/kpopupmenu.cpp \ kdeui/kactionclasses.cpp \ diff --git a/microkde/microkdeE.pro b/microkde/microkdeE.pro index 335fcd0..8fe2bd5 100644 --- a/microkde/microkdeE.pro +++ b/microkde/microkdeE.pro @@ -58,2 +58,3 @@ KDGanttMinimizeSplitter.h \ kdeui/kaction.h \ + kdeui/kpopupmenu.h \ kdeui/kactionclasses.h \ @@ -141,2 +142,3 @@ KDGanttMinimizeSplitter.cpp fncolordialog.cpp \ kdeui/kaction.cpp \ + kdeui/kpopupmenu.cpp \ kdeui/kactionclasses.cpp \ |