Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in / Register
Toggle navigation
D
Data Recovery White
Project
Project
Details
Activity
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
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wanglei
Data Recovery White
Commits
d4e8ed74
Commit
d4e8ed74
authored
Jul 26, 2024
by
wanglei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
...
parent
134049a6
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
8 deletions
+12
-8
MyApplication.kt
app/src/main/java/com/base/datarecovery/MyApplication.kt
+6
-2
AdmobNativeUtils.kt
.../java/com/base/datarecovery/ads/admob/AdmobNativeUtils.kt
+2
-2
AdMaxInterstitialUtils.kt
...a/com/base/datarecovery/ads/max/AdMaxInterstitialUtils.kt
+2
-2
AdMaxNativeUtils.kt
...in/java/com/base/datarecovery/ads/max/AdMaxNativeUtils.kt
+2
-2
No files found.
app/src/main/java/com/base/datarecovery/MyApplication.kt
View file @
d4e8ed74
...
...
@@ -92,7 +92,9 @@ class MyApplication : BaseApplication() {
private
fun
initLifeListener
()
{
registerActivityLifecycleCallbacks
(
object
:
ActivityLifecycleCallbacks
{
private
var
count
=
0
override
fun
onActivityCreated
(
activity
:
Activity
,
savedInstanceState
:
Bundle
?)
{}
override
fun
onActivityCreated
(
activity
:
Activity
,
savedInstanceState
:
Bundle
?)
{
ActivityManagerUtils
.
getInstance
().
addActivity
(
activity
)
}
override
fun
onActivityStarted
(
activity
:
Activity
)
{
LogEx
.
logDebug
(
TAG
,
"onActivityStarted"
)
...
...
@@ -157,7 +159,9 @@ class MyApplication : BaseApplication() {
override
fun
onActivitySaveInstanceState
(
activity
:
Activity
,
outState
:
Bundle
)
{}
override
fun
onActivityDestroyed
(
activity
:
Activity
)
{}
override
fun
onActivityDestroyed
(
activity
:
Activity
)
{
ActivityManagerUtils
.
getInstance
().
removeActivity
(
activity
)
}
})
}
...
...
app/src/main/java/com/base/datarecovery/ads/admob/AdmobNativeUtils.kt
View file @
d4e8ed74
...
...
@@ -101,9 +101,9 @@ object AdmobNativeUtils {
if
(
nativeAd
==
null
)
{
loadNativeAd
()
val
obj2
=
JSONObject
()
obj2
.
put
(
"reason"
,
"no
_
ad"
)
obj2
.
put
(
"reason"
,
"no
coach
ad"
)
obj2
.
put
(
"ad_unit"
,
"nativeAd"
)
EventUtils
.
event
(
"ad_
show_error
"
,
ext
=
obj2
)
EventUtils
.
event
(
"ad_
nocache_pull
"
,
ext
=
obj2
)
}
else
{
loadingListener
?.
invoke
()
}
...
...
app/src/main/java/com/base/datarecovery/ads/max/AdMaxInterstitialUtils.kt
View file @
d4e8ed74
...
...
@@ -124,9 +124,9 @@ object AdMaxInterstitialUtils {
}
else
{
LogEx
.
logDebug
(
TAG
,
"展示广告时,没有缓存,需要拉取。"
)
val
obj2
=
JSONObject
()
obj2
.
put
(
"reason"
,
"no ad"
)
obj2
.
put
(
"reason"
,
"no
cache
ad"
)
obj2
.
put
(
"ad_unit"
,
"interAd"
)
EventUtils
.
event
(
"ad_
show_error
"
,
ext
=
obj2
)
EventUtils
.
event
(
"ad_
nocache_pull
"
,
ext
=
obj2
)
val
loaded
=
loadInterstitialAd
(
activity
)
if
(
loaded
)
{
LogEx
.
logDebug
(
TAG
,
"loaded=true"
)
...
...
app/src/main/java/com/base/datarecovery/ads/max/AdMaxNativeUtils.kt
View file @
d4e8ed74
...
...
@@ -141,9 +141,9 @@ object AdMaxNativeUtils {
if
(
nativeAd
==
null
)
{
nativeAdLoader
.
loadAd
()
val
obj2
=
JSONObject
()
obj2
.
put
(
"reason"
,
"no_ad"
)
obj2
.
put
(
"reason"
,
"no_
cache_
ad"
)
obj2
.
put
(
"ad_unit"
,
"nativeAd"
)
EventUtils
.
event
(
"ad_
show_error
"
,
ext
=
obj2
)
EventUtils
.
event
(
"ad_
nocache_pull
"
,
ext
=
obj2
)
}
else
{
loadingListener
?.
invoke
()
}
...
...
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