diff --git a/android/app/src/main/java/updated/mysterium/vpn/ui/base/BaseActivity.kt b/android/app/src/main/java/updated/mysterium/vpn/ui/base/BaseActivity.kt index f18a8b6b9..1840270a9 100644 --- a/android/app/src/main/java/updated/mysterium/vpn/ui/base/BaseActivity.kt +++ b/android/app/src/main/java/updated/mysterium/vpn/ui/base/BaseActivity.kt @@ -178,6 +178,22 @@ abstract class BaseActivity : AppCompatActivity() { connectionStateToolbar?.protectedState(true) } + protected fun getTransitionAnimation(isBackTransition: Boolean?): Bundle? { + return if (isBackTransition == true) { + ActivityOptions.makeCustomAnimation( + applicationContext, + R.anim.slide_in_left, + R.anim.slide_out_right + ).toBundle() + } else { + ActivityOptions.makeCustomAnimation( + applicationContext, + R.anim.slide_in_right, + R.anim.slide_out_left + ).toBundle() + } + } + private fun unprotectedConnection() { connectionStateToolbar?.unprotectedState() } @@ -360,22 +376,6 @@ abstract class BaseActivity : AppCompatActivity() { } } - private fun getTransitionAnimation(isBackTransition: Boolean?): Bundle? { - return if (isBackTransition == true) { - ActivityOptions.makeCustomAnimation( - applicationContext, - R.anim.slide_in_left, - R.anim.slide_out_right - ).toBundle() - } else { - ActivityOptions.makeCustomAnimation( - applicationContext, - R.anim.slide_in_right, - R.anim.slide_out_left - ).toBundle() - } - } - private fun getCountryCode(): String? { return homeSelectionViewModel.getPreviousCountryCode() } diff --git a/android/app/src/main/java/updated/mysterium/vpn/ui/private/key/PrivateKeyActivity.kt b/android/app/src/main/java/updated/mysterium/vpn/ui/private/key/PrivateKeyActivity.kt index f378c7a43..d66459419 100644 --- a/android/app/src/main/java/updated/mysterium/vpn/ui/private/key/PrivateKeyActivity.kt +++ b/android/app/src/main/java/updated/mysterium/vpn/ui/private/key/PrivateKeyActivity.kt @@ -172,6 +172,7 @@ class PrivateKeyActivity : BaseActivity(), ActivityCompat.OnRequestPermissionsRe setNextToAccountFrameAvailability(result.isSuccess) result.onSuccess { viewModel.accountCreated() + navigateToPrepareTopUp() } result.onFailure { Log.i(TAG, "onFailure ${it.localizedMessage}") diff --git a/android/app/src/main/java/updated/mysterium/vpn/ui/terms/TermsOfUseActivity.kt b/android/app/src/main/java/updated/mysterium/vpn/ui/terms/TermsOfUseActivity.kt index 2e50175c0..d0922579a 100644 --- a/android/app/src/main/java/updated/mysterium/vpn/ui/terms/TermsOfUseActivity.kt +++ b/android/app/src/main/java/updated/mysterium/vpn/ui/terms/TermsOfUseActivity.kt @@ -94,7 +94,7 @@ class TermsOfUseActivity : BaseActivity() { } else { Intent(this, CreateAccountActivity::class.java) } - startActivity(intent) + startActivity(intent, getTransitionAnimation(false)) finish() } }