ui: remove unneeded @JvmStatic annotations
These are only needed on methods called from databindings, since those compile to java. Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
This commit is contained in:
		
							parent
							
								
									02b9677a9c
								
							
						
					
					
						commit
						354e1c0ed9
					
				@ -125,27 +125,20 @@ class Application : android.app.Application() {
 | 
				
			|||||||
        private const val TAG = "WireGuard/Application"
 | 
					        private const val TAG = "WireGuard/Application"
 | 
				
			||||||
        private lateinit var weakSelf: WeakReference<Application>
 | 
					        private lateinit var weakSelf: WeakReference<Application>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        @JvmStatic
 | 
					 | 
				
			||||||
        fun get(): Application {
 | 
					        fun get(): Application {
 | 
				
			||||||
            return weakSelf.get()!!
 | 
					            return weakSelf.get()!!
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        @JvmStatic
 | 
					 | 
				
			||||||
        suspend fun getBackend() = get().futureBackend.await()
 | 
					        suspend fun getBackend() = get().futureBackend.await()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        @JvmStatic
 | 
					 | 
				
			||||||
        fun getRootShell() = get().rootShell
 | 
					        fun getRootShell() = get().rootShell
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        @JvmStatic
 | 
					 | 
				
			||||||
        fun getPreferencesDataStore() = get().preferencesDataStore
 | 
					        fun getPreferencesDataStore() = get().preferencesDataStore
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        @JvmStatic
 | 
					 | 
				
			||||||
        fun getToolsInstaller() = get().toolsInstaller
 | 
					        fun getToolsInstaller() = get().toolsInstaller
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        @JvmStatic
 | 
					 | 
				
			||||||
        fun getTunnelManager() = get().tunnelManager
 | 
					        fun getTunnelManager() = get().tunnelManager
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        @JvmStatic
 | 
					 | 
				
			||||||
        fun getCoroutineScope() = get().coroutineScope
 | 
					        fun getCoroutineScope() = get().coroutineScope
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
				
			|||||||
@ -154,6 +154,7 @@ class AppListDialogFragment : DialogFragment() {
 | 
				
			|||||||
        const val KEY_SELECTED_APPS = "selected_apps"
 | 
					        const val KEY_SELECTED_APPS = "selected_apps"
 | 
				
			||||||
        const val KEY_IS_EXCLUDED = "is_excluded"
 | 
					        const val KEY_IS_EXCLUDED = "is_excluded"
 | 
				
			||||||
        const val REQUEST_SELECTION = "request_selection"
 | 
					        const val REQUEST_SELECTION = "request_selection"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        fun newInstance(selectedApps: ArrayList<String?>?, isExcluded: Boolean): AppListDialogFragment {
 | 
					        fun newInstance(selectedApps: ArrayList<String?>?, isExcluded: Boolean): AppListDialogFragment {
 | 
				
			||||||
            val extras = Bundle()
 | 
					            val extras = Bundle()
 | 
				
			||||||
            extras.putStringArrayList(KEY_SELECTED_APPS, selectedApps)
 | 
					            extras.putStringArrayList(KEY_SELECTED_APPS, selectedApps)
 | 
				
			||||||
 | 
				
			|||||||
@ -70,7 +70,6 @@ class ConfigNamingDialogFragment : DialogFragment() {
 | 
				
			|||||||
    companion object {
 | 
					    companion object {
 | 
				
			||||||
        private const val KEY_CONFIG_TEXT = "config_text"
 | 
					        private const val KEY_CONFIG_TEXT = "config_text"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        @JvmStatic
 | 
					 | 
				
			||||||
        fun newInstance(configText: String?): ConfigNamingDialogFragment {
 | 
					        fun newInstance(configText: String?): ConfigNamingDialogFragment {
 | 
				
			||||||
            val extras = Bundle()
 | 
					            val extras = Bundle()
 | 
				
			||||||
            extras.putString(KEY_CONFIG_TEXT, configText)
 | 
					            extras.putString(KEY_CONFIG_TEXT, configText)
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user