Fixed Color Fragment crash
This commit is contained in:
parent
348dc08f73
commit
b0de3006a4
1 changed files with 5 additions and 8 deletions
|
@ -16,7 +16,6 @@ package code.name.monkey.retromusic.fragments.player.color
|
||||||
|
|
||||||
import android.animation.ValueAnimator
|
import android.animation.ValueAnimator
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
import android.os.Handler
|
|
||||||
import android.view.View
|
import android.view.View
|
||||||
import androidx.appcompat.widget.Toolbar
|
import androidx.appcompat.widget.Toolbar
|
||||||
import androidx.core.animation.doOnEnd
|
import androidx.core.animation.doOnEnd
|
||||||
|
@ -61,14 +60,12 @@ class ColorFragment : AbsPlayerFragment(R.layout.fragment_color_player) {
|
||||||
_binding?.root?.setBackgroundColor(color.backgroundColor)
|
_binding?.root?.setBackgroundColor(color.backgroundColor)
|
||||||
}
|
}
|
||||||
animator.start()
|
animator.start()
|
||||||
Handler().post {
|
|
||||||
ToolbarContentTintHelper.colorizeToolbar(
|
ToolbarContentTintHelper.colorizeToolbar(
|
||||||
binding.playerToolbar,
|
binding.playerToolbar,
|
||||||
color.secondaryTextColor,
|
color.secondaryTextColor,
|
||||||
requireActivity()
|
requireActivity()
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
override fun onFavoriteToggled() {
|
override fun onFavoriteToggled() {
|
||||||
toggleFavorite(MusicPlayerRemote.currentSong)
|
toggleFavorite(MusicPlayerRemote.currentSong)
|
||||||
|
|
Loading…
Reference in a new issue