aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/ui/src/main/java/com/wireguard
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2020-09-22 23:59:40 +0200
committerJason A. Donenfeld <Jason@zx2c4.com>2020-09-22 23:59:40 +0200
commita8dfebb0862a4ebccf2f1b72724fd8219c2d2777 (patch)
tree3a01f5d46e923dcce6f633c08bec58be96d9349a /ui/src/main/java/com/wireguard
parenttv: hook up isFocused as observable property (diff)
downloadwireguard-android-a8dfebb0862a4ebccf2f1b72724fd8219c2d2777.tar.xz
wireguard-android-a8dfebb0862a4ebccf2f1b72724fd8219c2d2777.zip
tv: select first item after toggling deletion mode
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to 'ui/src/main/java/com/wireguard')
-rw-r--r--ui/src/main/java/com/wireguard/android/activity/TvMainActivity.kt3
1 files changed, 3 insertions, 0 deletions
diff --git a/ui/src/main/java/com/wireguard/android/activity/TvMainActivity.kt b/ui/src/main/java/com/wireguard/android/activity/TvMainActivity.kt
index 1528ac9..ad86f12 100644
--- a/ui/src/main/java/com/wireguard/android/activity/TvMainActivity.kt
+++ b/ui/src/main/java/com/wireguard/android/activity/TvMainActivity.kt
@@ -120,6 +120,9 @@ class TvMainActivity : AppCompatActivity() {
}
binding.deleteButton.setOnClickListener {
isDeleting.set(!isDeleting.get())
+ runOnUiThread {
+ binding.tunnelList.requestFocus()
+ }
}
binding.executePendingBindings()
setContentView(binding.root)