Commit 22f94188 authored by mengcuiguang's avatar mengcuiguang

个人中心高额任务添加快手广告

parent 98fa7afd
......@@ -65,6 +65,7 @@ public class VideoAdingManager {
// 是否是高额视频任务
private boolean isHighWeight = false;
private boolean isTTVideoAd = false;
private int highIndex = 0;//0-穿山甲 1-优量汇 2-快手
private Activity activity;
private boolean isVideoAdDownload = false;// 是否点击广告下载 true-点击
......@@ -237,12 +238,28 @@ public class VideoAdingManager {
* @return _
*/
private String getHighWeight() {
isTTVideoAd = !isTTVideoAd;
if (isTTVideoAd) {
return Constant.CSJ_VEDIO_AD;
} else {
return Constant.YLH_VEDIO_AD;
// isTTVideoAd = !isTTVideoAd;
// if (isTTVideoAd) {
// return Constant.CSJ_VEDIO_AD;
// } else {
// return Constant.YLH_VEDIO_AD;
// }
String adType = "";
switch (highIndex) {
case 0:
highIndex = 1;
adType = Constant.CSJ_VEDIO_AD;
break;
case 1:
highIndex = 2;
adType = Constant.YLH_VEDIO_AD;
break;
case 2:
highIndex = 0;
adType = Constant.KS_VEDIO_AD;
break;
}
return adType;
}
/**
......@@ -363,7 +380,7 @@ public class VideoAdingManager {
flVideoAdCount <= 0 &&
tzVideoAdCount <= 0 &&
csjFullVideoAdCount <= 0 &&
ksVideoAdCount <= 0 ) {
ksVideoAdCount <= 0) {
// showToast("今日视频已看完,请明天再来吧");
return true;
}
......@@ -773,6 +790,7 @@ public class VideoAdingManager {
}
}
}
private String getCode(String adtype) {
String code = "g";
switch (adtype) {
......
......@@ -106,13 +106,13 @@ class SettingsActivity : BaseActivity(), View.OnClickListener, OnLoginListener,
item_wechat.findViewById<TextView>(R.id.tv_right).text = "未授权"
}
item_invitedCode.findViewById<TextView>(R.id.tv_title).text = "邀请码"
item_invitedCode.findViewById<TextView>(R.id.tv_title).text = "用户ID"
val invitedCode = ContextCompat.getDrawable(mContext, R.mipmap.icon_settings_invite)
invitedCode?.setBounds(0, 0, 56, 56)
item_invitedCode.findViewById<TextView>(R.id.tv_title).setCompoundDrawables(invitedCode, null, null, null)
item_invitedCode.findViewById<TextView>(R.id.tv_right).visibility = View.VISIBLE
item_invitedCode.findViewById<ImageView>(R.id.iv_right).visibility = View.GONE
item_invitedCode.findViewById<TextView>(R.id.tv_right).text = UserManager.getInstance().codeID
item_invitedCode.findViewById<TextView>(R.id.tv_right).text = "GM-" + UserManager.getInstance().codeID
item_cleanCache.findViewById<TextView>(R.id.tv_title).text = "清理缓存"
val cleanCache = ContextCompat.getDrawable(this, R.mipmap.icon_settings_clean)
......
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