Fix composerView having issues with long texts pasted from gboard clipboard
The pasted text would not properly fill the editText, but show moved up with empty space below instead. Change-Id: I82d2a0bafbb402ec0728f21075d4641fbce90890
This commit is contained in:
parent
2ff3989230
commit
ed89f7fb1b
|
@ -85,10 +85,12 @@ class TextComposerView @JvmOverloads constructor(
|
||||||
val shouldShowSendButton = currentConstraintSetId == R.layout.composer_layout_constraint_set_expanded || !isBlank || alwaysShowSendButton
|
val shouldShowSendButton = currentConstraintSetId == R.layout.composer_layout_constraint_set_expanded || !isBlank || alwaysShowSendButton
|
||||||
TransitionManager.endTransitions(this@TextComposerView)
|
TransitionManager.endTransitions(this@TextComposerView)
|
||||||
if (views.sendButton.isVisible != shouldShowSendButton) {
|
if (views.sendButton.isVisible != shouldShowSendButton) {
|
||||||
|
/* This causes some weird layout bug when using gboard clipboard to paste longer texts
|
||||||
TransitionManager.beginDelayedTransition(
|
TransitionManager.beginDelayedTransition(
|
||||||
this@TextComposerView,
|
this@TextComposerView,
|
||||||
AutoTransition().also { it.duration = 150 }
|
AutoTransition().also { it.duration = 150 }
|
||||||
)
|
)
|
||||||
|
*/
|
||||||
views.sendButton.isInvisible = !shouldShowSendButton
|
views.sendButton.isInvisible = !shouldShowSendButton
|
||||||
}
|
}
|
||||||
updateSendButtonColor(isBlank)
|
updateSendButtonColor(isBlank)
|
||||||
|
|
Loading…
Reference in New Issue