mirror of
https://github.com/recloudstream/cloudstream.git
synced 2024-08-15 01:53:11 +00:00
settings selectable in tv mode
This commit is contained in:
parent
276cb78669
commit
57128dbc7d
1 changed files with 18 additions and 21 deletions
|
@ -94,28 +94,25 @@ class SettingsFragment : Fragment() {
|
||||||
activity?.navigate(id, Bundle())
|
activity?.navigate(id, Bundle())
|
||||||
}
|
}
|
||||||
|
|
||||||
settings_player?.setOnClickListener {
|
val isTrueTv = context?.isTrueTvSettings() == true
|
||||||
navigate(R.id.action_navigation_settings_to_navigation_settings_player)
|
|
||||||
}
|
|
||||||
|
|
||||||
settings_credits?.setOnClickListener {
|
listOf(
|
||||||
navigate(R.id.action_navigation_settings_to_navigation_settings_account)
|
Pair(settings_player, R.id.action_navigation_settings_to_navigation_settings_player),
|
||||||
}
|
Pair(settings_credits, R.id.action_navigation_settings_to_navigation_settings_account),
|
||||||
|
Pair(settings_ui, R.id.action_navigation_settings_to_navigation_settings_ui),
|
||||||
settings_ui?.setOnClickListener {
|
Pair(settings_lang, R.id.action_navigation_settings_to_navigation_settings_lang),
|
||||||
navigate(R.id.action_navigation_settings_to_navigation_settings_ui)
|
Pair(settings_nginx, R.id.action_navigation_settings_to_navigation_settings_nginx),
|
||||||
}
|
Pair(settings_updates, R.id.action_navigation_settings_to_navigation_settings_updates),
|
||||||
|
).forEach { (view, navigationId) ->
|
||||||
settings_lang?.setOnClickListener {
|
view?.apply {
|
||||||
navigate(R.id.action_navigation_settings_to_navigation_settings_lang)
|
setOnClickListener {
|
||||||
}
|
navigate(navigationId)
|
||||||
|
}
|
||||||
settings_nginx?.setOnClickListener {
|
if (isTrueTv) {
|
||||||
navigate(R.id.action_navigation_settings_to_navigation_settings_nginx)
|
isFocusable = true
|
||||||
}
|
isFocusableInTouchMode = true
|
||||||
|
}
|
||||||
settings_updates?.setOnClickListener {
|
}
|
||||||
navigate(R.id.action_navigation_settings_to_navigation_settings_updates)
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Reference in a new issue