Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
A
android_flowbox
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_flowbox
Commits
b5b9547c
Commit
b5b9547c
authored
Jul 19, 2021
by
mengcuiguang2
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
优化权限弹窗,修改新人红包,修改余额提现
parent
11910e77
Changes
7
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
111 additions
and
81 deletions
+111
-81
FullGroManager.java
...c/main/java/com/mints/flowbox/ad/full/FullGroManager.java
+2
-0
WifiAdManager.kt
app/src/main/java/com/mints/flowbox/ad/wifi/WifiAdManager.kt
+68
-71
DrawcashBean.java
...c/main/java/com/mints/flowbox/mvp/model/DrawcashBean.java
+3
-3
DrawcashActivity.kt
...n/java/com/mints/flowbox/ui/activitys/DrawcashActivity.kt
+3
-3
MyFragment.kt
...src/main/java/com/mints/flowbox/ui/fragment/MyFragment.kt
+31
-0
dialog_power.xml
app/src/main/res/layout/dialog_power.xml
+2
-2
gradle.properties
gradle.properties
+2
-2
No files found.
app/src/main/java/com/mints/flowbox/ad/full/FullGroManager.java
View file @
b5b9547c
...
...
@@ -98,7 +98,9 @@ public class FullGroManager {
*/
// mTTFullVideoAd = new TTFullVideoAd(activity, CsjGroMoreManager.INSTANCE.getAPP_IN_COMMON_AD_UNIT_INTERSTITIAL_ID());
mTTFullVideoAd
=
new
TTFullVideoAd
(
activity
,
fullId
);
// mTTFullVideoAd = new TTFullVideoAd(activity, "946369785");
//声音控制 模板 2.0
// TTVideoOption videoOption = VideoOptionUtil.getTTVideoOption();
TTVideoOption
videoOption
=
VideoOptionUtil
.
getTTVideoOption2
();
//创建广告请求参数AdSlot,具体参数含义参考文档
...
...
app/src/main/java/com/mints/flowbox/ad/wifi/WifiAdManager.kt
View file @
b5b9547c
...
...
@@ -2,9 +2,6 @@ package com.mints.flowbox.ad.wifi
import
android.app.Activity
import
com.mints.flowbox.ad.full.FullGroManager
import
com.mints.flowbox.ad.inscreen.InterstitialGroManager
import
com.mints.flowbox.common.Constant
import
java.util.*
/**
* wifi广告管理
...
...
@@ -22,28 +19,28 @@ class WifiAdManager private constructor() {
private
var
wifiAdStatusListener
:
WifiAdStatusListener
?
=
null
// groMore插屏
private
var
interstitialGroManager
:
InterstitialGroManager
?
=
null
//
private var interstitialGroManager: InterstitialGroManager? = null
// groMore全屏
private
var
fullGroManager
:
FullGroManager
?
=
null
// 当前广告类型
private
var
currentAdType
=
""
//
private var currentAdType = ""
/**
* 预加载广告,必须传入activity
*/
fun
loadWifiAd
(
activity
:
Activity
)
{
currentAdType
=
getCurrentAdType
()
when
(
currentAdType
)
{
Constant
.
GROMORE_INSERTSCREEN_AD
->
{
preLoadInterstitialGroMore
(
activity
)
}
Constant
.
GROMORE_FULL_AD
->
{
preLoadFullGroMore
(
activity
,
true
)
}
}
//
currentAdType = getCurrentAdType()
//
//
when (currentAdType) {
//
Constant.GROMORE_INSERTSCREEN_AD -> {
//
preLoadInterstitialGroMore(activity)
//
}
//
Constant.GROMORE_FULL_AD -> {
// preLoadFullGroMore(activity,
true)
//
}
//
}
preLoadFullGroMore
(
activity
,
true
)
}
...
...
@@ -51,7 +48,7 @@ class WifiAdManager private constructor() {
/**
* 定义广告类型规则
*/
private
fun
getCurrentAdType
():
String
{
//
private fun getCurrentAdType(): String {
// var tempAdType = ""
// val randomInt = Random().nextInt(10)
// if (randomInt % 2 == 0) {
...
...
@@ -61,19 +58,19 @@ class WifiAdManager private constructor() {
// }
//
// return tempAdType
return
Constant
.
GROMORE_INSERTSCREEN
_AD
}
// return Constant.GROMORE_FULL
_AD
//
}
/**
* 插屏
*/
private
fun
preLoadInterstitialGroMore
(
activity
:
Activity
)
{
if
(
interstitialGroManager
!=
null
)
{
interstitialGroManager
?.
onDestroy
()
}
interstitialGroManager
=
InterstitialGroManager
()
interstitialGroManager
?.
loadInsertScreenAd
(
activity
,
false
,
2
)
}
//
private fun preLoadInterstitialGroMore(activity: Activity) {
//
if (interstitialGroManager != null) {
//
interstitialGroManager?.onDestroy()
//
}
//
interstitialGroManager = InterstitialGroManager()
// interstitialGroManager?.loadInsertScreenAd(activity, false
)
//
}
/**
* 全屏
...
...
@@ -91,61 +88,61 @@ class WifiAdManager private constructor() {
* 展示广告
*/
fun
showInterstitial
()
{
when
(
currentAdType
)
{
Constant
.
GROMORE_INSERTSCREEN_AD
->
{
interstitialGroManager
?.
setWifiAdStatusListener
(
object
:
WifiAdStatusListener
{
override
fun
adSuccess
()
{
}
override
fun
adFail
()
{
}
override
fun
adClose
()
{
wifiAdStatusListener
?.
adClose
()
}
})
interstitialGroManager
?.
showInteractionAd
()
}
Constant
.
GROMORE_FULL_AD
->
{
//
when (currentAdType) {
////
Constant.GROMORE_INSERTSCREEN_AD -> {
////
interstitialGroManager?.setWifiAdStatusListener(object : WifiAdStatusListener {
////
override fun adSuccess() {
////
////
}
////
////
override fun adFail() {
////
////
}
////
////
override fun adClose() {
////
wifiAdStatusListener?.adClose()
////
}
////
})
////
interstitialGroManager?.showInteractionAd()
////
}
//
Constant.GROMORE_FULL_AD -> {
fullGroManager
?.
setWifiAdStatusListener
(
wifiAdStatusListener
)
fullGroManager
?.
showFullAd
()
}
}
//
}
//
}
}
/**
* 展示广告
*/
fun
showInterstitial
(
_activity
:
Activity
)
{
when
(
currentAdType
)
{
Constant
.
GROMORE_INSERTSCREEN_AD
->
{
interstitialGroManager
?.
setWifiAdStatusListener
(
object
:
WifiAdStatusListener
{
override
fun
adSuccess
()
{
}
override
fun
adFail
()
{
}
override
fun
adClose
()
{
wifiAdStatusListener
?.
adClose
()
}
})
interstitialGroManager
?.
showInteractionAd
(
_activity
)
}
Constant
.
GROMORE_FULL_AD
->
{
fullGroManager
?.
showFullAd
(
_activity
,
wifiAdStatusListener
)
}
}
//
when (currentAdType) {
//
Constant.GROMORE_INSERTSCREEN_AD -> {
//
interstitialGroManager?.setWifiAdStatusListener(object : WifiAdStatusListener {
//
override fun adSuccess() {
//
//
}
//
//
override fun adFail() {
//
//
}
//
//
override fun adClose() {
//
wifiAdStatusListener?.adClose()
//
}
//
})
//
interstitialGroManager?.showInteractionAd(_activity)
//
}
//
Constant.GROMORE_FULL_AD -> {
fullGroManager
?.
showFullAd
(
_activity
,
wifiAdStatusListener
)
//
}
//
}
}
fun
onDestroy
()
{
interstitialGroManager
?.
onDestroy
()
interstitialGroManager
?.
setWifiAdStatusListener
(
null
)
interstitialGroManager
=
null
//
interstitialGroManager?.onDestroy()
//
interstitialGroManager?.setWifiAdStatusListener(null)
//
interstitialGroManager = null
fullGroManager
?.
onDestroy
()
fullGroManager
=
null
...
...
app/src/main/java/com/mints/flowbox/mvp/model/DrawcashBean.java
View file @
b5b9547c
...
...
@@ -13,18 +13,18 @@ public class DrawcashBean implements Serializable {
private
double
maxCashout
;
private
int
vedioComplete
;
private
String
remark
;
private
String
surplus
;
private
double
surplus
;
private
List
<
CashOutMoneyArrBean
>
cashOutMoneyArr
;
private
VedioRules
vedioRules
;
private
boolean
isJDNewUser
;
private
boolean
openJDCash
=
true
;
private
String
JDUrl
=
null
;
public
String
getSurplus
()
{
public
double
getSurplus
()
{
return
surplus
;
}
public
void
setSurplus
(
String
surplus
)
{
public
void
setSurplus
(
double
surplus
)
{
this
.
surplus
=
surplus
;
}
...
...
app/src/main/java/com/mints/flowbox/ui/activitys/DrawcashActivity.kt
View file @
b5b9547c
...
...
@@ -141,8 +141,8 @@ class DrawcashActivity : BaseActivity(),
R
.
id
.
tvDrawcashNext
->
{
if
(
priceList
!=
null
&&
priceList
!!
.
size
>
0
)
{
// 校验当前金币< 选择金币 =提示 去做任务
if
(
userConfig
?.
coin
!!
<
priceList
!!
[
drawcashAdapter
.
getPosition
()].
money
*
10000
)
{
showToast
(
"
金币
不足,快去做任务吧"
)
if
(
userConfig
?.
surplus
!!
<
priceList
!!
[
drawcashAdapter
.
getPosition
()].
money
)
{
showToast
(
"
余额
不足,快去做任务吧"
)
return
}
...
...
@@ -187,7 +187,7 @@ class DrawcashActivity : BaseActivity(),
tvDrawcashExplain
.
text
=
data
.
drawcashRule
tvDrawcashHint
.
text
=
data
.
drawcashHint
tvDrawcashGold
.
text
=
SpanUtils
()
.
append
(
data
.
surplus
)
.
append
(
data
.
surplus
.
toString
()
)
.
setFontSize
(
BubbleUtils
.
sp2px
(
36
))
.
append
(
" 元"
)
.
create
()
...
...
app/src/main/java/com/mints/flowbox/ui/fragment/MyFragment.kt
View file @
b5b9547c
...
...
@@ -96,6 +96,8 @@ class MyFragment : BaseFragment(),
initManager
()
initView
()
initRecy
()
showFirstGive
()
}
override
fun
onHiddenChanged
(
hidden
:
Boolean
)
{
...
...
@@ -925,4 +927,33 @@ class MyFragment : BaseFragment(),
override
fun
onRefresh
()
{
onResume
()
}
private
fun
showFirstGive
()
{
// 新人福利
// 游客首次提示1500新人奖励 且 不是分享包
val
channel
=
CommonUtils
.
getAppMetaData
(
MintsApplication
.
getContext
(),
"CHANNEL_NAME"
)
if
(!
TextUtils
.
equals
(
channel
,
Constant
.
CHANNEL_SHARE
)
&&
AppPreferencesManager
.
get
().
getBoolean
(
Constant
.
FIRST_VISITOR_FLAG
,
true
)
)
{
AppPreferencesManager
.
get
().
put
(
Constant
.
FIRST_VISITOR_FLAG
,
false
)
val
bundle
=
Bundle
()
bundle
.
putInt
(
Constant
.
MAIN_CUR_COIN
,
AppConfig
.
firstGiveCoin
)
bundle
.
putString
(
Constant
.
MAIN_CARRIER_TYPE
,
Constant
.
CARRIER_NEW_VISITOR
)
readyGo
(
AwardActivity
::
class
.
java
,
bundle
)
}
}
}
\ No newline at end of file
app/src/main/res/layout/dialog_power.xml
View file @
b5b9547c
...
...
@@ -198,10 +198,10 @@
android:layout_marginLeft=
"20dp"
android:layout_marginRight=
"20dp"
android:layout_marginBottom=
"10dp"
android:background=
"@color/
color_ccc
"
android:background=
"@color/
white
"
android:gravity=
"center"
android:text=
"不同意"
android:textColor=
"@color/
white
"
/>
android:textColor=
"@color/
color_ccc
"
/>
</LinearLayout>
</LinearLayout>
...
...
gradle.properties
View file @
b5b9547c
...
...
@@ -16,8 +16,8 @@ org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryErro
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true
#
DEBUG_URL="http://39.97.65.143:9082/fb-api/"
DEBUG_URL
=
"https://api.mints-id.com/fb-api/"
DEBUG_URL
=
"http://39.97.65.143:9082/fb-api/"
#
DEBUG_URL="https://api.mints-id.com/fb-api/"
RELEASE_URL
=
"https://api.mints-id.com/fb-api/"
RELEASE_KEY_PASSWORD
=
mints.flowbox
...
...
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