Commit 0e780a9e authored by wanglei's avatar wanglei

...

parent 747216ec
...@@ -13,6 +13,7 @@ import com.test.easy.easycleanerjunk.fcm.CloseNotificationReceiver ...@@ -13,6 +13,7 @@ import com.test.easy.easycleanerjunk.fcm.CloseNotificationReceiver
import com.test.easy.easycleanerjunk.fcm.NotificationUtil import com.test.easy.easycleanerjunk.fcm.NotificationUtil
import com.test.easy.easycleanerjunk.helps.BaseActivity import com.test.easy.easycleanerjunk.helps.BaseActivity
import com.test.easy.easycleanerjunk.helps.ConfigHelper import com.test.easy.easycleanerjunk.helps.ConfigHelper
import com.test.easy.easycleanerjunk.helps.ConfigHelper.remainNotification
import com.test.easy.easycleanerjunk.helps.EventUtils import com.test.easy.easycleanerjunk.helps.EventUtils
import com.test.easy.easycleanerjunk.helps.ads.AdmobUtils import com.test.easy.easycleanerjunk.helps.ads.AdmobUtils
import com.test.easy.easycleanerjunk.service.PermanentNotificationService import com.test.easy.easycleanerjunk.service.PermanentNotificationService
...@@ -82,6 +83,7 @@ class NewSplashActivity : BaseActivity<ActivityLayoutSplashBinding>(), ...@@ -82,6 +83,7 @@ class NewSplashActivity : BaseActivity<ActivityLayoutSplashBinding>(),
} }
private fun startNotification() { private fun startNotification() {
if (remainNotification) {
val intent = Intent(this, PermanentNotificationService::class.java) val intent = Intent(this, PermanentNotificationService::class.java)
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) { if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) {
startForegroundService(intent) startForegroundService(intent)
...@@ -89,6 +91,7 @@ class NewSplashActivity : BaseActivity<ActivityLayoutSplashBinding>(), ...@@ -89,6 +91,7 @@ class NewSplashActivity : BaseActivity<ActivityLayoutSplashBinding>(),
startService(intent) startService(intent)
} }
} }
}
override fun onProgressMax() { override fun onProgressMax() {
Handler().postDelayed({ Handler().postDelayed({
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment