kopia lustrzana https://github.com/ryukoposting/Signal-Android
Fix crash with sticker availability change.
rodzic
b081452bed
commit
007e8a9dca
|
@ -36,13 +36,13 @@ class KeyboardPagerViewModel : ViewModel() {
|
|||
fun pages(): LiveData<Set<KeyboardPage>> = pages
|
||||
|
||||
fun setOnlyPage(page: KeyboardPage) {
|
||||
pages.value = setOf(page)
|
||||
pages.postValue(setOf(page))
|
||||
switchToPage(page)
|
||||
}
|
||||
|
||||
fun switchToPage(page: KeyboardPage) {
|
||||
if (this.pages.value.contains(page) && this.page.value != page) {
|
||||
this.page.value = page
|
||||
this.page.postValue(page)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Ładowanie…
Reference in New Issue