Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Sign in / Register
Toggle navigation
F
File Recovery RecycleBin
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
File Recovery RecycleBin
Commits
1c6c6646
Commit
1c6c6646
authored
Aug 06, 2024
by
wanglei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
...
parent
d10e2c06
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
48 additions
and
18 deletions
+48
-18
AppManagerActivity.kt
...overyrecyclebin/activity/appmanager/AppManagerActivity.kt
+13
-1
AppProcessActivity.kt
...overyrecyclebin/activity/appprocess/AppProcessActivity.kt
+8
-4
BatteryActivity.kt
...ilerecoveryrecyclebin/activity/battery/BatteryActivity.kt
+10
-1
CleanJunkActivity.kt
...ecoveryrecyclebin/activity/junkclean/CleanJunkActivity.kt
+1
-1
RepeatActivity.kt
.../filerecoveryrecyclebin/activity/repeat/RepeatActivity.kt
+1
-2
ScreenShotActivity.kt
...overyrecyclebin/activity/screenshot/ScreenShotActivity.kt
+1
-2
AdmobMaxHelper.kt
...ava/com/base/filerecoveryrecyclebin/ads/AdmobMaxHelper.kt
+12
-0
AdmobInterstitialUtils.kt
...ilerecoveryrecyclebin/ads/admob/AdmobInterstitialUtils.kt
+0
-5
DialogViews.kt
.../java/com/base/filerecoveryrecyclebin/view/DialogViews.kt
+2
-2
No files found.
app/src/main/java/com/base/filerecoveryrecyclebin/activity/appmanager/AppManagerActivity.kt
View file @
1c6c6646
...
...
@@ -13,11 +13,14 @@ import androidx.core.view.updatePadding
import
androidx.lifecycle.lifecycleScope
import
com.base.filerecoveryrecyclebin.adapter.AppManagerAdapter
import
com.base.filerecoveryrecyclebin.ads.AdmobMaxHelper
import
com.base.filerecoveryrecyclebin.ads.admob.AdmobInterstitialUtils
import
com.base.filerecoveryrecyclebin.bean.AppBean
import
com.base.filerecoveryrecyclebin.databinding.ActivityAppManagerBinding
import
com.base.filerecoveryrecyclebin.help.BaseActivity
import
com.base.filerecoveryrecyclebin.utils.BarUtils
import
com.base.filerecoveryrecyclebin.utils.RamUtils.ramPair
import
com.base.filerecoveryrecyclebin.view.DialogViews.showDeletePermanentlyDialog
import
com.base.filerecoveryrecyclebin.view.DialogViews.showExitFunctionDialog
import
kotlinx.coroutines.Dispatchers
import
kotlinx.coroutines.launch
...
...
@@ -79,7 +82,16 @@ class AppManagerActivity : BaseActivity<ActivityAppManagerBinding>() {
override
fun
initListener
()
{
super
.
initListener
()
onBackPressedDispatcher
.
addCallback
{
finishToMain
()
showExitFunctionDialog
{
showAd
->
if
(
showAd
){
AdmobMaxHelper
.
admobMaxShowInterstitialAd
(
this
@AppManagerActivity
,
isLoading
=
false
)
{
finishToMain
()
}
}
else
{
finishToMain
()
}
}
}
binding
.
flFanhui
.
setOnClickListener
{
onBackPressedDispatcher
.
onBackPressed
()
...
...
app/src/main/java/com/base/filerecoveryrecyclebin/activity/appprocess/AppProcessActivity.kt
View file @
1c6c6646
...
...
@@ -14,6 +14,7 @@ import androidx.core.view.updatePadding
import
androidx.lifecycle.lifecycleScope
import
com.base.filerecoveryrecyclebin.adapter.AppManagerAdapter
import
com.base.filerecoveryrecyclebin.ads.AdmobMaxHelper
import
com.base.filerecoveryrecyclebin.ads.AdmobMaxHelper.showBackInterAdSp
import
com.base.filerecoveryrecyclebin.bean.AppBean
import
com.base.filerecoveryrecyclebin.databinding.ActivityAppProcessBinding
import
com.base.filerecoveryrecyclebin.help.BaseActivity
...
...
@@ -64,10 +65,13 @@ class AppProcessActivity : BaseActivity<ActivityAppProcessBinding>() {
super
.
initListener
()
onBackPressedDispatcher
.
addCallback
{
showAppProcessExitDialog
(
ePercent
)
{
// AdmobMaxHelper.admobMaxShowInterstitialAd(this@AppProcessActivity) {
//
// }
finishToMain
()
if
(
showBackInterAdSp
())
{
AdmobMaxHelper
.
admobMaxShowInterstitialAd
(
this
@AppProcessActivity
)
{
finishToMain
()
}
}
else
{
finishToMain
()
}
}
}
binding
.
flFanhui
.
setOnClickListener
{
...
...
app/src/main/java/com/base/filerecoveryrecyclebin/activity/battery/BatteryActivity.kt
View file @
1c6c6646
...
...
@@ -15,6 +15,7 @@ import com.base.filerecoveryrecyclebin.help.BaseActivity
import
com.base.filerecoveryrecyclebin.receiver.BatteryReceiver
import
com.base.filerecoveryrecyclebin.utils.BarUtils
import
com.base.filerecoveryrecyclebin.utils.LogEx
import
com.base.filerecoveryrecyclebin.view.DialogViews.showExitFunctionDialog
import
kotlin.math.abs
...
...
@@ -63,7 +64,15 @@ class BatteryActivity : BaseActivity<ActivityBatteryBinding>() {
override
fun
initListener
()
{
super
.
initListener
()
onBackPressedDispatcher
.
addCallback
{
finishToMain
()
showExitFunctionDialog
{
showAd
->
if
(
showAd
)
{
AdmobMaxHelper
.
admobMaxShowInterstitialAd
(
this
@BatteryActivity
)
{
finishToMain
()
}
}
else
{
finishToMain
()
}
}
}
binding
.
flFanhui
.
setOnClickListener
{
onBackPressedDispatcher
.
onBackPressed
()
...
...
app/src/main/java/com/base/filerecoveryrecyclebin/activity/junkclean/CleanJunkActivity.kt
View file @
1c6c6646
...
...
@@ -65,7 +65,7 @@ class CleanJunkActivity : BaseActivity<ActivityLayoutCleanJunkBinding>() {
if
(
scanFinish
)
{
if
(
junkExpandAdapter
.
getAllChildItemCount
()
==
0
)
{
binding
.
tvBtn
.
visibility
=
View
.
GONE
binding
.
llTwoBtn
.
visibility
=
View
.
VISIBL
E
binding
.
llTwoBtn
.
visibility
=
View
.
GON
E
}
else
{
binding
.
tvBtn
.
isVisible
=
true
binding
.
tvBtn
.
isEnabled
=
true
...
...
app/src/main/java/com/base/filerecoveryrecyclebin/activity/repeat/RepeatActivity.kt
View file @
1c6c6646
...
...
@@ -8,7 +8,6 @@ import androidx.core.view.updatePadding
import
androidx.lifecycle.lifecycleScope
import
com.base.filerecoveryrecyclebin.adapter.MediaAdapter
import
com.base.filerecoveryrecyclebin.ads.AdmobMaxHelper
import
com.base.filerecoveryrecyclebin.ads.admob.AdmobInterstitialUtils.showInterAdSp
import
com.base.filerecoveryrecyclebin.bean.MediaBean
import
com.base.filerecoveryrecyclebin.bean.MediaTimeBean
import
com.base.filerecoveryrecyclebin.databinding.ActivityRepeatBinding
...
...
@@ -103,7 +102,7 @@ class RepeatActivity : BaseActivity<ActivityRepeatBinding>() {
}
binding
.
tvClean
.
setOnClickListener
{
showDeletePermanentlyDialog
{
if
(
showInter
AdSp
())
{
if
(
AdmobMaxHelper
.
showDelete
AdSp
())
{
AdmobMaxHelper
.
admobMaxShowInterstitialAd
(
this
,
isLoading
=
false
)
{
cleanFile
()
}
...
...
app/src/main/java/com/base/filerecoveryrecyclebin/activity/screenshot/ScreenShotActivity.kt
View file @
1c6c6646
...
...
@@ -9,7 +9,6 @@ import androidx.core.view.updatePadding
import
androidx.lifecycle.lifecycleScope
import
com.base.filerecoveryrecyclebin.adapter.ScreenShotAdapter
import
com.base.filerecoveryrecyclebin.ads.AdmobMaxHelper
import
com.base.filerecoveryrecyclebin.ads.admob.AdmobInterstitialUtils.showInterAdSp
import
com.base.filerecoveryrecyclebin.bean.ScreenPhotoBean
import
com.base.filerecoveryrecyclebin.bean.ScreenshotBean
import
com.base.filerecoveryrecyclebin.databinding.ActivityScreenShotBinding
...
...
@@ -122,7 +121,7 @@ class ScreenShotActivity : BaseActivity<ActivityScreenShotBinding>() {
binding
.
tvClean
.
setOnClickListener
{
showDeletePermanentlyDialog
{
if
(
showInter
AdSp
())
{
if
(
AdmobMaxHelper
.
showDelete
AdSp
())
{
AdmobMaxHelper
.
admobMaxShowInterstitialAd
(
this
,
isLoading
=
false
)
{
cleanFile
()
}
...
...
app/src/main/java/com/base/filerecoveryrecyclebin/ads/AdmobMaxHelper.kt
View file @
1c6c6646
...
...
@@ -32,6 +32,18 @@ object AdmobMaxHelper {
return
ss
==
1
}
fun
showBackInterAdSp
():
Boolean
{
val
isShowBackIntAd
=
AppPreferences
.
getInstance
().
getString
(
"isShowBackIntAd"
,
"0"
).
toInt
()
//1要看插屏 0不看
return
isShowBackIntAd
==
1
}
fun
showDeleteAdSp
():
Boolean
{
val
isDeleteInterAd
=
AppPreferences
.
getInstance
().
getString
(
"isDeleteInterAd"
,
"0"
).
toInt
()
//1要看插屏 0不看
return
isDeleteInterAd
==
1
}
//Begin
fun
initAdmobMaxAd
()
{
...
...
app/src/main/java/com/base/filerecoveryrecyclebin/ads/admob/AdmobInterstitialUtils.kt
View file @
1c6c6646
...
...
@@ -41,11 +41,6 @@ object AdmobInterstitialUtils {
return
System
.
currentTimeMillis
()
-
interLoadTime
>
1000
*
60
*
60
}
fun
showInterAdSp
():
Boolean
{
val
isDeleteInterAd
=
AppPreferences
.
getInstance
().
getString
(
"isDeleteInterAd"
,
"0"
).
toInt
()
//1要看插屏 0不看
return
isDeleteInterAd
==
1
}
fun
showInterstitialAd
(
activity
:
Activity
,
...
...
app/src/main/java/com/base/filerecoveryrecyclebin/view/DialogViews.kt
View file @
1c6c6646
...
...
@@ -19,7 +19,7 @@ import androidx.constraintlayout.widget.ConstraintLayout
import
androidx.lifecycle.LifecycleCoroutineScope
import
com.base.filerecoveryrecyclebin.R
import
com.base.filerecoveryrecyclebin.activity.junkclean.ScanJunkActivity
import
com.base.filerecoveryrecyclebin.ads.
admob.AdmobInterstitialUtils.show
InterAdSp
import
com.base.filerecoveryrecyclebin.ads.
AdmobMaxHelper.showBack
InterAdSp
import
com.base.filerecoveryrecyclebin.bean.ConstObject.SELECT_FILE_ALL
import
com.base.filerecoveryrecyclebin.bean.ConstObject.SELECT_FILE_AUDIO
import
com.base.filerecoveryrecyclebin.bean.ConstObject.SELECT_FILE_DOCUMENT
...
...
@@ -274,7 +274,7 @@ object DialogViews {
exitAction
:
(
showAd
:
Boolean
)
->
Unit
)
{
if
(!
mustShow
)
{
if
(!
showInterAdSp
())
{
if
(!
show
Back
InterAdSp
())
{
exitAction
.
invoke
(
false
)
return
}
...
...
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