android: Remove unnecessary JvmStatic/JvmField annotations
This commit is contained in:
parent
8d3288b6ff
commit
b31ab11842
@ -52,11 +52,9 @@ class YuzuApplication : Application() {
|
||||
}
|
||||
|
||||
companion object {
|
||||
@JvmField
|
||||
var documentsTree: DocumentsTree? = null
|
||||
lateinit var application: YuzuApplication
|
||||
|
||||
@JvmStatic
|
||||
val appContext: Context
|
||||
get() = application.applicationContext
|
||||
}
|
||||
|
@ -326,14 +326,12 @@ open class EmulationActivity : AppCompatActivity(), SensorEventListener {
|
||||
const val EXTRA_SELECTED_GAME = "SelectedGame"
|
||||
private const val EMULATION_RUNNING_NOTIFICATION = 0x1000
|
||||
|
||||
@JvmStatic
|
||||
fun launch(activity: AppCompatActivity, game: Game) {
|
||||
val launcher = Intent(activity, EmulationActivity::class.java)
|
||||
launcher.putExtra(EXTRA_SELECTED_GAME, game)
|
||||
activity.startActivity(launcher)
|
||||
}
|
||||
|
||||
@JvmStatic
|
||||
fun tryDismissRunningNotification(activity: Activity?) {
|
||||
// TODO(bunnei): Disable notifications until we support app suspension.
|
||||
//NotificationManagerCompat.from(activity).cancel(EMULATION_RUNNING_NOTIFICATION);
|
||||
|
@ -220,7 +220,6 @@ class SettingsActivity : AppCompatActivity(), SettingsActivityView {
|
||||
private const val ARG_GAME_ID = "game_id"
|
||||
private const val FRAGMENT_TAG = "settings"
|
||||
|
||||
@JvmStatic
|
||||
fun launch(context: Context, menuTag: String?, gameId: String?) {
|
||||
val settings = Intent(context, SettingsActivity::class.java)
|
||||
settings.putExtra(ARG_MENU_TAG, menuTag)
|
||||
|
@ -110,7 +110,6 @@ class SettingsFragment : Fragment(), SettingsFragmentView {
|
||||
private const val ARGUMENT_MENU_TAG = "menu_tag"
|
||||
private const val ARGUMENT_GAME_ID = "game_id"
|
||||
|
||||
@JvmStatic
|
||||
fun newInstance(menuTag: String?, gameId: String?): Fragment {
|
||||
val fragment = SettingsFragment()
|
||||
val arguments = Bundle()
|
||||
|
@ -12,7 +12,6 @@ object DirectoryInitialization {
|
||||
|
||||
var areDirectoriesReady: Boolean = false
|
||||
|
||||
@JvmStatic
|
||||
fun start(context: Context) {
|
||||
if (!areDirectoriesReady) {
|
||||
initializeInternalStorage(context)
|
||||
|
@ -103,7 +103,6 @@ class DocumentsTree {
|
||||
}
|
||||
|
||||
companion object {
|
||||
@JvmStatic
|
||||
fun isNativePath(path: String): Boolean {
|
||||
return if (path.isNotEmpty()) {
|
||||
path[0] == '/'
|
||||
|
@ -34,7 +34,6 @@ object EmulationMenuSettings {
|
||||
.apply()
|
||||
}
|
||||
|
||||
@JvmStatic
|
||||
var landscapeScreenLayout: Int
|
||||
get() = preferences.getInt(
|
||||
Settings.PREF_MENU_SETTINGS_LANDSCAPE,
|
||||
|
@ -237,7 +237,6 @@ object FileUtil {
|
||||
return size
|
||||
}
|
||||
|
||||
@JvmStatic
|
||||
fun copyUriToInternalStorage(
|
||||
context: Context,
|
||||
sourceUri: Uri?,
|
||||
|
@ -53,7 +53,6 @@ object GpuDriverHelper {
|
||||
zis.closeEntry()
|
||||
}
|
||||
|
||||
@JvmStatic
|
||||
fun initializeDriverParameters(context: Context) {
|
||||
try {
|
||||
// Initialize the file redirection directory.
|
||||
|
@ -14,31 +14,26 @@ import org.yuzu.yuzu_emu.BuildConfig
|
||||
object Log {
|
||||
private const val TAG = "Yuzu Frontend"
|
||||
|
||||
@JvmStatic
|
||||
fun verbose(message: String) {
|
||||
if (BuildConfig.DEBUG) {
|
||||
Log.v(TAG, message)
|
||||
}
|
||||
}
|
||||
|
||||
@JvmStatic
|
||||
fun debug(message: String) {
|
||||
if (BuildConfig.DEBUG) {
|
||||
Log.d(TAG, message)
|
||||
}
|
||||
}
|
||||
|
||||
@JvmStatic
|
||||
fun info(message: String) {
|
||||
Log.i(TAG, message)
|
||||
}
|
||||
|
||||
@JvmStatic
|
||||
fun warning(message: String) {
|
||||
Log.w(TAG, message)
|
||||
}
|
||||
|
||||
@JvmStatic
|
||||
fun error(message: String) {
|
||||
Log.e(TAG, message)
|
||||
}
|
||||
|
@ -25,7 +25,6 @@ object ThemeHelper {
|
||||
private const val DEFAULT = 0
|
||||
private const val MATERIAL_YOU = 1
|
||||
|
||||
@JvmStatic
|
||||
fun setTheme(activity: AppCompatActivity) {
|
||||
val preferences = PreferenceManager.getDefaultSharedPreferences(YuzuApplication.appContext)
|
||||
setThemeMode(activity)
|
||||
|
Loading…
Reference in New Issue
Block a user