summaryrefslogtreecommitdiff
path: root/noncore/applets/keyhelper/keyhelperapplet/applet/KeyHelperWidget.h
Unidiff
Diffstat (limited to 'noncore/applets/keyhelper/keyhelperapplet/applet/KeyHelperWidget.h') (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/applets/keyhelper/keyhelperapplet/applet/KeyHelperWidget.h75
1 files changed, 75 insertions, 0 deletions
diff --git a/noncore/applets/keyhelper/keyhelperapplet/applet/KeyHelperWidget.h b/noncore/applets/keyhelper/keyhelperapplet/applet/KeyHelperWidget.h
new file mode 100644
index 0000000..4798c5c
--- a/dev/null
+++ b/noncore/applets/keyhelper/keyhelperapplet/applet/KeyHelperWidget.h
@@ -0,0 +1,75 @@
1#ifndef _KEY_HELPER_WIDGET_H_
2#define _KEY_HELPER_WIDGET_H_
3
4#include <qwidget.h>
5#include <qlabel.h>
6#include <qpixmap.h>
7#include <qtimer.h>
8#include <qaccel.h>
9#include <opie2/otaskbarapplet.h>
10#include <opie2/okeyfilter.h>
11
12#include <qpe/qcopenvelope_qws.h>
13#include <qpe/qpeapplication.h>
14#include <qpe/global.h>
15#include <qpe/resource.h>
16#include "KeyHelper.h"
17#include "AppLnkManager.h"
18#include "ConfigEx.h"
19
20#include <syslog.h>
21
22Q_EXPORT void MsgHandler(QtMsgType type, const char* msg);
23
24class KeyHelperWidget : public QLabel
25{
26 Q_OBJECT
27public:
28 KeyHelperWidget(QWidget* parent = 0, const char* name=0);
29 ~KeyHelperWidget();
30 static int position();
31
32 virtual bool eventFilter(QObject* o, QEvent* e);
33
34public slots:
35 //void windowEvent(QWSWindow* w, QWSServer::WindowEvent e);
36protected:
37 QCopChannel* m_pChannel;
38 QCopChannel* m_pSysChannel;
39 QPixmap disabled;
40
41protected slots:
42 void receiveMessage(const QCString& msg, const QByteArray& data);
43 void sysMessage(const QCString& msg, const QByteArray& data);
44 void reload();
45 void set();
46 void unset();
47 void init();
48 void mouseReleaseEvent(QMouseEvent*);
49
50private:
51 void loadUseFilterApps();
52 void enable();
53 void disable();
54 void pause();
55 void restart();
56 void version();
57 void setDebugLevel(int level);
58 void initDebugLevel();
59
60 bool m_reset;
61 bool m_useFilter;
62 bool m_status;
63 QString m_xmlfile;
64 msg_handler m_defHandler;
65 bool m_enable;
66 bool m_saved;
67 QStringList m_apps;
68 KeyHelper* m_pHelper;
69private slots:
70 void doReload(bool showstatus=true);
71 void doEvent(int,int,int,int,int);
72 void doEvent(const QString&, int);
73};
74
75#endif /* _KEY_HELPER_WIDGET_H_ */