Commit 08ad975a authored by mengcuiguang's avatar mengcuiguang

代码合并

parent c94121e5
...@@ -292,11 +292,6 @@ public class VideoAdingManager { ...@@ -292,11 +292,6 @@ public class VideoAdingManager {
weight = weight + ksVideoWeight; weight = weight + ksVideoWeight;
LogUtil.d(TAG, "权重值:ksWeight:" + ksVideoWeight); LogUtil.d(TAG, "权重值:ksWeight:" + ksVideoWeight);
} }
if (AppConfig.rtaVideoAdCount > 0) {
weightList.add(new WeightBean(rtaVideoWeight, Constant.RTA_VEDIO_AD));
weight = weight + rtaVideoWeight;
LogUtil.d(TAG, "权重值:rtaWeight:" + rtaVideoWeight);
}
if (AppConfig.shVideoAdCount > 0) { if (AppConfig.shVideoAdCount > 0) {
weightList.add(new WeightBean(shVideoWeight, Constant.SH_VEDIO_AD)); weightList.add(new WeightBean(shVideoWeight, Constant.SH_VEDIO_AD));
weight = weight + shVideoWeight; weight = weight + shVideoWeight;
...@@ -307,6 +302,11 @@ public class VideoAdingManager { ...@@ -307,6 +302,11 @@ public class VideoAdingManager {
weight = weight + wnWeight; weight = weight + wnWeight;
LogUtil.d(TAG, "权重值:sdhzWeight:" + wnWeight); LogUtil.d(TAG, "权重值:sdhzWeight:" + wnWeight);
} }
if (AppConfig.rtaVideoAdCount > 0) {
weightList.add(new WeightBean(rtaVideoWeight, Constant.RTA_VEDIO_AD));
weight = weight + rtaVideoWeight;
LogUtil.d(TAG, "权重值:rtaWeight:" + rtaVideoWeight);
}
if (AppConfig.flVideoAdCount > 0) { if (AppConfig.flVideoAdCount > 0) {
weightList.add(new WeightBean(flVideoWeight, Constant.FL_VEDIO_AD)); weightList.add(new WeightBean(flVideoWeight, Constant.FL_VEDIO_AD));
weight = weight + flVideoWeight; weight = weight + flVideoWeight;
...@@ -738,17 +738,14 @@ public class VideoAdingManager { ...@@ -738,17 +738,14 @@ public class VideoAdingManager {
@Override @Override
public void adDownload() { public void adDownload() {
isVideoAdDownload = true; isVideoAdDownload = true;
// 注册下载任务监听
registerBroad();
} }
}); });
rtaVideoAdManager.loadAd(activity, bean.getCurCoin(), bean.getCarrierType(), bean.getExtraId()); rtaVideoAdManager.loadAd(activity, bean.getCurCoin(), bean.getCarrierType(), bean.getExtraId());
} }
// ChannelRuleEnum channelRule = ChannelRuleEnum.match(videoAdType);
// BaseVideoAd rule = channelRule.channel;
// if (rule != null) {
// rule.loadAd(activity, bean.getCurCoin(), bean.getCarrierType(), bean.getExtraId());
// }
} catch (Exception e) { } catch (Exception e) {
e.printStackTrace(); e.printStackTrace();
if (videoAdingListener != null) { if (videoAdingListener != null) {
......
...@@ -15,17 +15,25 @@ import com.mints.goodmoney.R ...@@ -15,17 +15,25 @@ import com.mints.goodmoney.R
object MokuManager { object MokuManager {
private const val APP_ID = "Y0jqdW3W" private const val APP_ID = "Y0jqdW3W"
private const val APP_KEY = "421ec06a6f1dbd75010f6f9e4d821cfe03e3a7a3" private const val APP_SECRET = "421ec06a6f1dbd75010f6f9e4d821cfe03e3a7a3"
fun init(activity: Activity) { fun init(activity: Activity) {
//初始化sdk try {
MokuHelper.initSdk(activity) //初始化sdk
MokuHelper.initSdk(activity)
} catch (e: MokuException) {
e.printStackTrace()
}
} }
fun initOaid(oaid: String) { fun initOaid(oaid: String) {
//设置oaid try {
MokuHelper.initOaid(oaid) //设置oaid
MokuHelper.initOaid(oaid)
} catch (e: MokuException) {
e.printStackTrace()
}
} }
fun gotoMoku(context: Context) { fun gotoMoku(context: Context) {
...@@ -36,33 +44,31 @@ object MokuManager { ...@@ -36,33 +44,31 @@ object MokuManager {
try { try {
//启动sdk //启动sdk
MokuHelper.startSdk(context, userId, APP_ID, APP_KEY) MokuHelper.startSdk(context, userId, APP_ID, APP_SECRET)
} catch (e: MokuException) {
e.printStackTrace() val styleConfig = StyleConfig()
} //设置页面标题文字
val styleConfig = StyleConfig() styleConfig.titleText = "蘑菇星球"
//设置页面标题文字 //设置标题栏颜色
styleConfig.titleText = "蘑菇星球" styleConfig.titleColor = context.getResources().getColor(R.color.green_morandi)
//设置标题栏颜色 //设置状态栏颜色
styleConfig.titleColor = context.getResources().getColor(R.color.green_morandi) styleConfig.statusBarColor = context.getResources().getColor(R.color.green_morandi)
//设置状态栏颜色 //设置标题栏返回键颜色
styleConfig.statusBarColor = context.getResources().getColor(R.color.green_morandi) styleConfig.titleBackColor = context.getResources().getColor(R.color.white)
//设置标题栏返回键颜色 //设置标题文字颜色
styleConfig.titleBackColor = context.getResources().getColor(R.color.white) styleConfig.titleTextColor = context.getResources().getColor(R.color.white)
//设置标题文字颜色 //设置选项框背景颜色
styleConfig.titleTextColor = context.getResources().getColor(R.color.white) styleConfig.tabBackgroundColor = context.getResources().getColor(R.color.moku_gray_very_light)
//设置选项框背景颜色 //设置选项框指示器颜色
styleConfig.tabBackgroundColor = context.getResources().getColor(R.color.moku_gray_very_light) styleConfig.tabIndicatorColor = context.getResources().getColor(R.color.green_morandi)
//设置选项框指示器颜色 //设置选项文字默认颜色
styleConfig.tabIndicatorColor = context.getResources().getColor(R.color.green_morandi) styleConfig.tabTextColor = context.getResources().getColor(R.color.green_morandi_light)
//设置选项文字默认颜色 //设置选项文字选中颜色
styleConfig.tabTextColor = context.getResources().getColor(R.color.green_morandi_light) styleConfig.tabSelectedTextColor = context.getResources().getColor(R.color.green_morandi)
//设置选项文字选中颜色
styleConfig.tabSelectedTextColor = context.getResources().getColor(R.color.green_morandi) //设置主题样式
MokuHelper.initStyleConfig(styleConfig)
//设置主题样式
MokuHelper.initStyleConfig(styleConfig)
try {
//跳转到蘑菇星球页面 //跳转到蘑菇星球页面
MokuHelper.startMokuMainActivity(context) MokuHelper.startMokuMainActivity(context)
} catch (e: MokuException) { } catch (e: MokuException) {
......
...@@ -37,7 +37,8 @@ public class TtCsjAdManager { ...@@ -37,7 +37,8 @@ public class TtCsjAdManager {
public static String TT_AD_VEDIO_OFFINELINE = "945562040";// 离线弹框 public static String TT_AD_VEDIO_OFFINELINE = "945562040";// 离线弹框
public static String TT_AD_VEDIO_GAME = "945562067";// 猎豹 public static String TT_AD_VEDIO_GAME = "945562067";// 猎豹
public static String TT_AD_VEDIO_JULEYUN = "945675529";// 聚乐云 // public static String TT_AD_VEDIO_JULEYUN = "945675529";// 聚乐云
public static String TT_AD_VEDIO_JULEYUN = "945562040";// 聚乐云
public static String TT_AD_VEDIO_BIANXIANMAO = "945743459";// 变现猫 public static String TT_AD_VEDIO_BIANXIANMAO = "945743459";// 变现猫
public static String TT_AD_VEDIO_BLESSINGBAG = "945730117";// 福袋 public static String TT_AD_VEDIO_BLESSINGBAG = "945730117";// 福袋
public static String TT_AD_VEDIO_HOMEVEDIO = "945744137";// 首页视频翻倍 public static String TT_AD_VEDIO_HOMEVEDIO = "945744137";// 首页视频翻倍
......
...@@ -31,7 +31,8 @@ object YlhAdManager { ...@@ -31,7 +31,8 @@ object YlhAdManager {
var YLH_AD_VEDIO_OFFINELINE_POSTID = "9001346780383626" //离线弹框 var YLH_AD_VEDIO_OFFINELINE_POSTID = "9001346780383626" //离线弹框
var YLH_AD_VEDIO_GAME_POSTID = "9051646750686770" //猎豹游戏 var YLH_AD_VEDIO_GAME_POSTID = "9051646750686770" //猎豹游戏
var YLH_AD_VEDIO_JULEYUN_POSTID = "1011746770898338" //聚乐云 // var YLH_AD_VEDIO_JULEYUN_POSTID = "1011746770898338" //聚乐云
var YLH_AD_VEDIO_JULEYUN_POSTID = "9001346780383626" //聚乐云
var YLH_AD_VEDIO_BLESSINGBAG_POSTID = "1081758148138388" //福袋 var YLH_AD_VEDIO_BLESSINGBAG_POSTID = "1081758148138388" //福袋
var YLH_AD_VEDIO_HOMEVEDIO_POSTID= "4051451341464487" // 首页视频翻倍 var YLH_AD_VEDIO_HOMEVEDIO_POSTID= "4051451341464487" // 首页视频翻倍
var YLH_AD_VEDIO_SMALLHOMEVEDIO_POSTID= "9051152341362610" // 短视频翻倍 var YLH_AD_VEDIO_SMALLHOMEVEDIO_POSTID= "9051152341362610" // 短视频翻倍
......
...@@ -259,6 +259,7 @@ class MyFragment : BaseFragment(), ...@@ -259,6 +259,7 @@ class MyFragment : BaseFragment(),
mCurrentIndex = 0 mCurrentIndex = 0
piv_grid.count = pageCount
vp_grid.adapter = ViewPagerAdapter(pagerList) vp_grid.adapter = ViewPagerAdapter(pagerList)
vp_grid.addOnPageChangeListener(object : ViewPager.OnPageChangeListener { vp_grid.addOnPageChangeListener(object : ViewPager.OnPageChangeListener {
override fun onPageScrollStateChanged(state: Int) { override fun onPageScrollStateChanged(state: Int) {
......
...@@ -13,9 +13,9 @@ ...@@ -13,9 +13,9 @@
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="center_horizontal" android:layout_gravity="center_horizontal"
android:layout_marginTop="5dp"
android:layout_marginBottom="5dp"
android:visibility="gone" android:visibility="gone"
android:layout_marginTop="8dp"
android:layout_marginBottom="8dp"
app:piv_count="2" app:piv_count="2"
app:piv_selectedColor="@color/color_FF9837" app:piv_selectedColor="@color/color_FF9837"
app:piv_unselectedColor="@color/color_20000000" app:piv_unselectedColor="@color/color_20000000"
......
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