diff options
author | 2010-10-12 16:16:38 +0900 | |
---|---|---|
committer | 2010-10-14 19:52:46 +0900 | |
commit | 179fa2c03e749df736f43e0838200bec52b4808a (patch) | |
tree | 09a614949bb1bf0a0da4d4dae92f7e457e346df6 /java/src/com/android/inputmethod/latin/LatinKeyboardBaseView.java | |
parent | 3d20d999025bbaab96b41d172225a39f7a1017b7 (diff) | |
download | latinime-179fa2c03e749df736f43e0838200bec52b4808a.tar.gz latinime-179fa2c03e749df736f43e0838200bec52b4808a.tar.xz latinime-179fa2c03e749df736f43e0838200bec52b4808a.zip |
DO NOT MERGE. Add visual indicator that long press , or mic key will bring up Settings
bug:3084022
Change-Id: I8b38e2803eb32469653484701882af35108eb69a
Diffstat (limited to '')
-rw-r--r-- | java/src/com/android/inputmethod/latin/LatinKeyboardBaseView.java | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/java/src/com/android/inputmethod/latin/LatinKeyboardBaseView.java b/java/src/com/android/inputmethod/latin/LatinKeyboardBaseView.java index 9ff7b9aef..b3f1364d8 100644 --- a/java/src/com/android/inputmethod/latin/LatinKeyboardBaseView.java +++ b/java/src/com/android/inputmethod/latin/LatinKeyboardBaseView.java @@ -847,7 +847,7 @@ public class LatinKeyboardBaseView extends View implements PointerTracker.UIProx // Usually don't draw icon if label is not null, but we draw icon for the number // hint. - shouldDrawIcon = isNumberAtEdgeOfPopupChars(key); + shouldDrawIcon = isCommaKeyLabelOrNumberAtEdgeOfPopupChars(key); } if (key.icon != null && shouldDrawIcon) { // Special handing for the upper-right number hint icons @@ -940,7 +940,7 @@ public class LatinKeyboardBaseView extends View implements PointerTracker.UIProx if (key == null) return; // Should not draw number hint icons - if (key.icon != null && !isNumberAtEdgeOfPopupChars(key)) { + if (key.icon != null && !isCommaKeyLabelOrNumberAtEdgeOfPopupChars(key)) { mPreviewText.setCompoundDrawables(null, null, null, key.iconPreview != null ? key.iconPreview : key.icon); mPreviewText.setText(null); @@ -1221,6 +1221,14 @@ public class LatinKeyboardBaseView extends View implements PointerTracker.UIProx return false; } + private static boolean isCommaKeyLabelOrNumberAtEdgeOfPopupChars(Key key) { + return isNumberAtEdgeOfPopupChars(key) || isCommaKeyLabel(key); + } + + private static boolean isCommaKeyLabel(Key key) { + return ",".equals(key.label); + } + private static boolean isNumberAtEdgeOfPopupChars(Key key) { return isNumberAtLeftmostPopupChar(key) || isNumberAtRightmostPopupChar(key); } |