Stop active scroll when emoji category is tapped
This commit is contained in:
parent
967485bd44
commit
0ea9f39ce2
|
@ -1580,6 +1580,7 @@ class MyKeyboardView @JvmOverloads constructor(context: Context, attrs: Attribut
|
||||||
it.imageTintList = ColorStateList.valueOf(inactiveColor)
|
it.imageTintList = ColorStateList.valueOf(inactiveColor)
|
||||||
}
|
}
|
||||||
root.imageTintList = ColorStateList.valueOf(context.getProperPrimaryColor())
|
root.imageTintList = ColorStateList.valueOf(context.getProperPrimaryColor())
|
||||||
|
keyboardViewBinding?.emojisList?.stopScroll()
|
||||||
(keyboardViewBinding?.emojisList?.layoutManager as? GridLayoutManager)?.scrollToPositionWithOffset(
|
(keyboardViewBinding?.emojisList?.layoutManager as? GridLayoutManager)?.scrollToPositionWithOffset(
|
||||||
allItems.indexOfFirst { it is EmojisAdapter.Item.Category && it.value == category },
|
allItems.indexOfFirst { it is EmojisAdapter.Item.Category && it.value == category },
|
||||||
0
|
0
|
||||||
|
|
Loading…
Reference in New Issue