Diffstat (limited to 'core/applets/multikeyapplet/multikey.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | core/applets/multikeyapplet/multikey.cpp | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/core/applets/multikeyapplet/multikey.cpp b/core/applets/multikeyapplet/multikey.cpp index b36ee12..b17498d 100644 --- a/core/applets/multikeyapplet/multikey.cpp +++ b/core/applets/multikeyapplet/multikey.cpp | |||
@@ -1,52 +1,46 @@ | |||
1 | /********************************************************************** | 1 | /********************************************************************** |
2 | ** Copyright (C) 2004 Anton Kachalov mouse@altlinux.ru | 2 | ** Copyright (C) 2004 Anton Kachalov mouse@altlinux.ru |
3 | ** All rights reserved. | 3 | ** All rights reserved. |
4 | ** | 4 | ** |
5 | ** This file may be distributed and/or modified under the terms of the | 5 | ** This file may be distributed and/or modified under the terms of the |
6 | ** GNU General Public License version 2 as published by the Free Software | 6 | ** GNU General Public License version 2 as published by the Free Software |
7 | ** Foundation and appearing in the file LICENSE.GPL included in the | 7 | ** Foundation and appearing in the file LICENSE.GPL included in the |
8 | ** packaging of this file. | 8 | ** packaging of this file. |
9 | ** | 9 | ** |
10 | ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE | 10 | ** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE |
11 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. | 11 | ** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. |
12 | ** | 12 | ** |
13 | **********************************************************************/ | 13 | **********************************************************************/ |
14 | 14 | ||
15 | #include "multikey.h" | 15 | #include "multikey.h" |
16 | 16 | ||
17 | /* OPIE */ | 17 | /* OPIE */ |
18 | #include <opie2/otaskbarapplet.h> | 18 | #include <opie2/otaskbarapplet.h> |
19 | #include <qpe/global.h> | ||
20 | #include <qpe/config.h> | ||
21 | #include <qpe/qcopenvelope_qws.h> | 19 | #include <qpe/qcopenvelope_qws.h> |
22 | #include <qpe/qpeapplication.h> | ||
23 | 20 | ||
24 | /* QT */ | 21 | /* QT */ |
25 | #include <qlabel.h> | ||
26 | #include <qdir.h> | 22 | #include <qdir.h> |
27 | #include <qfileinfo.h> | ||
28 | #include <qcopchannel_qws.h> | ||
29 | 23 | ||
30 | Multikey::Multikey(QWidget *parent) : QLabel(parent), popupMenu(this), current("EN") | 24 | Multikey::Multikey(QWidget *parent) : QLabel(parent), popupMenu(this), current("EN") |
31 | { | 25 | { |
32 | QCopChannel* swChannel = new QCopChannel("MultiKey/Switcher", this); | 26 | QCopChannel* swChannel = new QCopChannel("MultiKey/Switcher", this); |
33 | connect( swChannel, SIGNAL(received(const QCString &, const QByteArray &)), | 27 | connect( swChannel, SIGNAL(received(const QCString &, const QByteArray &)), |
34 | this, SLOT(message(const QCString &, const QByteArray &))); | 28 | this, SLOT(message(const QCString &, const QByteArray &))); |
35 | 29 | ||
36 | setFont( QFont( "Helvetica", 10, QFont::Normal ) ); | 30 | setFont( QFont( "Helvetica", 10, QFont::Normal ) ); |
37 | QPEApplication::setStylusOperation(this, QPEApplication::RightOnHold); | 31 | QPEApplication::setStylusOperation(this, QPEApplication::RightOnHold); |
38 | lang = 0; | 32 | lang = 0; |
39 | QCopEnvelope e("MultiKey/Keyboard", "getmultikey()"); | 33 | QCopEnvelope e("MultiKey/Keyboard", "getmultikey()"); |
40 | setText("EN"); | 34 | setText("EN"); |
41 | popupMenu.insertItem("EN", 0); | 35 | popupMenu.insertItem("EN", 0); |
42 | show(); | 36 | show(); |
43 | } | 37 | } |
44 | 38 | ||
45 | void Multikey::mousePressEvent(QMouseEvent *ev) | 39 | void Multikey::mousePressEvent(QMouseEvent *ev) |
46 | { | 40 | { |
47 | if (!sw_maps.count()) | 41 | if (!sw_maps.count()) |
48 | return; | 42 | return; |
49 | 43 | ||
50 | if (ev->button() == RightButton) { | 44 | if (ev->button() == RightButton) { |
51 | 45 | ||
52 | QPoint p = mapToGlobal(QPoint(0, 0)); | 46 | QPoint p = mapToGlobal(QPoint(0, 0)); |