Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
android_goodmoney
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_goodmoney
Commits
ece8fc3c
Commit
ece8fc3c
authored
Nov 27, 2020
by
jyx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
活动页信息流预加载
parent
e1d8d3c1
Changes
15
Show whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
234 additions
and
71 deletions
+234
-71
TTNativeExpressManager.java
...a/com/mints/goodmoney/manager/TTNativeExpressManager.java
+1
-1
TTPreLoadCarrierExpressManager.java
...nts/goodmoney/manager/TTPreLoadCarrierExpressManager.java
+107
-0
TTPreLoadExpressManager.java
.../com/mints/goodmoney/manager/TTPreLoadExpressManager.java
+11
-14
FoodSubsidyActivity.kt
...a/com/mints/goodmoney/ui/activitys/FoodSubsidyActivity.kt
+17
-2
MainActivity.kt
...ain/java/com/mints/goodmoney/ui/activitys/MainActivity.kt
+2
-0
MorningClockActivity.kt
.../com/mints/goodmoney/ui/activitys/MorningClockActivity.kt
+24
-11
WalkActivity.kt
...ain/java/com/mints/goodmoney/ui/activitys/WalkActivity.kt
+20
-5
WaterActivity.kt
...in/java/com/mints/goodmoney/ui/activitys/WaterActivity.kt
+12
-7
FriendsFragment.kt
...n/java/com/mints/goodmoney/ui/fragment/FriendsFragment.kt
+3
-3
MyFragment.kt
...c/main/java/com/mints/goodmoney/ui/fragment/MyFragment.kt
+14
-4
activity_award.xml
GoodMoney/app/src/main/res/layout/activity_award.xml
+3
-3
activity_food_subsidy.xml
GoodMoney/app/src/main/res/layout/activity_food_subsidy.xml
+4
-4
activity_walk.xml
GoodMoney/app/src/main/res/layout/activity_walk.xml
+1
-2
activity_water.xml
GoodMoney/app/src/main/res/layout/activity_water.xml
+5
-6
fragment_main_friends.xml
GoodMoney/app/src/main/res/layout/fragment_main_friends.xml
+10
-9
No files found.
GoodMoney/app/src/main/java/com/mints/goodmoney/manager/TTNativeExpressManager.java
View file @
ece8fc3c
...
...
@@ -67,7 +67,7 @@ public class TTNativeExpressManager {
* @param viewHeight
*/
private
void
getTtNativeExpress
(
String
codeId
,
FrameLayout
view
,
float
viewWidth
,
float
viewHeight
)
{
Context
context
=
MintsApplication
.
getContext
();
//
Context context= MintsApplication.getContext();
//step4:创建广告请求参数AdSlot,具体参数含义参考文档
AdSlot
adSlot
=
new
AdSlot
.
Builder
()
.
setCodeId
(
codeId
)
//广告位id
...
...
GoodMoney/app/src/main/java/com/mints/goodmoney/manager/TTPreLoadCarrierExpressManager.java
0 → 100644
View file @
ece8fc3c
package
com
.
mints
.
goodmoney
.
manager
;
import
android.content.Context
;
import
android.os.Handler
;
import
android.os.HandlerThread
;
import
android.os.Looper
;
import
android.os.Message
;
import
android.widget.FrameLayout
;
import
androidx.annotation.NonNull
;
import
com.mints.goodmoney.MintsApplication
;
public
class
TTPreLoadCarrierExpressManager
{
private
static
TTPreLoadCarrierExpressManager
_inst
;
private
FrameLayout
ttFrameLayout
;
private
TTNativeExpressManager
ttNativeExpressManager
;
private
HandlerThread
mHandlerThread
=
new
HandlerThread
(
"TTPreLoadHandlerThread"
);
private
Handler
mWorkHandler
;
private
Handler
mMainHandler
=
new
Handler
(
Looper
.
getMainLooper
());
private
int
mTTPreLoadWhat
=
0x3243434
;
public
static
TTPreLoadCarrierExpressManager
getInstance
()
{
if
(
_inst
==
null
)
{
_inst
=
new
TTPreLoadCarrierExpressManager
();
}
return
_inst
;
}
private
TTPreLoadCarrierExpressManager
()
{
init
();
}
private
void
init
()
{
ttNativeExpressManager
=
new
TTNativeExpressManager
();
ttNativeExpressManager
.
initTTAd
(
false
);
// 启动异步线程
mHandlerThread
.
start
();
mWorkHandler
=
new
Handler
(
mHandlerThread
.
getLooper
())
{
@Override
public
void
handleMessage
(
@NonNull
Message
msg
)
{
// 工作线程进行加载数据
if
(
msg
.
what
==
mTTPreLoadWhat
)
{
loadTtFrameLayoutInThread
((
String
)
msg
.
obj
);
}
}
};
}
public
void
onDestroy
()
{
mHandlerThread
.
quit
();
mHandlerThread
=
null
;
mWorkHandler
.
removeCallbacksAndMessages
(
null
);
mWorkHandler
=
null
;
}
public
FrameLayout
getTtFrameLayout
()
{
return
ttFrameLayout
;
}
private
void
loadTtFrameLayoutInThread
(
String
codeId
)
{
Context
context
=
MintsApplication
.
getContext
();
ttFrameLayout
=
null
;
try
{
ttFrameLayout
=
new
FrameLayout
(
context
);
ttNativeExpressManager
.
getNativeExpressInit
(
codeId
,
ttFrameLayout
,
340
,
0
);
ttNativeExpressManager
.
setTTNativeExpressManagerListener
(
view
->
{
mMainHandler
.
post
(()
->
{
// 主线程更新UI操作
if
(
view
==
null
)
{
ttFrameLayout
=
null
;
}
else
{
try
{
ttFrameLayout
=
view
;
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
ttFrameLayout
=
null
;
}
}
});
});
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
/**
* 预加载 信息流
*/
public
void
loadTtFrameLayout
(
String
codeId
)
{
Message
msg
=
Message
.
obtain
();
msg
.
what
=
mTTPreLoadWhat
;
msg
.
obj
=
codeId
;
mWorkHandler
.
sendMessage
(
msg
);
}
}
GoodMoney/app/src/main/java/com/mints/goodmoney/manager/TTPreLoadExpressManager.java
View file @
ece8fc3c
...
...
@@ -38,13 +38,12 @@ public class TTPreLoadExpressManager {
* 预加载 信息流
*/
public
void
loadTtFrameLayout
()
{
Context
context
=
MintsApplication
.
getContext
();
Context
context
=
MintsApplication
.
getContext
();
ttFrameLayout
=
null
;
try
{
ttFrameLayout
=
new
FrameLayout
(
context
);
ttNativeExpressManager
.
getNativeExpressInit
(
TtCsjAdManager
.
TT_AD_NATIVEEXPRESS_AWARD
,
ttFrameLayout
,
310
,
0
);
ttNativeExpressManager
.
setTTNativeExpressManagerListener
(
new
TTNativeExpressManager
.
TTNativeExpressManagerListener
()
{
@Override
public
void
setTtExpressView
(
FrameLayout
view
)
{
ttNativeExpressManager
.
setTTNativeExpressManagerListener
(
view
->
{
if
(
view
==
null
)
{
ttFrameLayout
=
null
;
}
else
{
...
...
@@ -56,12 +55,10 @@ public class TTPreLoadExpressManager {
ttFrameLayout
=
null
;
}
}
}
});
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
ttFrameLayout
=
null
;
}
}
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/activitys/FoodSubsidyActivity.kt
View file @
ece8fc3c
...
...
@@ -5,6 +5,7 @@ import android.view.View
import
com.mints.goodmoney.R
import
com.mints.goodmoney.common.Constant
import
com.mints.goodmoney.manager.TTNativeExpressManager
import
com.mints.goodmoney.manager.TTPreLoadCarrierExpressManager
import
com.mints.goodmoney.manager.TtCsjAdManager
import
com.mints.goodmoney.mvp.model.MealBean
import
com.mints.goodmoney.mvp.presenters.FoodSubsidyPresenter
...
...
@@ -92,6 +93,9 @@ class FoodSubsidyActivity : BaseActivity(), View.OnClickListener, FoodSubsidyVie
readyGo
(
AwardActivity
::
class
.
java
,
bundle
)
}
}
// 预加载信息流
TTPreLoadCarrierExpressManager
.
getInstance
().
loadTtFrameLayout
(
TtCsjAdManager
.
TT_AD_NATIVEEXPRESS_EAT
)
}
...
...
@@ -99,9 +103,20 @@ class FoodSubsidyActivity : BaseActivity(), View.OnClickListener, FoodSubsidyVie
* 初始化信息iyc
*/
private
fun
initExpress
()
{
try
{
//
try {
// ttNativeExpressManager.initTTAd(false)
ttNativeExpressManager
.
getNativeExpressInit
(
TtCsjAdManager
.
TT_AD_NATIVEEXPRESS_EAT
,
flWalkAd
,
320f
,
0f
)
// ttNativeExpressManager.getNativeExpressInit(TtCsjAdManager.TT_AD_NATIVEEXPRESS_EAT, flSubsidykAd, 320f, 0f)
// } catch (e: Exception) {
// e.printStackTrace()
// }
try
{
if
(
TTPreLoadCarrierExpressManager
.
getInstance
().
ttFrameLayout
!=
null
)
{
if
(
flSubsidykAd
!=
null
)
{
flSubsidykAd
.
removeAllViews
()
flSubsidykAd
.
addView
(
TTPreLoadCarrierExpressManager
.
getInstance
().
ttFrameLayout
)
}
}
}
catch
(
e
:
Exception
)
{
e
.
printStackTrace
()
}
...
...
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/activitys/MainActivity.kt
View file @
ece8fc3c
...
...
@@ -12,6 +12,7 @@ import com.mints.goodmoney.R
import
com.mints.goodmoney.ad.video.VedioAdingManager
import
com.mints.goodmoney.common.AppConfig
import
com.mints.goodmoney.common.Constant
import
com.mints.goodmoney.manager.TTPreLoadCarrierExpressManager
import
com.mints.goodmoney.manager.ZhangyueManager
import
com.mints.goodmoney.mvp.views.MainView
import
com.mints.goodmoney.ui.activitys.base.BaseActivity
...
...
@@ -70,6 +71,7 @@ class MainActivity : BaseActivity(), MainView, View.OnClickListener {
super
.
onDestroy
()
TTPreLoadCarrierExpressManager
.
getInstance
().
onDestroy
()
VedioAdingManager
.
getInstance
(
this
).
setVedioAdingListener
(
null
)
VedioAdingManager
.
getInstance
(
this
).
onDestory
()
}
...
...
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/activitys/MorningClockActivity.kt
View file @
ece8fc3c
...
...
@@ -7,6 +7,7 @@ import com.mints.goodmoney.R
import
com.mints.goodmoney.ad.video.VedioAdingManager
import
com.mints.goodmoney.common.Constant
import
com.mints.goodmoney.manager.TTNativeExpressManager
import
com.mints.goodmoney.manager.TTPreLoadCarrierExpressManager
import
com.mints.goodmoney.manager.TtCsjAdManager
import
com.mints.goodmoney.mvp.model.MorningClockBean
import
com.mints.goodmoney.mvp.model.VedioAdingBean
...
...
@@ -15,7 +16,6 @@ import com.mints.goodmoney.mvp.views.MorningClockView
import
com.mints.goodmoney.ui.activitys.base.BaseActivity
import
com.mints.goodmoney.ui.adapter.MorningClockAdapter
import
com.mints.goodmoney.utils.SpanUtils
import
kotlinx.android.synthetic.main.activity_drawcash.*
import
kotlinx.android.synthetic.main.activity_morning_clock.*
/**
...
...
@@ -64,6 +64,9 @@ class MorningClockActivity : BaseActivity()
R
.
id
.
ivMorningClockBack
->
finish
()
R
.
id
.
tvMorningClockClick
->
{
awardVedio
()
// 预加载信息流
TTPreLoadCarrierExpressManager
.
getInstance
().
loadTtFrameLayout
(
TtCsjAdManager
.
TT_AD_NATIVEEXPRESS_MORNINGCLOCK
)
}
}
}
...
...
@@ -73,19 +76,18 @@ class MorningClockActivity : BaseActivity()
morningClockList
=
data
.
targetList
if
(
data
.
isCanClick
)
{
tvMorningClockClick
.
setBackground
(
resources
.
getDrawable
(
R
.
drawable
.
shape_water_btn
)
)
tvMorningClockClick
.
background
=
resources
.
getDrawable
(
R
.
drawable
.
shape_water_btn
)
tvMorningClockClick
.
isEnabled
=
true
}
else
{
tvMorningClockClick
.
setBackground
(
resources
.
getDrawable
(
R
.
drawable
.
shape_tv_gold_none
)
)
tvMorningClockClick
.
background
=
resources
.
getDrawable
(
R
.
drawable
.
shape_tv_gold_none
)
tvMorningClockClick
.
isEnabled
=
false
}
tvMorningClockClick
.
text
=
data
.
buttonMsg
tvMorningClockDay
.
setText
(
SpanUtils
()
tvMorningClockDay
.
text
=
SpanUtils
()
.
append
(
"打卡领金币 已连续打卡"
)
.
append
(
"${data.continuityDays}"
).
setForegroundColor
(
resources
.
getColor
(
R
.
color
.
main_mints
))
.
append
(
"天"
)
.
create
()
)
.
create
(
)
initRvView
()
}
...
...
@@ -178,9 +180,20 @@ class MorningClockActivity : BaseActivity()
* 初始化信息iyc
*/
private
fun
initExpress
()
{
// try {
// ttNativeExpressManager.initTTAd(false)
// ttNativeExpressManager.getNativeExpressInit(TtCsjAdManager.TT_AD_NATIVEEXPRESS_MORNINGCLOCK, flMorningClockAd, 320f, 0f)
// } catch (e: Exception) {
// e.printStackTrace()
// }
try
{
ttNativeExpressManager
.
initTTAd
(
false
)
ttNativeExpressManager
.
getNativeExpressInit
(
TtCsjAdManager
.
TT_AD_NATIVEEXPRESS_MORNINGCLOCK
,
flMorningClockAd
,
320f
,
0f
)
if
(
TTPreLoadCarrierExpressManager
.
getInstance
().
ttFrameLayout
!=
null
)
{
if
(
flMorningClockAd
!=
null
)
{
flMorningClockAd
.
removeAllViews
()
flMorningClockAd
.
addView
(
TTPreLoadCarrierExpressManager
.
getInstance
().
ttFrameLayout
)
}
}
}
catch
(
e
:
Exception
)
{
e
.
printStackTrace
()
}
...
...
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/activitys/WalkActivity.kt
View file @
ece8fc3c
...
...
@@ -4,7 +4,7 @@ import android.os.Bundle
import
android.view.View
import
com.mints.goodmoney.R
import
com.mints.goodmoney.common.Constant
import
com.mints.goodmoney.manager.TT
Native
ExpressManager
import
com.mints.goodmoney.manager.TT
PreLoadCarrier
ExpressManager
import
com.mints.goodmoney.manager.TtCsjAdManager
import
com.mints.goodmoney.mvp.model.WalkBean
import
com.mints.goodmoney.mvp.presenters.WalkPresenter
...
...
@@ -21,7 +21,8 @@ import kotlinx.android.synthetic.main.activity_walk.*
class
WalkActivity
:
BaseActivity
(),
View
.
OnClickListener
,
WalkView
,
StepView
.
StepViewListener
{
private
val
walkPresenter
by
lazy
{
WalkPresenter
()
}
private
val
ttNativeExpressManager
by
lazy
{
TTNativeExpressManager
()
}
// private val ttNativeExpressManager by lazy { TTNativeExpressManager() }
private
var
curCoin
=
0
//点击的汽泡金币
override
fun
getContentViewLayoutID
()
=
R
.
layout
.
activity_walk
...
...
@@ -45,7 +46,7 @@ class WalkActivity : BaseActivity(), View.OnClickListener, WalkView, StepView.St
super
.
onDestroy
()
svWalk
?.
destoryAnim
()
ttNativeExpressManager
.
onTTAdDestroy
()
//
ttNativeExpressManager.onTTAdDestroy()
walkPresenter
.
detachView
()
}
...
...
@@ -97,15 +98,29 @@ class WalkActivity : BaseActivity(), View.OnClickListener, WalkView, StepView.St
bundle
.
putString
(
Constant
.
MAIN_CARRIER_TYPE
,
Constant
.
CARRIER_WALK_BUBBLE
)
readyGo
(
AwardActivity
::
class
.
java
,
bundle
)
}
// 预加载信息流
TTPreLoadCarrierExpressManager
.
getInstance
().
loadTtFrameLayout
(
TtCsjAdManager
.
TT_AD_NATIVEEXPRESS_WALK
)
}
/**
* 初始化信息iyc
*/
private
fun
initExpress
()
{
// try {
// ttNativeExpressManager.initTTAd(false)
// ttNativeExpressManager.getNativeExpressInit(TtCsjAdManager.TT_AD_NATIVEEXPRESS_WALK, flWalkAd, 320f, 0f)
// } catch (e: Exception) {
// e.printStackTrace()
// }
try
{
ttNativeExpressManager
.
initTTAd
(
false
)
ttNativeExpressManager
.
getNativeExpressInit
(
TtCsjAdManager
.
TT_AD_NATIVEEXPRESS_WALK
,
flWalkAd
,
320f
,
0f
)
if
(
TTPreLoadCarrierExpressManager
.
getInstance
().
ttFrameLayout
!=
null
)
{
if
(
flWalkAd
!=
null
)
{
flWalkAd
.
removeAllViews
()
flWalkAd
.
addView
(
TTPreLoadCarrierExpressManager
.
getInstance
().
ttFrameLayout
)
}
}
}
catch
(
e
:
Exception
)
{
e
.
printStackTrace
()
}
...
...
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/activitys/WaterActivity.kt
View file @
ece8fc3c
...
...
@@ -4,7 +4,7 @@ import android.os.Bundle
import
android.view.View
import
com.mints.goodmoney.R
import
com.mints.goodmoney.common.Constant
import
com.mints.goodmoney.manager.TT
Native
ExpressManager
import
com.mints.goodmoney.manager.TT
PreLoadCarrier
ExpressManager
import
com.mints.goodmoney.manager.TtCsjAdManager
import
com.mints.goodmoney.mvp.model.WaterBean
import
com.mints.goodmoney.mvp.presenters.WaterPresenter
...
...
@@ -17,11 +17,9 @@ import kotlinx.android.synthetic.main.activity_water.*
* 作者:孟崔广
* 时间:2020/10/13 11:55
*/
class
WaterActivity
:
BaseActivity
(),
View
.
OnClickListener
,
WaterView
.
WaterViewListener
,
com
.
mints
.
goodmoney
.
mvp
.
views
.
WaterView
{
class
WaterActivity
:
BaseActivity
(),
View
.
OnClickListener
,
WaterView
.
WaterViewListener
,
com
.
mints
.
goodmoney
.
mvp
.
views
.
WaterView
{
private
val
waterPresenter
by
lazy
{
WaterPresenter
()
}
private
val
ttNativeExpressManager
by
lazy
{
TTNativeExpressManager
()
}
override
fun
getContentViewLayoutID
()
=
R
.
layout
.
activity_water
...
...
@@ -53,7 +51,7 @@ class WaterActivity : BaseActivity(), View.OnClickListener, WaterView.WaterViewL
wvWater
?.
destoryAnim
()
wvWater
?.
closeWaterViewTime
()
ttNativeExpressManager
.
onTTAdDestroy
()
//
ttNativeExpressManager.onTTAdDestroy()
waterPresenter
.
detachView
()
}
...
...
@@ -69,6 +67,9 @@ class WaterActivity : BaseActivity(), View.OnClickListener, WaterView.WaterViewL
if
(
water
==
0
)
{
waterPresenter
.
clickForWater
()
}
// 预加载信息流
TTPreLoadCarrierExpressManager
.
getInstance
().
loadTtFrameLayout
(
TtCsjAdManager
.
TT_AD_NATIVEEXPRESS_WATER
)
}
override
fun
clickForWaterSuc
(
waterCoin
:
Int
)
{
...
...
@@ -110,8 +111,12 @@ class WaterActivity : BaseActivity(), View.OnClickListener, WaterView.WaterViewL
*/
private
fun
initExpress
()
{
try
{
ttNativeExpressManager
.
initTTAd
(
false
)
ttNativeExpressManager
.
getNativeExpressInit
(
TtCsjAdManager
.
TT_AD_NATIVEEXPRESS_WATER
,
flWaterAd
,
320f
,
0f
)
if
(
TTPreLoadCarrierExpressManager
.
getInstance
().
ttFrameLayout
!=
null
)
{
if
(
flWaterAd
!=
null
)
{
flWaterAd
.
removeAllViews
()
flWaterAd
.
addView
(
TTPreLoadCarrierExpressManager
.
getInstance
().
ttFrameLayout
)
}
}
}
catch
(
e
:
Exception
)
{
e
.
printStackTrace
()
}
...
...
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/fragment/FriendsFragment.kt
View file @
ece8fc3c
...
...
@@ -213,6 +213,7 @@ class FriendsFragment : BaseFragment(), FriendsView, OnRefreshListener, View.OnC
* 显示红包动画
*/
fun
showRedbox
(
view
:
View
?)
{
rope
=
null
rope
=
YoYo
.
with
(
Techniques
.
Pulse
).
duration
(
1200
)
.
interpolate
(
AccelerateDecelerateInterpolator
())
.
repeat
(-
1
)
...
...
@@ -234,7 +235,6 @@ class FriendsFragment : BaseFragment(), FriendsView, OnRefreshListener, View.OnC
btn_get_bonus
.
isEnabled
=
data
.
status
==
0
&&
data
.
cash
>
0
if
(
data
.
button
==
"戳我分红"
)
{
btn_get_bonus
.
isEnabled
=
true
btn_get_bonus
.
setTextColor
(
resources
.
getColor
(
R
.
color
.
white
))
btn_get_bonus
.
setBackgroundResource
(
R
.
drawable
.
shape_btn_friends_unenabled
)
showRedbox
(
btn_get_bonus
)
...
...
@@ -259,8 +259,8 @@ class FriendsFragment : BaseFragment(), FriendsView, OnRefreshListener, View.OnC
.
create
()
tv_bonus_money
.
text
=
SpanUtils
()
.
append
(
data
.
cash
.
toString
()).
setFo
ntSize
(
50
).
setFo
regroundColor
(
resources
.
getColor
(
R
.
color
.
color_E72C2B
))
.
append
(
"元"
).
setFontSize
(
30
).
setForegroundColor
(
resources
.
getColor
(
R
.
color
.
color_E72C2B
))
.
append
(
data
.
cash
.
toString
()).
setForegroundColor
(
resources
.
getColor
(
R
.
color
.
color_E72C2B
))
.
append
(
"元"
).
setFontSize
(
22
).
setForegroundColor
(
resources
.
getColor
(
R
.
color
.
color_E72C2B
))
.
create
()
tv_bonus_rate
.
text
=
SpanUtils
()
...
...
GoodMoney/app/src/main/java/com/mints/goodmoney/ui/fragment/MyFragment.kt
View file @
ece8fc3c
...
...
@@ -20,9 +20,7 @@ import com.mints.goodmoney.R
import
com.mints.goodmoney.ad.video.VedioAdingManager
import
com.mints.goodmoney.common.AppConfig
import
com.mints.goodmoney.common.Constant
import
com.mints.goodmoney.manager.BxmManager
import
com.mints.goodmoney.manager.UserManager
import
com.mints.goodmoney.manager.YwhzManager
import
com.mints.goodmoney.manager.*
import
com.mints.goodmoney.mvp.model.*
import
com.mints.goodmoney.mvp.presenters.MyPresenter
import
com.mints.goodmoney.mvp.views.MyView
...
...
@@ -363,7 +361,15 @@ class MyFragment : BaseFragment(), MyView, OnItemChildClickListener, OnRefreshLi
// 已登录
if
(
userManager
.
wxOpenid
.
isNotEmpty
())
{
GlideUtils
.
loadImageViewLoding
(
context
,
userManager
.
wxHeader
,
item_title_avatar
,
R
.
mipmap
.
ic_my
,
R
.
mipmap
.
ic_my
)
if
(
userManager
.
wxName
.
isEmpty
())
{
var
mobile
=
userManager
.
mobile
if
(
mobile
.
isNotEmpty
())
{
mobile
=
mobile
.
substring
(
0
,
3
)
+
"****"
+
mobile
.
substring
(
mobile
.
length
-
4
,
mobile
.
length
)
}
item_title_id
.
text
=
"手机:$mobile"
}
else
{
item_title_id
.
text
=
userManager
.
wxName
}
}
else
{
var
mobile
=
userManager
.
mobile
if
(
mobile
.
isNotEmpty
())
{
...
...
@@ -599,9 +605,11 @@ class MyFragment : BaseFragment(), MyView, OnItemChildClickListener, OnRefreshLi
// 自有界面
when
(
hotBean
.
toUrl
)
{
Constant
.
HOT_ACTIVITY_WATER
->
{
TTPreLoadCarrierExpressManager
.
getInstance
().
loadTtFrameLayout
(
TtCsjAdManager
.
TT_AD_NATIVEEXPRESS_WATER
)
readyGo
(
WaterActivity
::
class
.
java
)
}
Constant
.
HOT_ACTIVITY_WALK
->
{
TTPreLoadCarrierExpressManager
.
getInstance
().
loadTtFrameLayout
(
TtCsjAdManager
.
TT_AD_NATIVEEXPRESS_WALK
)
readyGo
(
WalkActivity
::
class
.
java
)
}
Constant
.
HOT_ACTIVITY_CARD
->
{
...
...
@@ -611,12 +619,14 @@ class MyFragment : BaseFragment(), MyView, OnItemChildClickListener, OnRefreshLi
readyGo
(
LiebaoGameActivity
::
class
.
java
)
}
Constant
.
HOT_ACTIVITY_MORNINGCLOCK
->
{
TTPreLoadCarrierExpressManager
.
getInstance
().
loadTtFrameLayout
(
TtCsjAdManager
.
TT_AD_NATIVEEXPRESS_MORNINGCLOCK
)
readyGo
(
MorningClockActivity
::
class
.
java
)
}
Constant
.
HOT_ACTIVITY_BXM
->
{
// 消费变现猫事件
}
Constant
.
HOT_ACTIVITY_EAT
->
{
TTPreLoadCarrierExpressManager
.
getInstance
().
loadTtFrameLayout
(
TtCsjAdManager
.
TT_AD_NATIVEEXPRESS_EAT
)
readyGo
(
FoodSubsidyActivity
::
class
.
java
)
}
else
->
{
...
...
GoodMoney/app/src/main/res/layout/activity_award.xml
View file @
ece8fc3c
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:app=
"http://schemas.android.com/apk/res-auto"
xmlns:tools=
"http://schemas.android.com/tools"
android:layout_width=
"match_parent"
android:layout_height=
"match_parent"
...
...
@@ -110,11 +109,12 @@
<FrameLayout
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:layout_
marginTop=
"10dp
"
android:layout_
gravity=
"center
"
android:layout_marginLeft=
"25dp"
android:layout_marginTop=
"10dp"
android:layout_marginRight=
"25dp"
android:layout_gravity=
"center"
android:background=
"@drawable/shape_bg_write"
>
<FrameLayout
android:id=
"@+id/flAwardAd"
android:layout_width=
"wrap_content"
...
...
GoodMoney/app/src/main/res/layout/activity_food_subsidy.xml
View file @
ece8fc3c
...
...
@@ -7,8 +7,10 @@
android:overScrollMode=
"never"
>
<LinearLayout
android:id=
"@+id/ll_food"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:gravity=
"center_horizontal"
android:orientation=
"vertical"
>
<FrameLayout
...
...
@@ -41,14 +43,12 @@
</FrameLayout>
<FrameLayout
android:id=
"@+id/fl
Wal
kAd"
android:id=
"@+id/fl
Subsidy
kAd"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_horizontal"
android:layout_marginTop=
"20dp"
android:background=
"@color/full_transparent"
>
</FrameLayout>
android:background=
"@color/full_transparent"
/>
</LinearLayout>
</ScrollView>
GoodMoney/app/src/main/res/layout/activity_walk.xml
View file @
ece8fc3c
...
...
@@ -46,9 +46,8 @@
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_horizontal"
android:layout_marginTop=
"20dp"
android:background=
"@color/full_transparent"
>
android:background=
"@color/full_transparent"
/
>
</FrameLayout>
</LinearLayout>
</ScrollView>
GoodMoney/app/src/main/res/layout/activity_water.xml
View file @
ece8fc3c
...
...
@@ -23,14 +23,14 @@
android:layout_height=
"wrap_content"
android:layout_marginTop=
"20dp"
android:padding=
"15dp"
android:src=
"@drawable/yl_mp_ic_back_left"
></ImageView
>
android:src=
"@drawable/yl_mp_ic_back_left"
/
>
<ImageView
android:layout_width=
"wrap_content"
android:
src=
"@mipmap/ic_font_water
"
android:
layout_height=
"wrap_content
"
android:layout_gravity=
"center_horizontal"
android:layout_marginTop=
"60dp"
android:
layout_height=
"wrap_content"
/>
android:
src=
"@mipmap/ic_font_water"
/>
<com.mints.goodmoney.ui.widgets.WaterView
android:id=
"@+id/wvWater"
...
...
@@ -42,13 +42,12 @@
<FrameLayout
android:id=
"@+id/flWaterAd"
android:layout_marginTop=
"20dp"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_gravity=
"center_horizontal"
android:background=
"@color/full_transparent"
>
android:layout_marginTop=
"20dp"
android:background=
"@color/full_transparent"
/>
</FrameLayout>
</LinearLayout>
</ScrollView>
GoodMoney/app/src/main/res/layout/fragment_main_friends.xml
View file @
ece8fc3c
...
...
@@ -186,19 +186,19 @@
android:id=
"@+id/tv_yesterday_bonus"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:gravity=
"
right
"
android:padding
Right
=
"10dp"
android:gravity=
"
end
"
android:padding
End
=
"10dp"
android:text=
"@string/dot"
android:textSize=
"2
0
sp"
/>
android:textSize=
"2
2
sp"
/>
<TextView
android:id=
"@+id/tv_today_bonus"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:gravity=
"
right
"
android:padding
Right
=
"10dp"
android:gravity=
"
end
"
android:padding
End
=
"10dp"
android:text=
"@string/dot"
android:textSize=
"2
0
sp"
/>
android:textSize=
"2
2
sp"
/>
</LinearLayout>
...
...
@@ -214,7 +214,7 @@
<TextView
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginStart=
"
10
dp"
android:layout_marginStart=
"
6
dp"
android:layout_marginTop=
"15dp"
android:text=
"分红收益"
android:textColor=
"@color/color_CF7E7E"
/>
...
...
@@ -223,9 +223,10 @@
android:id=
"@+id/tv_bonus_money"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_marginStart=
"
10
dp"
android:layout_marginStart=
"
6
dp"
android:layout_marginTop=
"40dp"
android:text=
"@string/dot"
/>
android:text=
"@string/dot"
android:textSize=
"22sp"
/>
<Button
android:id=
"@+id/btn_get_bonus"
...
...
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