Commit 815a9b4d authored by mengcuiguang's avatar mengcuiguang

代码优化

parent 59c7fe10
...@@ -2,6 +2,8 @@ package com.duben.happyplaylet.video.csj ...@@ -2,6 +2,8 @@ package com.duben.happyplaylet.video.csj
import android.app.Dialog import android.app.Dialog
import android.os.Bundle import android.os.Bundle
import android.os.Handler
import android.os.Looper
import android.text.TextUtils import android.text.TextUtils
import android.util.Log import android.util.Log
import android.view.View import android.view.View
...@@ -204,10 +206,14 @@ class DramaApiDetailActivity : BaseActivity(), VideoEpisodeAdapter.OnEpisodeClic ...@@ -204,10 +206,14 @@ class DramaApiDetailActivity : BaseActivity(), VideoEpisodeAdapter.OnEpisodeClic
TextUtils.isEmpty(UserManager.getInstance().mobile) && TextUtils.isEmpty(UserManager.getInstance().mobile) &&
!AppConfig.vipNoBindMobile !AppConfig.vipNoBindMobile
) { ) {
AppConfig.vipNoBindMobile = true Handler(Looper.getMainLooper()).postDelayed({
val bundle = Bundle() if(isFinishing) return@postDelayed
bundle.putBoolean(MobileLoginActivity.BACK, true)
readyGo(MobileLoginActivity::class.java, bundle) AppConfig.vipNoBindMobile = true
val bundle = Bundle()
bundle.putBoolean(MobileLoginActivity.BACK, true)
readyGo(MobileLoginActivity::class.java, bundle)
}, 1000)
} }
} }
......
...@@ -2,6 +2,8 @@ package com.duben.happyplaylet.video.tx ...@@ -2,6 +2,8 @@ package com.duben.happyplaylet.video.tx
import android.app.Dialog import android.app.Dialog
import android.os.Bundle import android.os.Bundle
import android.os.Handler
import android.os.Looper
import android.text.TextUtils import android.text.TextUtils
import android.view.View import android.view.View
import com.google.gson.Gson import com.google.gson.Gson
...@@ -69,10 +71,15 @@ class TxVideoActivity : BaseActivity(), View.OnClickListener, VideoView, ...@@ -69,10 +71,15 @@ class TxVideoActivity : BaseActivity(), View.OnClickListener, VideoView,
TextUtils.isEmpty(UserManager.getInstance().mobile) && TextUtils.isEmpty(UserManager.getInstance().mobile) &&
!AppConfig.vipNoBindMobile !AppConfig.vipNoBindMobile
) { ) {
AppConfig.vipNoBindMobile = true Handler(Looper.getMainLooper()).postDelayed({
val bundle = Bundle() if(isFinishing) return@postDelayed
bundle.putBoolean(MobileLoginActivity.BACK, true)
readyGo(MobileLoginActivity::class.java, bundle) AppConfig.vipNoBindMobile = true
val bundle = Bundle()
bundle.putBoolean(MobileLoginActivity.BACK, true)
readyGo(MobileLoginActivity::class.java, bundle)
}, 1000)
} }
} }
......
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