mirror of
https://github.com/recloudstream/cloudstream.git
synced 2024-08-15 01:53:11 +00:00
use no focus tag from strings
This commit is contained in:
parent
976f7c1e69
commit
f8ef06dc64
3 changed files with 5 additions and 4 deletions
|
@ -61,6 +61,7 @@ import com.lagradost.cloudstream3.APIHolder.apis
|
|||
import com.lagradost.cloudstream3.APIHolder.getApiDubstatusSettings
|
||||
import com.lagradost.cloudstream3.APIHolder.initAll
|
||||
import com.lagradost.cloudstream3.APIHolder.updateHasTrailers
|
||||
import com.lagradost.cloudstream3.AcraApplication.Companion.context
|
||||
import com.lagradost.cloudstream3.AcraApplication.Companion.getKey
|
||||
import com.lagradost.cloudstream3.AcraApplication.Companion.removeKey
|
||||
import com.lagradost.cloudstream3.AcraApplication.Companion.setKey
|
||||
|
@ -1185,7 +1186,7 @@ class MainActivity : AppCompatActivity(), ColorPickerDialogListener {
|
|||
|
||||
if(isTrueTvSettings()) {
|
||||
newLocalBinding.root.viewTreeObserver.addOnGlobalFocusChangeListener { _, newFocus ->
|
||||
if (newFocus?.tag == "tv_no_focus_tag") return@addOnGlobalFocusChangeListener
|
||||
if (newFocus?.tag == context?.getString(R.string.tv_no_focus_tag)) return@addOnGlobalFocusChangeListener
|
||||
centerView(newFocus)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -253,7 +253,7 @@ class ResultFragmentTv : Fragment() {
|
|||
val leftListener: View.OnFocusChangeListener =
|
||||
View.OnFocusChangeListener { view, hasFocus ->
|
||||
if (!hasFocus) return@OnFocusChangeListener
|
||||
if (view?.tag == "tv_no_focus_tag"){
|
||||
if (view?.tag == context?.getString(R.string.tv_no_focus_tag)){
|
||||
resultFinishLoading.scrollTo(0,0)
|
||||
}
|
||||
toggleEpisodes(false)
|
||||
|
|
|
@ -157,7 +157,7 @@
|
|||
android:id="@+id/home_preview_hidden_prev_focus"
|
||||
android:layout_width="1dp"
|
||||
android:layout_height="1dp"
|
||||
android:tag="tv_no_focus_tag"
|
||||
android:tag="@string/tv_no_focus_tag"
|
||||
android:focusable="false" />
|
||||
|
||||
<com.google.android.material.button.MaterialButton
|
||||
|
@ -190,7 +190,7 @@
|
|||
android:id="@+id/home_preview_hidden_next_focus"
|
||||
android:layout_width="1dp"
|
||||
android:layout_height="1dp"
|
||||
android:tag="tv_no_focus_tag"
|
||||
android:tag="@string/tv_no_focus_tag"
|
||||
android:focusable="false" />
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue