ui: root: rewrite in kotlin

Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
This commit is contained in:
Jason A. Donenfeld committed 2020-03-26 01:55:44 -06:00
1 parent 2958144fd0
commit 85dd303c88
7 files changed
+352 -398

No files matched your search

@@ -43,7 +43,7 @@ class VersionPreference(context: Context, attrs: AttributeSet?) : Preference(con
}
init {
Application.getBackendAsync().thenAccept { backend: Backend ->
Application.getBackendAsync().thenAccept { backend ->
versionSummary = getContext().getString(R.string.version_summary_checking, getBackendPrettyName(context, backend).toLowerCase(Locale.ENGLISH))
Application.getAsyncWorker().supplyAsync(backend::getVersion).whenComplete { version, exception ->
versionSummary = if (exception == null)