Skip to content

Commit 354e1c0

Browse files
committed
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 <[email protected]>
1 parent 02b9677 commit 354e1c0

File tree

3 files changed

+1
-8
lines changed

3 files changed

+1
-8
lines changed

ui/src/main/java/com/wireguard/android/Application.kt

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -125,27 +125,20 @@ class Application : android.app.Application() {
125125
private const val TAG = "WireGuard/Application"
126126
private lateinit var weakSelf: WeakReference<Application>
127127

128-
@JvmStatic
129128
fun get(): Application {
130129
return weakSelf.get()!!
131130
}
132131

133-
@JvmStatic
134132
suspend fun getBackend() = get().futureBackend.await()
135133

136-
@JvmStatic
137134
fun getRootShell() = get().rootShell
138135

139-
@JvmStatic
140136
fun getPreferencesDataStore() = get().preferencesDataStore
141137

142-
@JvmStatic
143138
fun getToolsInstaller() = get().toolsInstaller
144139

145-
@JvmStatic
146140
fun getTunnelManager() = get().tunnelManager
147141

148-
@JvmStatic
149142
fun getCoroutineScope() = get().coroutineScope
150143
}
151144

ui/src/main/java/com/wireguard/android/fragment/AppListDialogFragment.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,7 @@ class AppListDialogFragment : DialogFragment() {
154154
const val KEY_SELECTED_APPS = "selected_apps"
155155
const val KEY_IS_EXCLUDED = "is_excluded"
156156
const val REQUEST_SELECTION = "request_selection"
157+
157158
fun newInstance(selectedApps: ArrayList<String?>?, isExcluded: Boolean): AppListDialogFragment {
158159
val extras = Bundle()
159160
extras.putStringArrayList(KEY_SELECTED_APPS, selectedApps)

ui/src/main/java/com/wireguard/android/fragment/ConfigNamingDialogFragment.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,6 @@ class ConfigNamingDialogFragment : DialogFragment() {
7070
companion object {
7171
private const val KEY_CONFIG_TEXT = "config_text"
7272

73-
@JvmStatic
7473
fun newInstance(configText: String?): ConfigNamingDialogFragment {
7574
val extras = Bundle()
7675
extras.putString(KEY_CONFIG_TEXT, configText)

0 commit comments

Comments
 (0)