diff options
author | 2014-08-16 14:07:14 +0000 | |
---|---|---|
committer | 2014-08-16 14:07:14 +0000 | |
commit | e260d62e0fed308eba8d1e8671d6afa2936bba66 (patch) | |
tree | 7deac371fa474ebc2b8a8ebe7d01cf38813c9f74 /java | |
parent | 1d3732b6e82f1beed771a293b2c8a69db67e662b (diff) | |
parent | c9240d280c2a49ed09069be36a0e3dae05ac0e69 (diff) | |
download | latinime-e260d62e0fed308eba8d1e8671d6afa2936bba66.tar.gz latinime-e260d62e0fed308eba8d1e8671d6afa2936bba66.tar.xz latinime-e260d62e0fed308eba8d1e8671d6afa2936bba66.zip |
am c9240d28: am 18ac3c8a: am 16a43d2b: Let the backing view cover the entire content area
* commit 'c9240d280c2a49ed09069be36a0e3dae05ac0e69':
Let the backing view cover the entire content area
Diffstat (limited to 'java')
3 files changed, 8 insertions, 7 deletions
diff --git a/java/src/com/android/inputmethod/latin/LatinIME.java b/java/src/com/android/inputmethod/latin/LatinIME.java index 71fd10e83..258f21f7c 100644 --- a/java/src/com/android/inputmethod/latin/LatinIME.java +++ b/java/src/com/android/inputmethod/latin/LatinIME.java @@ -1089,7 +1089,10 @@ public class LatinIME extends InputMethodService implements KeyboardActionListen - keyboardHeight; final LayoutParams params = mKeyPreviewBackingView.getLayoutParams(); - params.height = mSuggestionStripView.setMoreSuggestionsHeight(remainingHeight); + mSuggestionStripView.setMoreSuggestionsHeight(remainingHeight); + + // Let the backing cover the remaining region entirely. + params.height = remainingHeight; mKeyPreviewBackingView.setLayoutParams(params); return params.height; } diff --git a/java/src/com/android/inputmethod/latin/suggestions/SuggestionStripLayoutHelper.java b/java/src/com/android/inputmethod/latin/suggestions/SuggestionStripLayoutHelper.java index c5f062d5b..7307ca1ba 100644 --- a/java/src/com/android/inputmethod/latin/suggestions/SuggestionStripLayoutHelper.java +++ b/java/src/com/android/inputmethod/latin/suggestions/SuggestionStripLayoutHelper.java @@ -167,16 +167,14 @@ final class SuggestionStripLayoutHelper { return mMaxMoreSuggestionsRow * mMoreSuggestionsRowHeight + mMoreSuggestionsBottomGap; } - public int setMoreSuggestionsHeight(final int remainingHeight) { + public void setMoreSuggestionsHeight(final int remainingHeight) { final int currentHeight = getMoreSuggestionsHeight(); if (currentHeight <= remainingHeight) { - return currentHeight; + return; } mMaxMoreSuggestionsRow = (remainingHeight - mMoreSuggestionsBottomGap) / mMoreSuggestionsRowHeight; - final int newHeight = getMoreSuggestionsHeight(); - return newHeight; } private static Drawable getMoreSuggestionsHint(final Resources res, final float textSize, diff --git a/java/src/com/android/inputmethod/latin/suggestions/SuggestionStripView.java b/java/src/com/android/inputmethod/latin/suggestions/SuggestionStripView.java index 6c4d80ecb..9b8c38a2d 100644 --- a/java/src/com/android/inputmethod/latin/suggestions/SuggestionStripView.java +++ b/java/src/com/android/inputmethod/latin/suggestions/SuggestionStripView.java @@ -219,8 +219,8 @@ public final class SuggestionStripView extends RelativeLayout implements OnClick mStripVisibilityGroup.showSuggestionsStrip(); } - public int setMoreSuggestionsHeight(final int remainingHeight) { - return mLayoutHelper.setMoreSuggestionsHeight(remainingHeight); + public void setMoreSuggestionsHeight(final int remainingHeight) { + mLayoutHelper.setMoreSuggestionsHeight(remainingHeight); } public boolean isShowingAddToDictionaryHint() { |