Merge "RemoteInputView: Add null check in WindowInsetsAnimation.Callback" into tm-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
c9a1ec32a3
@@ -269,8 +269,12 @@ public class RemoteInputView extends LinearLayout implements View.OnClickListene
|
|||||||
super.onEnd(animation);
|
super.onEnd(animation);
|
||||||
if (animation.getTypeMask() == WindowInsets.Type.ime()) {
|
if (animation.getTypeMask() == WindowInsets.Type.ime()) {
|
||||||
mEntry.mRemoteEditImeAnimatingAway = false;
|
mEntry.mRemoteEditImeAnimatingAway = false;
|
||||||
mEntry.mRemoteEditImeVisible =
|
WindowInsets editTextRootWindowInsets = mEditText.getRootWindowInsets();
|
||||||
mEditText.getRootWindowInsets().isVisible(WindowInsets.Type.ime());
|
if (editTextRootWindowInsets == null) {
|
||||||
|
Log.w(TAG, "onEnd called on detached view", new Exception());
|
||||||
|
}
|
||||||
|
mEntry.mRemoteEditImeVisible = editTextRootWindowInsets != null
|
||||||
|
&& editTextRootWindowInsets.isVisible(WindowInsets.Type.ime());
|
||||||
if (!mEntry.mRemoteEditImeVisible && !mEditText.mShowImeOnInputConnection) {
|
if (!mEntry.mRemoteEditImeVisible && !mEditText.mShowImeOnInputConnection) {
|
||||||
mController.removeRemoteInput(mEntry, mToken);
|
mController.removeRemoteInput(mEntry, mToken);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user