-rw-r--r-- | inputmethods/multikey/keyboard.cpp | 1 | ||||
-rw-r--r-- | inputmethods/multikey/keyboard.h | 5 | ||||
-rw-r--r-- | inputmethods/multikey/keyboardimpl.cpp | 4 | ||||
-rw-r--r-- | inputmethods/multikey/keyboardimpl.h | 13 |
4 files changed, 18 insertions, 5 deletions
diff --git a/inputmethods/multikey/keyboard.cpp b/inputmethods/multikey/keyboard.cpp index 84c0c74..c22fbb1 100644 --- a/inputmethods/multikey/keyboard.cpp +++ b/inputmethods/multikey/keyboard.cpp @@ -34,12 +34,13 @@ #include <qfile.h> #include <qtextstream.h> #include <qstringlist.h> #include <sys/utsname.h> +using namespace MultiKey; /* Keyboard::Keyboard {{{1 */ Keyboard::Keyboard(QWidget* parent, const char* _name, WFlags f) : QFrame(parent, _name, f), shift(0), lock(0), ctrl(0), alt(0), meta(0), circumflex(0), diaeresis(0), baccent(0), accent(0), useLargeKeys(TRUE), usePicks(0), useRepeat(0), diff --git a/inputmethods/multikey/keyboard.h b/inputmethods/multikey/keyboard.h index bc74e71..20c5cee 100644 --- a/inputmethods/multikey/keyboard.h +++ b/inputmethods/multikey/keyboard.h @@ -22,12 +22,15 @@ #include "../pickboard/pickboardcfg.h" #include "../pickboard/pickboardpicks.h" #include "configdlg.h" class QTimer; +namespace MultiKey +{ + class KeyboardConfig : public DictFilterConfig { public: KeyboardConfig(PickboardPicks* p) : DictFilterConfig(p), backspaces(0) { nrows = 1; } virtual void generateText(const QString &s); void decBackspaces() { if (backspaces) backspaces--; } @@ -182,7 +185,7 @@ private: QColor keycolor_lines; QColor textcolor; ConfigDlg *configdlg; }; - +} // namespace MultiKey diff --git a/inputmethods/multikey/keyboardimpl.cpp b/inputmethods/multikey/keyboardimpl.cpp index cebd43d..4cfbcd5 100644 --- a/inputmethods/multikey/keyboardimpl.cpp +++ b/inputmethods/multikey/keyboardimpl.cpp @@ -20,13 +20,13 @@ #include <qapplication.h> #include <qpixmap.h> #include "keyboard.h" #include "keyboardimpl.h" /* XPM */ -static const char * kb_xpm[] = { +static const char * const kb_xpm[] = { "28 13 4 1", " c None", ". c #4C4C4C", "+ c #FFF7DD", "@ c #D6CFBA", " .......................... ", @@ -55,13 +55,13 @@ KeyboardImpl::~KeyboardImpl() delete icn; } QWidget *KeyboardImpl::inputMethod( QWidget *parent, Qt::WFlags f ) { if ( !input ) - input = new Keyboard( parent, "Keyboard", f ); + input = new MultiKey::Keyboard( parent, "Keyboard", f ); return input; } void KeyboardImpl::resetState() { if ( input ) diff --git a/inputmethods/multikey/keyboardimpl.h b/inputmethods/multikey/keyboardimpl.h index e756364..76a2955 100644 --- a/inputmethods/multikey/keyboardimpl.h +++ b/inputmethods/multikey/keyboardimpl.h @@ -19,15 +19,22 @@ **********************************************************************/ #ifndef KEYBOARDIMPL_H #define KEYBOARDIMPL_H #include <qpe/inputmethodinterface.h> -class Keyboard; +namespace MultiKey +{ + class Keyboard; +} + class QPixmap; +namespace +{ + class KeyboardImpl : public InputMethodInterface { public: KeyboardImpl(); virtual ~KeyboardImpl(); @@ -40,12 +47,14 @@ public: virtual void resetState(); virtual QPixmap *icon(); virtual QString name(); virtual void onKeyPress( QObject *receiver, const char *slot ); private: - Keyboard *input; + MultiKey::Keyboard *input; QPixmap *icn; ulong ref; }; +} // anonymous namespace + #endif |