|
|
|
@ -45,7 +45,7 @@ class LinkDeviceActivity : BaseActionBarActivity(), ScanQRCodeWrapperFragmentDel
|
|
|
|
|
private var restoreJob: Job? = null
|
|
|
|
|
|
|
|
|
|
override fun onBackPressed() {
|
|
|
|
|
if (restoreJob?.isActive == true) return // don't allow going back with pending job
|
|
|
|
|
if (restoreJob?.isActive == true) return // Don't allow going back with a pending job
|
|
|
|
|
super.onBackPressed()
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
@ -53,14 +53,12 @@ class LinkDeviceActivity : BaseActionBarActivity(), ScanQRCodeWrapperFragmentDel
|
|
|
|
|
override fun onCreate(savedInstanceState: Bundle?) {
|
|
|
|
|
super.onCreate(savedInstanceState)
|
|
|
|
|
setUpActionBarSessionLogo()
|
|
|
|
|
// Set the registration sync variables
|
|
|
|
|
TextSecurePreferences.apply {
|
|
|
|
|
setHasViewedSeed(this@LinkDeviceActivity, true)
|
|
|
|
|
setConfigurationMessageSynced(this@LinkDeviceActivity, false)
|
|
|
|
|
setRestorationTime(this@LinkDeviceActivity, System.currentTimeMillis())
|
|
|
|
|
setLastProfileUpdateTime(this@LinkDeviceActivity, 0)
|
|
|
|
|
}
|
|
|
|
|
// registration variables are synced
|
|
|
|
|
setContentView(R.layout.activity_link_device)
|
|
|
|
|
viewPager.adapter = adapter
|
|
|
|
|
tabLayout.setupWithViewPager(viewPager)
|
|
|
|
|