Commit 7aace0b7 authored by mengcuiguang's avatar mengcuiguang

优化umeng埋点

parent 39d284f5
......@@ -82,9 +82,6 @@ class InitAppService : IntentService("InitializeService") {
// 变现猫
initBxm(this.application)
// 猎豹游戏初始化
LiebaoManager.getInstance().initCmGameSdk()
}
/**
......
......@@ -13,6 +13,7 @@ import androidx.multidex.MultiDexApplication;
import com.bun.miitmdid.core.JLibrary;
import com.component.dly.xzzq_ywsdk.YwSDK;
import com.mints.goodmoney.common.Constant;
import com.mints.goodmoney.manager.LiebaoManager;
import com.mints.goodmoney.manager.MiitHelper;
import com.mints.goodmoney.manager.TtCsjAdManager;
import com.mints.goodmoney.manager.UserManager;
......@@ -112,6 +113,9 @@ public class MintsApplication extends MultiDexApplication {
// 一览视频
YlVideoManager.INSTANCE.init(this);
// 猎豹游戏初始化
LiebaoManager.getInstance().initCmGameSdk();
}
private MiitHelper.AppIdsUpdater appIdsUpdater = ids -> OAID = ids;
......
......@@ -68,14 +68,7 @@ class AwardActivity : BaseActivity(), AwardView, View.OnClickListener {
Utils.hideBottomUIMenu(this)
// 开启3秒倒计时
startTime()
if (!TextUtils.isEmpty(carrierType) && curCoin > 0) {
// 埋点上送事件
val map = mutableMapOf<String, String>()
map["userId"] = UserManager.getInstance().userID
map["coin"] = "" + curCoin
MobclickAgent.onEvent(this, carrierType, map)
}
pushUmengEvent()
when (carrierType) {
Constant.CARRIER_GAME_ONLINE, Constant.CARRIER_EATMEAL -> {
......@@ -173,6 +166,19 @@ class AwardActivity : BaseActivity(), AwardView, View.OnClickListener {
}
}
/**
* 提示umeng事件埋点
*/
private fun pushUmengEvent() {
if (!TextUtils.isEmpty(carrierType) && curCoin > 0) {
// 埋点上送事件
val map = mutableMapOf<String, String>()
map["userId"] = UserManager.getInstance().userID
map["coin"] = "" + curCoin
MobclickAgent.onEvent(this, carrierType, map)
}
}
override fun finish() {
super.finish()
//关闭窗体动画显示
......@@ -236,14 +242,17 @@ class AwardActivity : BaseActivity(), AwardView, View.OnClickListener {
R.id.tvAwardNext -> {
when (carrierType) {
// 只有看视频才能领金币
Constant.CARRIER_CHALLENGE_SHAREFRIEND_DOUBLE,
Constant.CARRIER_OFFLINE_DOUBLE, Constant.CARRIER_SIGNIN_HOMEPAGE_CARD,
Constant.CARRIER_CHALLENGE_TURN, Constant.CARRIER_CHALLENGE_CARD,
Constant.CARRIER_WALK_BUBBLE, Constant.CARRIER_HOMEVEDIO_DOUBLE,
Constant.CARRIER_SMALLHOMEVEDIO_DOUBLE, Constant.CARRIER_EATMEAL_SUBSIDY,
Constant.CARRIER_WALK_BUBBLE, Constant.CARRIER_EATMEAL_SUBSIDY,
Constant.CARRIER_WALK, Constant.CARRIER_HOMEWATER -> {
awardVedio()
}
Constant.CARRIER_CHALLENGE_SHAREFRIEND_DOUBLE, Constant.CARRIER_HOMEVEDIO_DOUBLE,
Constant.CARRIER_SMALLHOMEVEDIO_DOUBLE -> {
pushUmengEvent()
awardVedio()
}
Constant.CARRIER_NEW_VISITOR -> {
readyGoThenKill(LoginActivity::class.java)
}
......
......@@ -227,6 +227,9 @@ class MainFragment : BaseFragment(), HomeView, View.OnClickListener {
private fun showPowerDialog() {
if (ps.getBoolean(Constant.LOAN_PERMISSION_FLAG, true)) {
powerDialog()
} else {
// 数美初始化
ShumeiManager.getInstance().initShumei()
}
}
......
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