mirror of
https://github.com/SchildiChat/SchildiChat-android.git
synced 2024-11-22 17:35:54 +03:00
Fix / crash not called on UI Thread
This commit is contained in:
parent
2a2431e490
commit
2eee25bbc1
1 changed files with 7 additions and 3 deletions
|
@ -45,7 +45,9 @@ object PopupAlertManager {
|
|||
synchronized(alertFiFo) {
|
||||
alertFiFo.add(alert)
|
||||
}
|
||||
displayNextIfPossible()
|
||||
weakCurrentActivity?.get()?.runOnUiThread {
|
||||
displayNextIfPossible()
|
||||
}
|
||||
}
|
||||
|
||||
fun cancelAlert(uid: String) {
|
||||
|
@ -62,8 +64,10 @@ object PopupAlertManager {
|
|||
|
||||
//it could also be the current one
|
||||
if (currentAlerter?.uid == uid) {
|
||||
Alerter.hide()
|
||||
currentIsDismissed()
|
||||
weakCurrentActivity?.get()?.runOnUiThread {
|
||||
Alerter.hide()
|
||||
currentIsDismissed()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue