Skip to content

Commit 1bcab95

Browse files
committed
Update placeholder color on theme change
1 parent 364d773 commit 1bcab95

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

app/src/main/kotlin/com/simplemobiletools/musicplayer/adapters/BaseMusicAdapter.kt

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@ abstract class BaseMusicAdapter<Type>(
3030

3131
var textToHighlight = ""
3232
val tagHelper by lazy { TagHelper(context) }
33-
val placeholder by lazy { resources.getSmallPlaceholder(textColor) }
34-
val placeholderBig by lazy { resources.getBiggerPlaceholder(textColor) }
33+
var placeholder = resources.getSmallPlaceholder(textColor)
34+
var placeholderBig = resources.getBiggerPlaceholder(textColor)
3535
open val cornerRadius by lazy { resources.getDimension(com.simplemobiletools.commons.R.dimen.rounded_corner_radius_small).toInt() }
3636

3737
init {
@@ -164,6 +164,8 @@ abstract class BaseMusicAdapter<Type>(
164164
if (textColor != newTextColor || properPrimaryColor != context.getProperPrimaryColor()) {
165165
updateTextColor(newTextColor)
166166
updatePrimaryColor()
167+
placeholder = resources.getSmallPlaceholder(textColor)
168+
placeholderBig = resources.getBiggerPlaceholder(textColor)
167169
notifyDataChanged()
168170
}
169171
}

0 commit comments

Comments
 (0)