Commit cfde0bff by YKai

fix:一键登录逻辑优化

parent 428a643d
...@@ -8,7 +8,7 @@ ext { ...@@ -8,7 +8,7 @@ ext {
"m-confide" : "0.0.48.91", "m-confide" : "0.0.48.91",
"m-consultant" : "0.0.59.40", "m-consultant" : "0.0.59.40",
"m-fm" : "0.0.30.00", "m-fm" : "0.0.30.00",
"m-user" : "0.0.60.64", "m-user" : "0.0.60.65",
"m-home" : "0.0.22.51", "m-home" : "0.0.22.51",
"m-im" : "0.0.18.30", "m-im" : "0.0.18.30",
"m-dynamic" : "0.0.7.13", "m-dynamic" : "0.0.7.13",
...@@ -91,7 +91,7 @@ ext { ...@@ -91,7 +91,7 @@ ext {
"m-confide" : "0.0.48.91", "m-confide" : "0.0.48.91",
"m-consultant" : "0.0.51.16", "m-consultant" : "0.0.51.16",
"m-fm" : "0.0.23.5", "m-fm" : "0.0.23.5",
"m-user" : "0.0.60.63", "m-user" : "0.0.60.65",
"m-home" : "0.0.22.51", "m-home" : "0.0.22.51",
"m-im" : "0.0.3.15", "m-im" : "0.0.3.15",
"m-dynamic" : "0.0.1.7", "m-dynamic" : "0.0.1.7",
......
...@@ -101,8 +101,6 @@ object LoginUtils { ...@@ -101,8 +101,6 @@ object LoginUtils {
@JvmStatic @JvmStatic
fun loginSuccessOperate(activity: Activity) { fun loginSuccessOperate(activity: Activity) {
// 在一键登录页面切换到其它登录方式登录后,并退出一键登录界面
OneKeyLoginHelp.quitLoginPage()
val size = ActivityManager.getActivitySize() val size = ActivityManager.getActivitySize()
if (size <= 2) {//当前stack只有两个页面,必然没有MainActivity if (size <= 2) {//当前stack只有两个页面,必然没有MainActivity
ActivityManager.finishAll() ActivityManager.finishAll()
......
...@@ -364,7 +364,6 @@ object OneKeyLoginHelp { ...@@ -364,7 +364,6 @@ object OneKeyLoginHelp {
LogUtil.e("唤起授权页成功:$s") LogUtil.e("唤起授权页成功:$s")
if (mIsFromGuide){ if (mIsFromGuide){
mActivity.finish() mActivity.finish()
mIsFromGuide = false
} }
} }
ResultCode.CODE_SUCCESS -> { // 获取token成功 ResultCode.CODE_SUCCESS -> { // 获取token成功
......
...@@ -633,18 +633,11 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont ...@@ -633,18 +633,11 @@ class RegisterAndLoginActivity : BaseMvpActivity<ILoginContract.View, ILoginCont
override fun onBackPressed() { override fun onBackPressed() {
//当前stack只有一个activity,说明被挤掉线的 //当前stack只有一个activity,说明被挤掉线的
// if (ActivityManager.getActivitySize() == 1) { if (ActivityManager.getActivitySize() == 1) {
// ActivityManager.finishOtherActivity(this)
// UserIn.mainIntent(this, 4)
// finish()
// } else {
// super.onBackPressed()
// }
if (isFromGuide){
ActivityManager.finishOtherActivity(this) ActivityManager.finishOtherActivity(this)
UserIn.mainIntent(this, 4) UserIn.mainIntent(this, 4)
finish() finish()
}else{ } else {
super.onBackPressed() super.onBackPressed()
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment