Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
android_youyou
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
android
android_youyou
Commits
741652f9
Commit
741652f9
authored
Mar 30, 2021
by
mengcuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
开放代码位
parent
5f85fbc8
Changes
8
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
98 additions
and
98 deletions
+98
-98
build.gradle
app/build.gradle
+2
-2
WenshuApplication.java
app/src/main/java/com/wenshu/youyou/WenshuApplication.java
+5
-3
TTPreLoadExpressXmlyManager.java
...wenshu/youyou/ad/express/TTPreLoadExpressXmlyManager.java
+1
-1
TtCsjAdManager.java
...c/main/java/com/wenshu/youyou/manager/TtCsjAdManager.java
+2
-2
AwardActivity.kt
...main/java/com/wenshu/youyou/ui/activitys/AwardActivity.kt
+83
-85
MainActivity.kt
.../main/java/com/wenshu/youyou/ui/activitys/MainActivity.kt
+0
-2
MainFragment.kt
...c/main/java/com/wenshu/youyou/ui/fragment/MainFragment.kt
+3
-2
MyFragment.kt
...src/main/java/com/wenshu/youyou/ui/fragment/MyFragment.kt
+2
-1
No files found.
app/build.gradle
View file @
741652f9
...
@@ -9,8 +9,8 @@ android {
...
@@ -9,8 +9,8 @@ android {
applicationId
"com.wenshu.youyou"
applicationId
"com.wenshu.youyou"
minSdkVersion
rootProject
.
ext
.
androidMinSdkVersion
minSdkVersion
rootProject
.
ext
.
androidMinSdkVersion
targetSdkVersion
rootProject
.
ext
.
androidTargetSdkVersion
targetSdkVersion
rootProject
.
ext
.
androidTargetSdkVersion
versionCode
3
versionCode
4
versionName
"1.0.
3
"
versionName
"1.0.
4
"
flavorDimensions
"default"
flavorDimensions
"default"
// dex突破65535的限制
// dex突破65535的限制
...
...
app/src/main/java/com/wenshu/youyou/WenshuApplication.java
View file @
741652f9
...
@@ -12,9 +12,11 @@ import androidx.multidex.MultiDexApplication;
...
@@ -12,9 +12,11 @@ import androidx.multidex.MultiDexApplication;
import
com.hjq.toast.ToastUtils
;
import
com.hjq.toast.ToastUtils
;
import
com.wenshu.youyou.common.Constant
;
import
com.wenshu.youyou.common.Constant
;
import
com.wenshu.youyou.manager.MhManager
;
import
com.wenshu.youyou.manager.MiitHelper
;
import
com.wenshu.youyou.manager.MiitHelper
;
import
com.wenshu.youyou.manager.RsNewsManager
;
import
com.wenshu.youyou.manager.RsNewsManager
;
import
com.wenshu.youyou.manager.TtCsjAdManager
;
import
com.wenshu.youyou.manager.TtCsjAdManager
;
import
com.wenshu.youyou.manager.WnManager
;
import
com.wenshu.youyou.manager.YlVideoManager
;
import
com.wenshu.youyou.manager.YlVideoManager
;
import
com.wenshu.youyou.manager.YlhAdManager
;
import
com.wenshu.youyou.manager.YlhAdManager
;
import
com.wenshu.youyou.net.LoanService
;
import
com.wenshu.youyou.net.LoanService
;
...
@@ -117,10 +119,10 @@ public class WenshuApplication extends MultiDexApplication {
...
@@ -117,10 +119,10 @@ public class WenshuApplication extends MultiDexApplication {
// KsManager.INSTANCE.initKs(this);
// KsManager.INSTANCE.initKs(this);
// 闪电盒子
// 闪电盒子
//
WnManager.INSTANCE.initWn(this);
WnManager
.
INSTANCE
.
initWn
(
this
);
// 枫岚广告
// 枫岚广告
//
MhManager.INSTANCE.initWn(this);
MhManager
.
INSTANCE
.
initWn
(
this
);
// 天卓珊瑚
// 天卓珊瑚
// TzManager.INSTANCE.initTz(this);
// TzManager.INSTANCE.initTz(this);
...
@@ -132,7 +134,7 @@ public class WenshuApplication extends MultiDexApplication {
...
@@ -132,7 +134,7 @@ public class WenshuApplication extends MultiDexApplication {
RsNewsManager
.
INSTANCE
.
init
(
this
);
RsNewsManager
.
INSTANCE
.
init
(
this
);
// 喜马拉雅
// 喜马拉雅
//
initXmly();
initXmly
();
// 自定义logger
// 自定义logger
bindLogger
();
bindLogger
();
...
...
app/src/main/java/com/wenshu/youyou/ad/express/TTPreLoadExpressXmlyManager.java
View file @
741652f9
...
@@ -28,7 +28,7 @@ public class TTPreLoadExpressXmlyManager {
...
@@ -28,7 +28,7 @@ public class TTPreLoadExpressXmlyManager {
}
}
private
TTPreLoadExpressXmlyManager
()
{
private
TTPreLoadExpressXmlyManager
()
{
//
init();
init
();
}
}
private
void
init
()
{
private
void
init
()
{
...
...
app/src/main/java/com/wenshu/youyou/manager/TtCsjAdManager.java
View file @
741652f9
...
@@ -24,14 +24,14 @@ public class TtCsjAdManager {
...
@@ -24,14 +24,14 @@ public class TtCsjAdManager {
public
static
String
TT_AD_BANNER_MY
=
"945812059"
;
// 个人中心
public
static
String
TT_AD_BANNER_MY
=
"945812059"
;
// 个人中心
public
static
String
TT_AD_BANNER_JULEYUN
=
""
;
// 聚乐云
public
static
String
TT_AD_BANNER_JULEYUN
=
""
;
// 聚乐云
/*激励视频*/
/*激励视频*/
public
static
String
TT_AD_VEDIO_MAIN_DEV
=
""
;
// 开发使用
public
static
String
TT_AD_VEDIO_MAIN_DEV
=
"
945811826
"
;
// 开发使用
public
static
String
TT_AD_VEDIO_DRINK
=
"945811826"
;
//喝水打卡
public
static
String
TT_AD_VEDIO_DRINK
=
"945811826"
;
//喝水打卡
public
static
String
TT_AD_VEDIO_WALK
=
"945811826"
;
//走路打卡
public
static
String
TT_AD_VEDIO_WALK
=
"945811826"
;
//走路打卡
public
static
String
TT_AD_VEDIO_MAIN
=
"945811826"
;
// 我的界面视频
public
static
String
TT_AD_VEDIO_MAIN
=
"945811826"
;
// 我的界面视频
public
static
String
TT_AD_VEDIO_ERASE
=
"945811826"
;
// 刮刮乐
public
static
String
TT_AD_VEDIO_ERASE
=
"945811826"
;
// 刮刮乐
public
static
String
TT_AD_VEDIO_TURNABLE
=
"945811826"
;
// 大转盘
public
static
String
TT_AD_VEDIO_TURNABLE
=
"945811826"
;
// 大转盘
public
static
String
TT_AD_VEDIO_MOREDIALOG
=
"945811826"
;
// 气泡
public
static
String
TT_AD_VEDIO_MOREDIALOG
=
"945811826"
;
// 气泡
public
static
String
TT_AD_VEDIO_SIGN
=
""
;
// 签到
public
static
String
TT_AD_VEDIO_SIGN
=
"
945811826
"
;
// 签到
public
static
String
TT_AD_VEDIO_EAT
=
"945811826"
;
// 饭补
public
static
String
TT_AD_VEDIO_EAT
=
"945811826"
;
// 饭补
public
static
String
TT_AD_VEDIO_OFFINELINE
=
"945811826"
;
// 离线弹框
public
static
String
TT_AD_VEDIO_OFFINELINE
=
"945811826"
;
// 离线弹框
public
static
String
TT_AD_VEDIO_DRAWCASH
=
"945811826"
;
// 提现
public
static
String
TT_AD_VEDIO_DRAWCASH
=
"945811826"
;
// 提现
...
...
app/src/main/java/com/wenshu/youyou/ui/activitys/AwardActivity.kt
View file @
741652f9
...
@@ -77,7 +77,7 @@ class AwardActivity : BaseActivity(), AwardView, View.OnClickListener {
...
@@ -77,7 +77,7 @@ class AwardActivity : BaseActivity(), AwardView, View.OnClickListener {
pushAward
()
pushAward
()
}
}
//
initExpress()
initExpress
()
initListener
()
initListener
()
initDataView
()
initDataView
()
}
}
...
@@ -412,90 +412,88 @@ class AwardActivity : BaseActivity(), AwardView, View.OnClickListener {
...
@@ -412,90 +412,88 @@ class AwardActivity : BaseActivity(), AwardView, View.OnClickListener {
}
}
override
fun
onClick
(
v
:
View
)
{
override
fun
onClick
(
v
:
View
)
{
when
(
v
.
id
)
{
R
.
id
.
ivAwardBack
->
{
finish
()
finish
()
}
R
.
id
.
tvAwardHigh
->
{
when
(
superTaskStatus
)
{
// 播放激励视频,注册安装监听
0
->
{
// 是否开启应用使用情况权限
if
(
AppUtil
.
isOpenUsageStats
())
{
registerBroad
()
awardVideo
()
}
else
{
AppTryPlayManager
.
openAppUsageStats
(
this
)
}
}
// 下载完成,点击去试玩
1
->
{
if
(
mCurrentPkg
==
null
)
{
showToast
(
"任务异常,请重试~"
)
awardPresenter
.
setHighTaskType
(
"0"
)
}
else
{
if
(
AppUtil
.
checkPackInfo
(
mContext
,
mCurrentPkg
!!
))
{
AppTryPlayManager
.
toTryPlay
(
mCurrentPkg
!!
)
}
else
{
showToast
(
"未找到当前APP、可能被卸载,请重试~"
)
}
}
}
// 试玩时间不足,继续试玩
2
->
{
if
(
mCurrentPkg
==
null
)
{
showToast
(
"任务异常,请重试~"
)
awardPresenter
.
setHighTaskType
(
"0"
)
}
else
{
if
(
AppUtil
.
checkPackInfo
(
mContext
,
mCurrentPkg
!!
))
{
AppTryPlayManager
.
toTryPlay
(
mCurrentPkg
!!
)
}
else
{
showToast
(
"未找到当前APP、可能被卸载,请重试~"
)
}
}
}
// 试玩完成,领取奖励
3
->
{
val
vo
=
HashMap
<
String
,
Any
>()
vo
[
"carrierType"
]
=
Constant
.
CARRIER_HIGH_ACTIVITY
awardPresenter
.
reportAddCoinMsg
(
vo
)
// when (v.id) {
readyGoThenKill
(
DrawcashActivity
::
class
.
java
)
// R.id.ivAwardBack -> {
}
// finish()
}
// }
}
// R.id.tvAwardHigh -> {
R
.
id
.
tvAwardNext
->
{
// when (superTaskStatus) {
// 普通视频奖励 走公共下载监听
// // 播放激励视频,注册安装监听
AppConfig
.
isSuperTask
=
false
// 0 -> {
superTaskStatus
=
4
// // 是否开启应用使用情况权限
// if (AppUtil.isOpenUsageStats()) {
when
(
carrierType
)
{
// registerBroad()
// 只有看视频才能领金币
// awardVideo()
Constant
.
CARRIER_OFFLINE_DOUBLE
,
Constant
.
CARRIER_SIGNIN_HOMEPAGE_CARD
,
// } else {
Constant
.
CARRIER_CHALLENGE_TURN
,
Constant
.
CARRIER_CHALLENGE_CARD
,
// AppTryPlayManager.openAppUsageStats(this)
Constant
.
CARRIER_WALK_BUBBLE
,
Constant
.
CARRIER_EATMEAL_SUBSIDY
,
// }
Constant
.
CARRIER_WALK
,
Constant
.
CARRIER_HOMEWATER
->
{
// }
awardVideo
()
// // 下载完成,点击去试玩
}
// 1 -> {
Constant
.
CARRIER_BLESSINGBAG_DOUBLE
,
Constant
.
CARRIER_CHALLENGE_SHAREFRIEND_DOUBLE
,
// if (mCurrentPkg == null) {
Constant
.
CARRIER_HOMEVEDIO_DOUBLE
,
Constant
.
CARRIER_SMALLHOMEVEDIO_DOUBLE
,
// showToast("任务异常,请重试~")
Constant
.
CARRIER_RUISHINEWS_DOUBLE
->
{
// awardPresenter.setHighTaskType("0")
// 翻倍载体上送友盟
//
pushUmengEvent
()
// } else {
awardVideo
()
// if (AppUtil.checkPackInfo(mContext, mCurrentPkg!!)) {
}
// AppTryPlayManager.toTryPlay(mCurrentPkg!!)
Constant
.
CARRIER_NEW_VISITOR
->
{
// } else {
readyGoThenKill
(
WxLoginActivity
::
class
.
java
)
// showToast("未找到当前APP、可能被卸载,请重试~")
}
// }
else
->
{
// }
finish
()
// }
}
// // 试玩时间不足,继续试玩
}
// 2 -> {
}
// if (mCurrentPkg == null) {
}
// showToast("任务异常,请重试~")
// awardPresenter.setHighTaskType("0")
// } else {
// if (AppUtil.checkPackInfo(mContext, mCurrentPkg!!)) {
// AppTryPlayManager.toTryPlay(mCurrentPkg!!)
// } else {
// showToast("未找到当前APP、可能被卸载,请重试~")
// }
// }
// }
// // 试玩完成,领取奖励
// 3 -> {
// val vo = HashMap<String, Any>()
// vo["carrierType"] = Constant.CARRIER_HIGH_ACTIVITY
// awardPresenter.reportAddCoinMsg(vo)
//
// readyGoThenKill(DrawcashActivity::class.java)
// }
// }
// }
// R.id.tvAwardNext -> {
// // 普通视频奖励 走公共下载监听
// AppConfig.isSuperTask = false
// superTaskStatus = 4
//
// when (carrierType) {
// // 只有看视频才能领金币
// Constant.CARRIER_OFFLINE_DOUBLE, Constant.CARRIER_SIGNIN_HOMEPAGE_CARD,
// Constant.CARRIER_CHALLENGE_TURN, Constant.CARRIER_CHALLENGE_CARD,
// Constant.CARRIER_WALK_BUBBLE, Constant.CARRIER_EATMEAL_SUBSIDY,
// Constant.CARRIER_WALK, Constant.CARRIER_HOMEWATER -> {
// awardVideo()
// }
// Constant.CARRIER_BLESSINGBAG_DOUBLE, Constant.CARRIER_CHALLENGE_SHAREFRIEND_DOUBLE,
// Constant.CARRIER_HOMEVEDIO_DOUBLE, Constant.CARRIER_SMALLHOMEVEDIO_DOUBLE,
// Constant.CARRIER_RUISHINEWS_DOUBLE -> {
// // 翻倍载体上送友盟
// pushUmengEvent()
// awardVideo()
// }
// Constant.CARRIER_NEW_VISITOR -> {
// readyGoThenKill(WxLoginActivity::class.java)
// }
// else -> {
// finish()
// }
// }
// }
// }
}
}
/**
/**
...
...
app/src/main/java/com/wenshu/youyou/ui/activitys/MainActivity.kt
View file @
741652f9
...
@@ -45,8 +45,6 @@ class MainActivity : BaseActivity(), MainView, View.OnClickListener {
...
@@ -45,8 +45,6 @@ class MainActivity : BaseActivity(), MainView, View.OnClickListener {
override
fun
getContentViewLayoutID
()
=
R
.
layout
.
activity_main
override
fun
getContentViewLayoutID
()
=
R
.
layout
.
activity_main
override
fun
initViewsAndEvents
()
{
override
fun
initViewsAndEvents
()
{
// ZhangyueManager.onCreateIreader(baseApplication)
showShortVedioLayout
()
showShortVedioLayout
()
if
(
moneyFragment
==
null
)
{
if
(
moneyFragment
==
null
)
{
...
...
app/src/main/java/com/wenshu/youyou/ui/fragment/MainFragment.kt
View file @
741652f9
...
@@ -36,6 +36,7 @@ import com.wenshu.youyou.ui.widgets.seekbar.BubbleUtils
...
@@ -36,6 +36,7 @@ import com.wenshu.youyou.ui.widgets.seekbar.BubbleUtils
import
com.wenshu.youyou.utils.LogUtil
import
com.wenshu.youyou.utils.LogUtil
import
com.wenshu.youyou.utils.TimeRender
import
com.wenshu.youyou.utils.TimeRender
import
com.wenshu.library.utils.CommonUtils
import
com.wenshu.library.utils.CommonUtils
import
com.wenshu.youyou.ad.express.TTPreLoadExpressXmlyManager
import
com.yilan.sdk.player.ylplayer.YLPlayerConfig
import
com.yilan.sdk.player.ylplayer.YLPlayerConfig
import
com.yilan.sdk.player.ylplayer.callback.OnPlayerCallBack
import
com.yilan.sdk.player.ylplayer.callback.OnPlayerCallBack
import
com.yilan.sdk.ui.configs.YLUIConfig
import
com.yilan.sdk.ui.configs.YLUIConfig
...
@@ -92,8 +93,8 @@ class MainFragment : BaseFragment(), HomeView, View.OnClickListener {
...
@@ -92,8 +93,8 @@ class MainFragment : BaseFragment(), HomeView, View.OnClickListener {
// 奖励页预加载 信息流广告
// 奖励页预加载 信息流广告
PreLoadExpressManager
.
loadADFrameLayout
()
PreLoadExpressManager
.
loadADFrameLayout
()
//
// 刷新喜马拉雅信息流
// 刷新喜马拉雅信息流
//
TTPreLoadExpressXmlyManager.getInstance().loadTtFrameLayout()
TTPreLoadExpressXmlyManager
.
getInstance
().
loadTtFrameLayout
()
// 首次显示权限弹窗
// 首次显示权限弹窗
showPowerDialog
()
showPowerDialog
()
...
...
app/src/main/java/com/wenshu/youyou/ui/fragment/MyFragment.kt
View file @
741652f9
...
@@ -27,6 +27,7 @@ import com.wenshu.youyou.R
...
@@ -27,6 +27,7 @@ import com.wenshu.youyou.R
import
com.wenshu.youyou.ad.banner.BannerManager
import
com.wenshu.youyou.ad.banner.BannerManager
import
com.wenshu.youyou.ad.express.PreLoadExpressManager
import
com.wenshu.youyou.ad.express.PreLoadExpressManager
import
com.wenshu.youyou.ad.express.TTPreLoadCarrierExpressManager
import
com.wenshu.youyou.ad.express.TTPreLoadCarrierExpressManager
import
com.wenshu.youyou.ad.express.TTPreLoadExpressXmlyManager
import
com.wenshu.youyou.ad.video.VideoAdingManager
import
com.wenshu.youyou.ad.video.VideoAdingManager
import
com.wenshu.youyou.common.AppConfig
import
com.wenshu.youyou.common.AppConfig
import
com.wenshu.youyou.common.Constant
import
com.wenshu.youyou.common.Constant
...
@@ -156,7 +157,7 @@ class MyFragment : BaseFragment(),
...
@@ -156,7 +157,7 @@ class MyFragment : BaseFragment(),
BannerManager
.
getTtBanner
(
TtCsjAdManager
.
TT_AD_BANNER_MY
,
fl_my_banner
)
BannerManager
.
getTtBanner
(
TtCsjAdManager
.
TT_AD_BANNER_MY
,
fl_my_banner
)
// 刷新喜马拉雅信息流
// 刷新喜马拉雅信息流
//
TTPreLoadExpressXmlyManager.getInstance().loadTtFrameLayout()
TTPreLoadExpressXmlyManager
.
getInstance
().
loadTtFrameLayout
()
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment