From 5ceae026e0dad7d71372bcb3fa4d992094d669a7 Mon Sep 17 00:00:00 2001 From: Satoshi Kataoka Date: Tue, 1 Oct 2013 22:20:56 +0900 Subject: [PATCH] Retain Emoji Keyboard after rotation Bug: 10612450 Change-Id: Ie0ae953958d2b0a0a4da651584f1e28b0ba38ae3 --- .../com/android/inputmethod/keyboard/EmojiLayoutParams.java | 4 +--- .../com/android/inputmethod/keyboard/KeyboardSwitcher.java | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/java/src/com/android/inputmethod/keyboard/EmojiLayoutParams.java b/java/src/com/android/inputmethod/keyboard/EmojiLayoutParams.java index 267fad5cd..71790b7d6 100644 --- a/java/src/com/android/inputmethod/keyboard/EmojiLayoutParams.java +++ b/java/src/com/android/inputmethod/keyboard/EmojiLayoutParams.java @@ -75,9 +75,7 @@ public class EmojiLayoutParams { public void setActionBarProperties(LinearLayout ll) { final LinearLayout.LayoutParams lp = (LinearLayout.LayoutParams) ll.getLayoutParams(); - lp.height = mEmojiActionBarHeight; - lp.topMargin = 0; - lp.bottomMargin = mBottomPadding; + lp.height = mEmojiActionBarHeight - mBottomPadding; ll.setLayoutParams(lp); } diff --git a/java/src/com/android/inputmethod/keyboard/KeyboardSwitcher.java b/java/src/com/android/inputmethod/keyboard/KeyboardSwitcher.java index 74edd87cf..ad6e2c0f2 100644 --- a/java/src/com/android/inputmethod/keyboard/KeyboardSwitcher.java +++ b/java/src/com/android/inputmethod/keyboard/KeyboardSwitcher.java @@ -155,7 +155,7 @@ public final class KeyboardSwitcher implements KeyboardState.SwitchActions { } public void saveKeyboardState() { - if (getKeyboard() != null) { + if (getKeyboard() != null || isShowingEmojiKeyboard()) { mState.onSaveKeyboardState(); } }