Commit fd8ceb10 authored by maxiaoliang's avatar maxiaoliang

修改金币任务item背景,看广告视频按钮只有立即领取时晃动,修改广告

parent 12f0fb8e
......@@ -71,7 +71,7 @@ class SpeedWaterTaskAdapter :
holder?.imglucky.visibility=View.VISIBLE
}
if (data?.buttonSway != null && data?.buttonSway == 1) {
if (data?.buttonSway != null && data?.buttonSway == 1&&data?.status!=1) {
startAnimator(holder?.ivStatus)
} else {
holder?.ivStatus.clearAnimation()
......
......@@ -68,7 +68,7 @@ class WateringTaskAdpater :
holder?.imglucky.visibility=View.VISIBLE
}
if (data?.buttonSway != null && data?.buttonSway == 1) {
if (data?.buttonSway != null && data?.buttonSway == 1&&data?.status!=1) {
startAnimator(holder?.ivStatus)
} else {
startAnimator2(holder?.ivStatus)
......
......@@ -613,6 +613,13 @@ object MainDialog {
onClickListener.onClick(it)
mDialog.dismiss()
}
mDialog.setOnDismissListener(object : DialogInterface.OnDismissListener {
override fun onDismiss(p0: DialogInterface?) {
onDestroy()
AdUtils.loadFeedCacheAdToCache(activity)
}
})
mDialog?.setCanceledOnTouchOutside(false)
mDialog?.setCancelable(false)
mDialog?.show()
......
......@@ -51,13 +51,6 @@ object AdUtils {
fun showFeedAd(activity: Activity, actionName: String, view: FrameLayout) {
try {
view.postDelayed(object :Runnable {
override fun run() {
if(activity?.isFinishing){
return
}
activity?.runOnUiThread() {
AdManager.showFeedAd(
ADConfig.AD_IMG_FADE,
actionName,
......@@ -69,11 +62,20 @@ object AdUtils {
activity,
view
)
}
}
},500)
} catch (e: Exception) {
}
// try {
// view.postDelayed(object :Runnable {
// override fun run() {
// if(activity?.isFinishing){
// return
// }
//
// activity?.runOnUiThread() {
//
// }
// }
// },0)
// } catch (e: Exception) {
// }
}
//预加载激励
......
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