mirror of
https://github.com/mihonapp/mihon.git
synced 2024-11-07 03:07:25 +01:00
Fix snackbars not being in viewport properly
This commit is contained in:
parent
88032e11df
commit
060f0682f4
@ -46,6 +46,7 @@ import eu.kanade.tachiyomi.util.view.shrinkOnScroll
|
||||
import eu.kanade.tachiyomi.util.view.snack
|
||||
import eu.kanade.tachiyomi.widget.AutofitRecyclerView
|
||||
import eu.kanade.tachiyomi.widget.EmptyView
|
||||
import kotlinx.android.synthetic.main.main_activity.root_coordinator
|
||||
import kotlinx.coroutines.Job
|
||||
import kotlinx.coroutines.flow.drop
|
||||
import kotlinx.coroutines.flow.filter
|
||||
@ -403,7 +404,7 @@ open class BrowseSourceController(bundle: Bundle) :
|
||||
|
||||
binding.emptyView.show(message, actions)
|
||||
} else {
|
||||
snack = binding.catalogueView.snack(message, Snackbar.LENGTH_INDEFINITE) {
|
||||
snack = activity!!.root_coordinator?.snack(message, Snackbar.LENGTH_INDEFINITE) {
|
||||
setAction(R.string.action_retry, retryAction)
|
||||
}
|
||||
}
|
||||
|
@ -152,8 +152,6 @@ class MainActivity : BaseActivity<MainActivityBinding>() {
|
||||
if (Migrations.upgrade(preferences) && !BuildConfig.DEBUG) {
|
||||
WhatsNewDialogController().showDialog(router)
|
||||
}
|
||||
|
||||
WhatsNewDialogController().showDialog(router)
|
||||
}
|
||||
|
||||
preferences.extensionUpdatesCount()
|
||||
|
@ -891,7 +891,7 @@ class MangaController :
|
||||
val manga = presenter.manga
|
||||
presenter.downloadChapters(chapters)
|
||||
if (view != null && !manga.favorite) {
|
||||
binding.recycler.snack(view.context.getString(R.string.snack_add_to_library), Snackbar.LENGTH_INDEFINITE) {
|
||||
activity!!.root_coordinator?.snack(view.context.getString(R.string.snack_add_to_library), Snackbar.LENGTH_INDEFINITE) {
|
||||
setAction(R.string.action_add) {
|
||||
addToLibrary(manga)
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user