diff options
Diffstat (limited to 'java/src/com/android/inputmethod')
-rw-r--r-- | java/src/com/android/inputmethod/keyboard/Key.java | 10 | ||||
-rw-r--r-- | java/src/com/android/inputmethod/keyboard/KeyboardParser.java | 2 |
2 files changed, 6 insertions, 6 deletions
diff --git a/java/src/com/android/inputmethod/keyboard/Key.java b/java/src/com/android/inputmethod/keyboard/Key.java index eccd0c822..98a7f98c2 100644 --- a/java/src/com/android/inputmethod/keyboard/Key.java +++ b/java/src/com/android/inputmethod/keyboard/Key.java @@ -216,11 +216,11 @@ public class Key { if (keyXPos < 0) { // If keyXPos is negative, the actual x-coordinate will be k + keyXPos. keyXPos += keyboardWidth; - if (keyXPos < x) { - // keyXPos shouldn't be less than x because drawable area for this key starts - // at x. Or, this key will overlaps the adjacent key on its left hand side. - keyXPos = x; - } + } + if (keyXPos < x) { + // keyXPos shouldn't be less than x because drawable area for this key starts + // at x. Or, this key will overlaps the adjacent key on its left hand side. + keyXPos = x; } if (keyWidth == 0) { // If keyWidth is zero, the actual key width will be determined to fill out the diff --git a/java/src/com/android/inputmethod/keyboard/KeyboardParser.java b/java/src/com/android/inputmethod/keyboard/KeyboardParser.java index 308651a9e..e599dfdef 100644 --- a/java/src/com/android/inputmethod/keyboard/KeyboardParser.java +++ b/java/src/com/android/inputmethod/keyboard/KeyboardParser.java @@ -549,7 +549,7 @@ public class KeyboardParser { } private void endKey(Key key) { - mCurrentX = key.mX + key.mGap + key.mWidth; + mCurrentX = key.mX - key.mGap / 2 + key.mWidth + key.mGap; if (mCurrentX > mMaxRowWidth) mMaxRowWidth = mCurrentX; } |