mirror of
https://github.com/oxen-io/session-android.git
synced 2025-04-21 08:51:31 +00:00
fix: send skip event to the display name activity instead of PN mode
This commit is contained in:
parent
69db4081bc
commit
d631897a3a
@ -93,7 +93,7 @@ class LinkDeviceActivity : BaseActionBarActivity(), ScanQRCodeWrapperFragmentDel
|
|||||||
|
|
||||||
loader.isVisible = true
|
loader.isVisible = true
|
||||||
val snackBar = Snackbar.make(containerLayout, R.string.activity_link_device_skip_prompt,Snackbar.LENGTH_INDEFINITE)
|
val snackBar = Snackbar.make(containerLayout, R.string.activity_link_device_skip_prompt,Snackbar.LENGTH_INDEFINITE)
|
||||||
.setAction(R.string.registration_activity__skip) { register() }
|
.setAction(R.string.registration_activity__skip) { register(true) }
|
||||||
|
|
||||||
val skipJob = launch {
|
val skipJob = launch {
|
||||||
delay(30_000L)
|
delay(30_000L)
|
||||||
@ -106,16 +106,16 @@ class LinkDeviceActivity : BaseActionBarActivity(), ScanQRCodeWrapperFragmentDel
|
|||||||
// handle we've synced
|
// handle we've synced
|
||||||
snackBar.dismiss()
|
snackBar.dismiss()
|
||||||
skipJob.cancel()
|
skipJob.cancel()
|
||||||
register()
|
register(false)
|
||||||
}
|
}
|
||||||
|
|
||||||
loader.isVisible = false
|
loader.isVisible = false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun register() {
|
private fun register(skipped: Boolean) {
|
||||||
restoreJob?.cancel()
|
restoreJob?.cancel()
|
||||||
val intent = Intent(this@LinkDeviceActivity, PNModeActivity::class.java)
|
val intent = Intent(this@LinkDeviceActivity, if (skipped) DisplayNameActivity::class.java else PNModeActivity::class.java)
|
||||||
push(intent)
|
push(intent)
|
||||||
}
|
}
|
||||||
// endregion
|
// endregion
|
||||||
|
Loading…
x
Reference in New Issue
Block a user