mirror of
https://github.com/fork-maintainers/iceraven-browser
synced 2024-11-19 09:25:34 +00:00
[fenix] For https://github.com/mozilla-mobile/fenix/issues/2874, https://github.com/mozilla-mobile/fenix/issues/5375, https://github.com/mozilla-mobile/fenix/issues/5131 - submitList workaround for Android 5 + 6
This commit is contained in:
parent
4d975044c3
commit
3783f94347
@ -4,6 +4,7 @@
|
||||
|
||||
package org.mozilla.fenix.home.sessioncontrol
|
||||
|
||||
import android.os.Build
|
||||
import android.view.LayoutInflater
|
||||
import android.view.ViewGroup
|
||||
import androidx.recyclerview.widget.ItemTouchHelper
|
||||
@ -151,6 +152,10 @@ class SessionControlUIView(
|
||||
}
|
||||
|
||||
override fun updateView() = Consumer<SessionControlState> {
|
||||
// Workaround for list not updating until scroll on Android 5 + 6
|
||||
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.N) {
|
||||
sessionControlAdapter.submitList(null)
|
||||
}
|
||||
sessionControlAdapter.submitList(it.toAdapterList())
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user