Commit 4d3d6adc authored by wanglei's avatar wanglei

插页预加载

parent 6949230e
......@@ -19,6 +19,7 @@ import com.base.filerecoveryrecyclebin.activity.screenshot.ScreenShotActivity
import com.base.filerecoveryrecyclebin.ads.admob.AdmobInterstitialUtils
import com.base.filerecoveryrecyclebin.ads.admob.AdmobNativeUtils
import com.base.filerecoveryrecyclebin.ads.admob.AdmobOpenUtils
import com.base.filerecoveryrecyclebin.ads.max.AdMaxInterstitialUtils
import com.base.filerecoveryrecyclebin.ads.max.AdMaxOpenUtils
import com.base.filerecoveryrecyclebin.bean.ConstObject
import com.base.filerecoveryrecyclebin.bean.ConstObject.ID_JUNK_CLEAN_PUSH
......@@ -83,6 +84,7 @@ class SplashActivity : BaseActivity<ActivitySplashBinding>() {
AdmobInterstitialUtils.loadInterstitialAd(this)
} else {
AdMaxOpenUtils.loadAppOpenAd(this)
AdMaxInterstitialUtils.loadInterstitialAd(this)
}
} else {
binding.llStart.visibility = View.VISIBLE
......
......@@ -83,6 +83,7 @@ object AdMaxInterstitialUtils {
override fun onAdHidden(p0: MaxAd) {
LogEx.logDebug(TAG, "onAdHidden")
onHidden?.invoke()
interstitialAd?.loadAd()
}
override fun onAdClicked(p0: MaxAd) {
......@@ -199,5 +200,12 @@ object AdMaxInterstitialUtils {
}
fun loadInterstitialAd(activity: Activity) {
setListener(activity)
if (AdMaxInit.isAdMaxInit) {
interstitialAd?.loadAd()
}
}
}
\ No newline at end of file
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