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
ba1bed4e
Commit
ba1bed4e
authored
Jul 21, 2021
by
mengcuiguang2
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
代码优化
parent
fd3309b6
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
18 additions
and
54 deletions
+18
-54
InsertScreenAdManager.kt
...va/com/mints/flowbox/ad/inscreen/InsertScreenAdManager.kt
+2
-2
AwardPresenter.java
...java/com/mints/flowbox/mvp/presenters/AwardPresenter.java
+2
-2
TzVideoAdPresenter.kt
...va/com/mints/flowbox/mvp/presenters/TzVideoAdPresenter.kt
+0
-37
YlhVideoAdPresenter.java
...com/mints/flowbox/mvp/presenters/YlhVideoAdPresenter.java
+3
-2
AwardActivity.kt
...main/java/com/mints/flowbox/ui/activitys/AwardActivity.kt
+2
-2
TurnTableFragment.kt
...n/java/com/mints/flowbox/ui/fragment/TurnTableFragment.kt
+9
-9
No files found.
app/src/main/java/com/mints/flowbox/ad/inscreen/InsertScreenAdManager.kt
View file @
ba1bed4e
...
@@ -52,7 +52,7 @@ class InsertScreenAdManager {
...
@@ -52,7 +52,7 @@ class InsertScreenAdManager {
}
}
override
fun
adClose
()
{
override
fun
adClose
()
{
wifiAdStatusListener
?.
adClose
()
}
}
})
})
}
}
...
@@ -76,7 +76,7 @@ class InsertScreenAdManager {
...
@@ -76,7 +76,7 @@ class InsertScreenAdManager {
}
}
override
fun
adClose
()
{
override
fun
adClose
()
{
wifiAdStatusListener
?.
adClose
()
}
}
})
})
}
}
...
...
app/src/main/java/com/mints/flowbox/mvp/presenters/AwardPresenter.java
View file @
ba1bed4e
...
@@ -133,7 +133,7 @@ public class AwardPresenter extends BasePresenter<AwardView> {
...
@@ -133,7 +133,7 @@ public class AwardPresenter extends BasePresenter<AwardView> {
public
void
reportAddCoinMsg
(
HashMap
<
String
,
Object
>
vo
)
{
public
void
reportAddCoinMsg
(
HashMap
<
String
,
Object
>
vo
)
{
AppHttpManager
.
getInstance
(
loanApplication
)
AppHttpManager
.
getInstance
(
loanApplication
)
.
call
(
loanService
.
reportAddCoinMsg
(
vo
),
.
call
(
loanService
.
reportAddCoinMsg
(
vo
),
new
BaseSubscriber
<
BaseResponse
<
Object
>>()
{
new
BaseSubscriber
<
BaseResponse
<
Json
Object
>>()
{
@Override
@Override
public
void
onCompleted
()
{
public
void
onCompleted
()
{
if
(
isLinkView
())
return
;
if
(
isLinkView
())
return
;
...
@@ -145,7 +145,7 @@ public class AwardPresenter extends BasePresenter<AwardView> {
...
@@ -145,7 +145,7 @@ public class AwardPresenter extends BasePresenter<AwardView> {
}
}
@Override
@Override
public
void
onNext
(
BaseResponse
<
Object
>
baseResponse
)
{
public
void
onNext
(
BaseResponse
<
Json
Object
>
baseResponse
)
{
if
(
isLinkView
())
return
;
if
(
isLinkView
())
return
;
}
}
});
});
...
...
app/src/main/java/com/mints/flowbox/mvp/presenters/TzVideoAdPresenter.kt
deleted
100644 → 0
View file @
fd3309b6
package
com.mints.flowbox.mvp.presenters
import
android.app.Activity
import
com.mints.flowbox.MintsApplication
import
com.mints.flowbox.mvp.model.BaseResponse
import
com.mints.flowbox.mvp.views.VideoAdManagerView
import
com.mints.library.net.neterror.BaseSubscriber
import
com.mints.library.net.neterror.Throwable
import
rx.android.schedulers.AndroidSchedulers
import
java.util.*
class
TzVideoAdPresenter
:
BasePresenter
<
VideoAdManagerView
>()
{
fun
reportAddCoinMsg
(
activity
:
Activity
?,
vo
:
HashMap
<
String
,
Any
>)
{
if
(
activity
==
null
)
return
loanApplication
=
activity
.
application
as
MintsApplication
loanService
=
loanApplication
.
loanService
subscription
=
loanService
.
reportAddCoinMsg
(
vo
)
.
observeOn
(
AndroidSchedulers
.
mainThread
())
.
subscribeOn
(
loanApplication
.
defaultSubscribeScheduler
())
.
subscribe
(
object
:
BaseSubscriber
<
BaseResponse
<
Any
>>()
{
override
fun
onCompleted
()
{}
override
fun
onError
(
e
:
Throwable
)
{
}
override
fun
onNext
(
baseResponse
:
BaseResponse
<
Any
>)
{}
})
}
fun
dispose
()
{
loanService
=
null
loanApplication
=
null
if
(
subscription
!=
null
&&
!
subscription
.
isUnsubscribed
())
{
subscription
.
unsubscribe
()
}
}
}
\ No newline at end of file
app/src/main/java/com/mints/flowbox/mvp/presenters/YlhVideoAdPresenter.java
View file @
ba1bed4e
...
@@ -2,6 +2,7 @@ package com.mints.flowbox.mvp.presenters;
...
@@ -2,6 +2,7 @@ package com.mints.flowbox.mvp.presenters;
import
android.app.Activity
;
import
android.app.Activity
;
import
com.google.gson.JsonObject
;
import
com.mints.flowbox.MintsApplication
;
import
com.mints.flowbox.MintsApplication
;
import
com.mints.flowbox.mvp.model.BaseResponse
;
import
com.mints.flowbox.mvp.model.BaseResponse
;
import
com.mints.flowbox.mvp.views.VideoAdManagerView
;
import
com.mints.flowbox.mvp.views.VideoAdManagerView
;
...
@@ -30,7 +31,7 @@ public class YlhVideoAdPresenter extends BasePresenter<VideoAdManagerView> {
...
@@ -30,7 +31,7 @@ public class YlhVideoAdPresenter extends BasePresenter<VideoAdManagerView> {
subscription
=
loanService
.
reportAddCoinMsg
(
vo
)
subscription
=
loanService
.
reportAddCoinMsg
(
vo
)
.
observeOn
(
AndroidSchedulers
.
mainThread
())
.
observeOn
(
AndroidSchedulers
.
mainThread
())
.
subscribeOn
(
loanApplication
.
defaultSubscribeScheduler
())
.
subscribeOn
(
loanApplication
.
defaultSubscribeScheduler
())
.
subscribe
(
new
BaseSubscriber
<
BaseResponse
<
Object
>>()
{
.
subscribe
(
new
BaseSubscriber
<
BaseResponse
<
Json
Object
>>()
{
@Override
@Override
public
void
onCompleted
()
{
public
void
onCompleted
()
{
...
@@ -42,7 +43,7 @@ public class YlhVideoAdPresenter extends BasePresenter<VideoAdManagerView> {
...
@@ -42,7 +43,7 @@ public class YlhVideoAdPresenter extends BasePresenter<VideoAdManagerView> {
}
}
@Override
@Override
public
void
onNext
(
BaseResponse
<
Object
>
baseResponse
)
{
public
void
onNext
(
BaseResponse
<
Json
Object
>
baseResponse
)
{
}
}
});
});
...
...
app/src/main/java/com/mints/flowbox/ui/activitys/AwardActivity.kt
View file @
ba1bed4e
...
@@ -715,8 +715,8 @@ class AwardActivity : BaseActivity(), AwardView, View.OnClickListener {
...
@@ -715,8 +715,8 @@ class AwardActivity : BaseActivity(), AwardView, View.OnClickListener {
val
rateBig
=
BigDecimal
(
"10000"
)
val
rateBig
=
BigDecimal
(
"10000"
)
val
cashStr
=
allcoinBig
.
divide
(
rateBig
).
setScale
(
2
,
BigDecimal
.
ROUND_DOWN
).
toString
()
val
cashStr
=
allcoinBig
.
divide
(
rateBig
).
setScale
(
2
,
BigDecimal
.
ROUND_DOWN
).
toString
()
if
(
data
.
gromore
Coin
>
0
)
{
if
(
AppConfig
.
award
Coin
>
0
)
{
tvAwardContent
.
text
=
"${
data.gromore
Coin}金币已到账"
tvAwardContent
.
text
=
"${
AppConfig.award
Coin}金币已到账"
tvAwardNext
.
visibility
=
View
.
GONE
tvAwardNext
.
visibility
=
View
.
GONE
}
}
...
...
app/src/main/java/com/mints/flowbox/ui/fragment/TurnTableFragment.kt
View file @
ba1bed4e
...
@@ -126,6 +126,14 @@ class TurnTableFragment : BaseFragment(), TurnTableView, AdapterView.OnItemClick
...
@@ -126,6 +126,14 @@ class TurnTableFragment : BaseFragment(), TurnTableView, AdapterView.OnItemClick
insertScreenAdManager
?.
setInsertScreenAdStatusListener
(
object
:
insertScreenAdManager
?.
setInsertScreenAdStatusListener
(
object
:
WifiAdStatusListener
{
WifiAdStatusListener
{
override
fun
adSuccess
()
{
override
fun
adSuccess
()
{
}
override
fun
adFail
()
{
}
override
fun
adClose
()
{
try
{
try
{
if
(
turnTableData
?.
surplus
!!
<=
0
)
{
if
(
turnTableData
?.
surplus
!!
<=
0
)
{
return
return
...
@@ -133,7 +141,7 @@ class TurnTableFragment : BaseFragment(), TurnTableView, AdapterView.OnItemClick
...
@@ -133,7 +141,7 @@ class TurnTableFragment : BaseFragment(), TurnTableView, AdapterView.OnItemClick
insertScreenAdManager
?.
onDestroy
()
insertScreenAdManager
?.
onDestroy
()
if
(
AppPreferencesManager
.
get
()
if
(
AppPreferencesManager
.
get
()
.
getBoolean
(
Constant
.
TURNTABLE_SWITCH_BUTTON
,
false
)
.
getBoolean
(
Constant
.
TURNTABLE_SWITCH_BUTTON
,
false
)
)
{
)
{
clickTurn
()
clickTurn
()
}
}
...
@@ -142,14 +150,6 @@ class TurnTableFragment : BaseFragment(), TurnTableView, AdapterView.OnItemClick
...
@@ -142,14 +150,6 @@ class TurnTableFragment : BaseFragment(), TurnTableView, AdapterView.OnItemClick
e
.
printStackTrace
()
e
.
printStackTrace
()
}
}
}
}
override
fun
adFail
()
{
}
override
fun
adClose
()
{
}
})
})
switchButton
?.
isOpened
=
switchButton
?.
isOpened
=
...
...
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