Diffstat (limited to 'inputmethods/jumpx/keyboard.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | inputmethods/jumpx/keyboard.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/inputmethods/jumpx/keyboard.cpp b/inputmethods/jumpx/keyboard.cpp index 0b8fc14..0cfb4be 100644 --- a/inputmethods/jumpx/keyboard.cpp +++ b/inputmethods/jumpx/keyboard.cpp | |||
@@ -103,48 +103,49 @@ static const uchar *const specialMapParen[] = { | |||
103 | (const uchar *const)"[]", | 103 | (const uchar *const)"[]", |
104 | (const uchar *const)"{}", | 104 | (const uchar *const)"{}", |
105 | (const uchar *const)"<>", | 105 | (const uchar *const)"<>", |
106 | (const uchar *const)"@~", | 106 | (const uchar *const)"@~", |
107 | }; | 107 | }; |
108 | 108 | ||
109 | static const uchar *const num2Map = (const uchar *const)"67890"; | 109 | static const uchar *const num2Map = (const uchar *const)"67890"; |
110 | 110 | ||
111 | static const mapElement mod2Map[] = { | 111 | static const mapElement mod2Map[] = { |
112 | { Qt::Key_Backspace, 8 }, | 112 | { Qt::Key_Backspace, 8 }, |
113 | { Qt::Key_Delete, 0 }, | 113 | { Qt::Key_Delete, 0 }, |
114 | { Qt::Key_Return, 13 }, | 114 | { Qt::Key_Return, 13 }, |
115 | { Qt::Key_Shift, 0 }, | 115 | { Qt::Key_Shift, 0 }, |
116 | { myParenID, 0 }, | 116 | { myParenID, 0 }, |
117 | }; | 117 | }; |
118 | 118 | ||
119 | static const int cursorMap[][2] = { | 119 | static const int cursorMap[][2] = { |
120 | { Qt::Key_Home, Qt::Key_PageUp }, | 120 | { Qt::Key_Home, Qt::Key_PageUp }, |
121 | { Qt::Key_End, Qt::Key_PageDown }, | 121 | { Qt::Key_End, Qt::Key_PageDown }, |
122 | { Qt::Key_Up, Qt::Key_Up }, | 122 | { Qt::Key_Up, Qt::Key_Up }, |
123 | { Qt::Key_Left, Qt::Key_Right }, | 123 | { Qt::Key_Left, Qt::Key_Right }, |
124 | { Qt::Key_Down, Qt::Key_Down }, | 124 | { Qt::Key_Down, Qt::Key_Down }, |
125 | }; | 125 | }; |
126 | 126 | ||
127 | using namespace JumpX; | ||
127 | 128 | ||
128 | Keyboard::Keyboard(QWidget* parent, const char* name, WFlags f) : | 129 | Keyboard::Keyboard(QWidget* parent, const char* name, WFlags f) : |
129 | QFrame(parent, name, f), | 130 | QFrame(parent, name, f), |
130 | shift(0), paren(0), ctrl(0), alt(0), | 131 | shift(0), paren(0), ctrl(0), alt(0), |
131 | pressedKeyUnicode(0), pressedKeyQcode(0), pressedMod(0), | 132 | pressedKeyUnicode(0), pressedKeyQcode(0), pressedMod(0), |
132 | isnoncont(false), | 133 | isnoncont(false), |
133 | slideKeyUnicodeH(0), slideKeyQcodeH(0), slideKeyUnicodeV(0), slideKeyQcodeV(0), | 134 | slideKeyUnicodeH(0), slideKeyQcodeH(0), slideKeyUnicodeV(0), slideKeyQcodeV(0), |
134 | enableMouseTracking(false), slidePix(NULL), slidePixH(NULL), slidePixV(NULL), | 135 | enableMouseTracking(false), slidePix(NULL), slidePixH(NULL), slidePixV(NULL), |
135 | releasedPix(NULL), pressedPix(NULL) | 136 | releasedPix(NULL), pressedPix(NULL) |
136 | { | 137 | { |
137 | //setPalette(QPalette(QColor(240,240,230))); // Beige! | 138 | //setPalette(QPalette(QColor(240,240,230))); // Beige! |
138 | 139 | ||
139 | releasedPlain = releasedShift = releasedParen = Resource::loadPixmap("jumpx/released"); | 140 | releasedPlain = releasedShift = releasedParen = Resource::loadPixmap("jumpx/released"); |
140 | pressedPlain = pressedShift = pressedParen = Resource::loadPixmap("jumpx/pressed"); | 141 | pressedPlain = pressedShift = pressedParen = Resource::loadPixmap("jumpx/pressed"); |
141 | pressedDigit = Resource::loadPixmap("jumpx/pressed"); | 142 | pressedDigit = Resource::loadPixmap("jumpx/pressed"); |
142 | 143 | ||
143 | QPixmap tmp; | 144 | QPixmap tmp; |
144 | 145 | ||
145 | tmp = Resource::loadPixmap("jumpx/releasedShift"); | 146 | tmp = Resource::loadPixmap("jumpx/releasedShift"); |
146 | bitBlt(&releasedShift, letterx1, 0, &tmp); | 147 | bitBlt(&releasedShift, letterx1, 0, &tmp); |
147 | 148 | ||
148 | tmp = Resource::loadPixmap("jumpx/releasedParen"); | 149 | tmp = Resource::loadPixmap("jumpx/releasedParen"); |
149 | bitBlt(&releasedParen, specialx1, 0, &tmp); | 150 | bitBlt(&releasedParen, specialx1, 0, &tmp); |
150 | 151 | ||