From cf373f3a93d355e386195fda596a8c93f00ba859 Mon Sep 17 00:00:00 2001 From: jubb Date: Fri, 5 Mar 2021 13:39:15 +1100 Subject: [PATCH] fix: set current pager item to 0 on scan --- .../securesms/loki/activities/LinkDeviceActivity.kt | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/app/src/main/java/org/thoughtcrime/securesms/loki/activities/LinkDeviceActivity.kt b/app/src/main/java/org/thoughtcrime/securesms/loki/activities/LinkDeviceActivity.kt index 7a781589cb..ff27a1da45 100644 --- a/app/src/main/java/org/thoughtcrime/securesms/loki/activities/LinkDeviceActivity.kt +++ b/app/src/main/java/org/thoughtcrime/securesms/loki/activities/LinkDeviceActivity.kt @@ -17,8 +17,6 @@ import kotlinx.android.synthetic.main.activity_create_private_chat.* import kotlinx.android.synthetic.main.activity_create_private_chat.tabLayout import kotlinx.android.synthetic.main.activity_create_private_chat.viewPager import kotlinx.android.synthetic.main.activity_link_device.* -import kotlinx.android.synthetic.main.activity_settings.* -import kotlinx.android.synthetic.main.activity_settings.loader import kotlinx.android.synthetic.main.fragment_recovery_phrase.* import kotlinx.coroutines.Job import kotlinx.coroutines.delay @@ -86,6 +84,7 @@ class LinkDeviceActivity : BaseActionBarActivity(), ScanQRCodeWrapperFragmentDel } private fun continueWithSeed(seed: ByteArray) { + viewPager.currentItem = 0 // reset view to the main one restoreJob?.cancel() restoreJob = lifecycleScope.launch { // RestoreActivity handles seed this way