mirror of
https://github.com/libre-tube/LibreTube.git
synced 2024-12-14 22:30:30 +05:30
commit
d852726ecf
@ -27,12 +27,6 @@ class HomeFragment : BaseFragment() {
|
||||
private lateinit var binding: FragmentHomeBinding
|
||||
private lateinit var region: String
|
||||
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
super.onCreate(savedInstanceState)
|
||||
arguments?.let {
|
||||
}
|
||||
}
|
||||
|
||||
override fun onCreateView(
|
||||
inflater: LayoutInflater,
|
||||
container: ViewGroup?,
|
||||
|
@ -21,7 +21,7 @@ object LocaleHelper {
|
||||
)
|
||||
updateLocaleConf(context, locale)
|
||||
} else {
|
||||
val locale = Locale(languageName.toString())
|
||||
val locale = Locale(languageName)
|
||||
updateLocaleConf(context, locale)
|
||||
}
|
||||
}
|
||||
@ -41,15 +41,15 @@ object LocaleHelper {
|
||||
|
||||
fun getDetectedCountry(context: Context, defaultCountryIsoCode: String): String {
|
||||
detectSIMCountry(context)?.let {
|
||||
return it
|
||||
if (it != "") return it
|
||||
}
|
||||
|
||||
detectNetworkCountry(context)?.let {
|
||||
return it
|
||||
if (it != "") return it
|
||||
}
|
||||
|
||||
detectLocaleCountry(context)?.let {
|
||||
return it
|
||||
if (it != "") return it
|
||||
}
|
||||
|
||||
return defaultCountryIsoCode
|
||||
|
@ -51,8 +51,9 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@+id/video_count"
|
||||
android:layout_centerInParent="true"
|
||||
android:layout_marginStart="5dp"
|
||||
app:srcCompat="@drawable/ic_playlist" />
|
||||
android:paddingStart="5dp"
|
||||
app:srcCompat="@drawable/ic_playlist"
|
||||
tools:ignore="RtlSymmetry" />
|
||||
|
||||
</RelativeLayout>
|
||||
</com.google.android.material.card.MaterialCardView>
|
||||
|
Loading…
Reference in New Issue
Block a user