mirror of
https://github.com/cmclark00/RetroMusicPlayer.git
synced 2025-05-19 16:45:20 +01:00
[Player] Fixed Show now playing not working
This commit is contained in:
parent
93277b8de7
commit
ba9c928588
5 changed files with 48 additions and 22 deletions
|
@ -1,7 +1,9 @@
|
|||
package code.name.monkey.retromusic.extensions
|
||||
|
||||
import androidx.core.view.WindowInsetsCompat
|
||||
import code.name.monkey.retromusic.util.RetroUtil
|
||||
|
||||
fun WindowInsetsCompat?.safeGetBottomInsets(): Int {
|
||||
return this?.getInsets(WindowInsetsCompat.Type.systemBars())?.bottom ?: 0
|
||||
// Get Navbar heights if insets are null
|
||||
return (this?.getInsets(WindowInsetsCompat.Type.systemBars())?.bottom ?: RetroUtil.getNavigationBarHeight())
|
||||
}
|
||||
|
|
|
@ -69,6 +69,7 @@ fun View.translateYAnimate(value: Float): Animator {
|
|||
duration = 300
|
||||
doOnStart {
|
||||
show()
|
||||
bringToFront()
|
||||
}
|
||||
doOnEnd {
|
||||
if (value != 0f) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue