Merge "New Pipeline: resume spinning after RemoteInputView is moved"
This commit is contained in:
committed by
Android (Google) Code Review
commit
d00a8b52ee
@@ -118,6 +118,7 @@ public class RemoteInputView extends LinearLayout implements View.OnClickListene
|
||||
private boolean mColorized;
|
||||
private int mTint;
|
||||
private boolean mResetting;
|
||||
private boolean mWasSpinning;
|
||||
|
||||
// TODO(b/193539698): move these to a Controller
|
||||
private RemoteInputController mController;
|
||||
@@ -439,6 +440,10 @@ public class RemoteInputView extends LinearLayout implements View.OnClickListene
|
||||
mEditText.requestFocus();
|
||||
}
|
||||
}
|
||||
if (mWasSpinning) {
|
||||
mController.addSpinning(mEntry.getKey(), mToken);
|
||||
mWasSpinning = false;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -447,6 +452,7 @@ public class RemoteInputView extends LinearLayout implements View.OnClickListene
|
||||
mEditText.removeTextChangedListener(mTextWatcher);
|
||||
mEditText.setOnEditorActionListener(null);
|
||||
mEditText.mRemoteInputView = null;
|
||||
mWasSpinning = mController.isSpinning(mEntry.getKey(), mToken);
|
||||
if (mEntry.getRow().isChangingPosition() || isTemporarilyDetached()) {
|
||||
return;
|
||||
}
|
||||
@@ -533,6 +539,8 @@ public class RemoteInputView extends LinearLayout implements View.OnClickListene
|
||||
if (isActive() && mWrapper != null) {
|
||||
mWrapper.setRemoteInputVisible(true);
|
||||
}
|
||||
|
||||
mWasSpinning = false;
|
||||
}
|
||||
|
||||
private void reset() {
|
||||
|
||||
Reference in New Issue
Block a user