mirror of
https://github.com/libre-tube/LibreTube.git
synced 2025-04-28 07:50:31 +05:30
commit
8c5a34861c
@ -116,17 +116,17 @@ class ChannelFragment : Fragment() {
|
||||
colorPrimary,
|
||||
true)
|
||||
|
||||
val ColorText = TypedValue()
|
||||
val colorText = TypedValue()
|
||||
(context as Activity).theme.resolveAttribute(
|
||||
R.attr.colorOnSurface,
|
||||
ColorText,
|
||||
colorText,
|
||||
true)
|
||||
|
||||
runOnUiThread {
|
||||
if (response.subscribed==true){
|
||||
isSubscribed=true
|
||||
button.text=getString(R.string.unsubscribe)
|
||||
button.setTextColor(ColorText.data)
|
||||
button.setTextColor(colorText.data)
|
||||
|
||||
}
|
||||
if(response.subscribed!=null){
|
||||
@ -140,7 +140,7 @@ class ChannelFragment : Fragment() {
|
||||
}else{
|
||||
subscribe()
|
||||
button.text=getString(R.string.unsubscribe)
|
||||
button.setTextColor(ColorText.data)
|
||||
button.setTextColor(colorText.data)
|
||||
}
|
||||
}}
|
||||
}
|
||||
|
@ -651,10 +651,10 @@ class PlayerFragment : Fragment() {
|
||||
true
|
||||
)
|
||||
|
||||
val ColorText = TypedValue()
|
||||
val colorText = TypedValue()
|
||||
(context as Activity).theme.resolveAttribute(
|
||||
R.attr.colorOnSurface,
|
||||
ColorText,
|
||||
colorText,
|
||||
true
|
||||
)
|
||||
|
||||
@ -662,7 +662,7 @@ class PlayerFragment : Fragment() {
|
||||
if (response.subscribed == true) {
|
||||
isSubscribed = true
|
||||
button.text = getString(R.string.unsubscribe)
|
||||
button.setTextColor(ColorText.data)
|
||||
button.setTextColor(colorText.data)
|
||||
}
|
||||
if (response.subscribed != null) {
|
||||
button.setOnClickListener {
|
||||
@ -673,7 +673,7 @@ class PlayerFragment : Fragment() {
|
||||
} else {
|
||||
subscribe(channel_id)
|
||||
button.text = getString(R.string.unsubscribe)
|
||||
button.setTextColor(colorPrimary.data)
|
||||
button.setTextColor(colorText.data)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user