Clean up string resources by deleting hint_strings.xml and refactoring hint-related strings into the main strings.xml
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
package eu.gaudian.translator.view.hints
|
||||
|
||||
import android.content.Context
|
||||
import android.os.Build
|
||||
import java.util.Locale
|
||||
|
||||
/**
|
||||
@@ -91,16 +90,9 @@ object MarkdownHintLoader {
|
||||
return "$hintFileName-$languageCode.md"
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the current device locale.
|
||||
*/
|
||||
@Suppress("DEPRECATION")
|
||||
|
||||
fun getCurrentLocale(context: Context): Locale {
|
||||
return if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.N) {
|
||||
context.resources.configuration.locales[0]
|
||||
} else {
|
||||
context.resources.configuration.locale
|
||||
}
|
||||
return context.resources.configuration.locale
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user