Merge "Prevent duplicated registration of OnComputeInternalInsetsListener"

automerge: efd9abb

* commit 'efd9abb7dfd8d5015e73ab52b4f9b7854df4b02c':
  Prevent duplicated registration of OnComputeInternalInsetsListener
This commit is contained in:
Yohei Yukawa
2015-02-14 15:11:37 +00:00
committed by android-build-merger

View File

@@ -708,6 +708,7 @@ public class InputMethodService extends AbstractInputMethodService {
mRootView.setSystemUiVisibility(
View.SYSTEM_UI_FLAG_LAYOUT_STABLE | View.SYSTEM_UI_FLAG_LAYOUT_HIDE_NAVIGATION);
mWindow.setContentView(mRootView);
mRootView.getViewTreeObserver().removeOnComputeInternalInsetsListener(mInsetsComputer);
mRootView.getViewTreeObserver().addOnComputeInternalInsetsListener(mInsetsComputer);
if (Settings.Global.getInt(getContentResolver(),
Settings.Global.FANCY_IME_ANIMATIONS, 0) != 0) {