Commit d9da0255 authored by mengcuiguang's avatar mengcuiguang

添加审核去广告包

parent e6ac82fb
......@@ -64,7 +64,8 @@ android {
// 不显示Log
buildConfigField "boolean", "LOG_DEBUG", "true"
buildConfigField "String", "AppKeyPre", "\"abcd\""
buildConfigField "String", "MainIp", DEBUG_URL
// buildConfigField "String", "MainIp", DEBUG_URL
buildConfigField "String", "MainIp", RELEASE_URL
manifestPlaceholders = [TD_SCHEMA_KEY: DEBUG_TD_SCHEMA_KEY,
TD_KEY : DEBUG_TD_KEY]
......@@ -190,7 +191,7 @@ dependencies {
// 三方接入
// leakcanary
debugImplementation 'com.squareup.leakcanary:leakcanary-android:2.4'
// debugImplementation 'com.squareup.leakcanary:leakcanary-android:2.4'
// 极光推送
implementation 'cn.jiguang.sdk:jpush:3.6.6'
implementation 'cn.jiguang.sdk:jcore:2.3.8'
......
......@@ -127,7 +127,7 @@
<!-- </activity>-->
<activity
android:name=".ui.activitys.SplashYlhActivity"
android:name=".ui.activitys.SplashActivity"
android:screenOrientation="portrait"
android:theme="@style/NormalSplash">
<intent-filter>
......
......@@ -354,33 +354,33 @@ class MyFragment : BaseFragment(),
* 设置Banner
*/
override fun getMyRotationChartSuc(data: RotationChartBean) {
mBannerData = data
if (mBannerData?.list == null || mBannerData?.list!!.size == 0) {
mAdBannerAdapter = null
fl_my_banner.visibility = View.VISIBLE
LogUtil.d("TAG", "getMyRotationChartSuc")
banner_view.visibility = View.GONE
banner_view.stopAutoScroll()
BannerManager.getTtBanner(TtCsjAdManager.TT_AD_BANNER_MY, fl_my_banner)
} else {
fl_my_banner.visibility = View.GONE
banner_view.visibility = View.VISIBLE
mAdBannerAdapter = AdBannerAdapter(activity)
mAdBannerAdapter?.let {
val list: MutableList<RotationChartBean.ListBean?> = mutableListOf()
list.addAll(mBannerData?.list!!)
list.add(data.position, null)
it.setOnPageClickListener(this)
it.setData(list)
it.setAdPosition(data.position)
banner_view.setAdapter(it)
}
banner_view.startAutoScroll()
}
// mBannerData = data
//
// if (mBannerData?.list == null || mBannerData?.list!!.size == 0) {
// mAdBannerAdapter = null
//
// fl_my_banner.visibility = View.VISIBLE
// LogUtil.d("TAG", "getMyRotationChartSuc")
// banner_view.visibility = View.GONE
// banner_view.stopAutoScroll()
// BannerManager.getTtBanner(TtCsjAdManager.TT_AD_BANNER_MY, fl_my_banner)
// } else {
//
// fl_my_banner.visibility = View.GONE
// banner_view.visibility = View.VISIBLE
// mAdBannerAdapter = AdBannerAdapter(activity)
//
// mAdBannerAdapter?.let {
// val list: MutableList<RotationChartBean.ListBean?> = mutableListOf()
// list.addAll(mBannerData?.list!!)
// list.add(data.position, null)
// it.setOnPageClickListener(this)
// it.setData(list)
// it.setAdPosition(data.position)
// banner_view.setAdapter(it)
// }
// banner_view.startAutoScroll()
// }
}
override fun onRefresh(refreshLayout: RefreshLayout) {
......
......@@ -101,37 +101,37 @@ public class ForegroundOrBackground implements Application.ActivityLifecycleCall
return;
}
if (count == 0) {
// LogUtil.d("ForegroundOrBackground", System.currentTimeMillis() - leaveTime + " onActivityStarted");
// 60秒后打开应用 显示开屏广告
if (System.currentTimeMillis() - leaveTime >= 60000) {
if (isYlhSplash) {
isYlhSplash = false;
if (ylhIntent == null) {
// 优量汇广告
ylhIntent = new Intent(activity, SplashADActivity.class);
}
activity.startActivity(ylhIntent);
} else {
isYlhSplash = true;
if (csjIntent == null) {
// 快手广告
csjIntent = new Intent(activity, SplashCsjADActivity.class);
}
activity.startActivity(csjIntent);
// if (ksIntent == null) {
// if (count == 0) {
//// LogUtil.d("ForegroundOrBackground", System.currentTimeMillis() - leaveTime + " onActivityStarted");
// // 60秒后打开应用 显示开屏广告
// if (System.currentTimeMillis() - leaveTime >= 60000) {
//
// if (isYlhSplash) {
// isYlhSplash = false;
//
// if (ylhIntent == null) {
// // 优量汇广告
// ylhIntent = new Intent(activity, SplashADActivity.class);
// }
// activity.startActivity(ylhIntent);
// } else {
// isYlhSplash = true;
//
// if (csjIntent == null) {
// // 快手广告
// ksIntent = new Intent(activity, SplashKsADActivity.class);
// csjIntent = new Intent(activity, SplashCsjADActivity.class);
// }
// activity.startActivity(ksIntent);
}
}
}
// activity.startActivity(csjIntent);
//
//// if (ksIntent == null) {
//// // 快手广告
//// ksIntent = new Intent(activity, SplashKsADActivity.class);
//// }
//// activity.startActivity(ksIntent);
// }
//
// }
// }
count++;
}
......
......@@ -170,6 +170,7 @@
</FrameLayout>
<FrameLayout
android:visibility="gone"
android:id="@+id/flAwardAd"
android:layout_width="match_parent"
android:layout_height="wrap_content"
......
......@@ -42,6 +42,7 @@
</FrameLayout>
<FrameLayout
android:visibility="gone"
android:id="@+id/flSubsidykAd"
android:layout_width="340dp"
android:layout_height="340dp"
......
......@@ -85,6 +85,7 @@
</LinearLayout>
<FrameLayout
android:visibility="gone"
android:id="@+id/flMorningClockAd"
android:layout_width="340dp"
android:layout_height="340dp"
......
......@@ -41,6 +41,7 @@
</FrameLayout>
<FrameLayout
android:visibility="gone"
android:id="@+id/flWalkAd"
android:layout_width="340dp"
android:layout_height="340dp"
......
......@@ -40,6 +40,7 @@
</FrameLayout>
<FrameLayout
android:visibility="gone"
android:id="@+id/flWaterAd"
android:layout_width="340dp"
android:layout_height="340dp"
......
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