Commit fa93ed46 authored by wanglei's avatar wanglei

..

parent 6f15b37f
......@@ -75,10 +75,12 @@ class FileRecoveryActivity : BaseActivity<ActivityFileRecoveryBinding>() {
SCAN_PHOTOS -> {
var size = 0
folderBean?.recoveryList?.forEach {
val bitmap = BitmapFactory.decodeFile(it.path)
if (bitmap.height < 256 || bitmap.width < 256) {
size++
it.isThumbnails = true
runCatching {
val bitmap = BitmapFactory.decodeFile(it.path)
if (bitmap.height < 256 || bitmap.width < 256) {
size++
it.isThumbnails = true
}
}
}
binding.tvThumbnails.text = "Hide thumbnails (${size})"
......
......@@ -7,6 +7,9 @@ import com.base.datarecovery.fcm.ScreenStatusReceiver
import com.base.datarecovery.help.BaseApplication
import org.json.JSONObject
/**
* call before agree
*/
object InstallHelps {
fun init() {
val referrerClient = InstallReferrerClient.newBuilder(BaseApplication.context).build()
......@@ -24,12 +27,12 @@ object InstallHelps {
obj.put("instantExperienceLaunched", installInfo.toString())
EventUtils.event("install_referrer", ext = obj, isSingleEvent = true)
if (listOf("gclid", "facebook","instagram").all { !installInfo.contains(it, true) }) {
//自然用户
AppPreferences.getInstance().put("install_source","origin")
}else{
if (listOf("gclid", "facebook", "instagram").all { !installInfo.contains(it, true) }) {
//自然用户
AppPreferences.getInstance().put("install_source", "origin")
} else {
//渠道用户
AppPreferences.getInstance().put("install_source","channel")
AppPreferences.getInstance().put("install_source", "channel")
}
NewComUtils.requestCfg {
......@@ -38,7 +41,8 @@ object InstallHelps {
RecoveryTimerManager.getInstance().stopTaskTimer()
} else {
val timerDelay: Int = AppPreferences.getInstance().getString("timerDelay", "1").toIntOrNull() ?: 1
val timerInterval: Int = AppPreferences.getInstance().getString("timerInterval", "7").toIntOrNull() ?: 7
val timerInterval: Int =
AppPreferences.getInstance().getString("timerInterval", "7").toIntOrNull() ?: 7
if (!RecoveryTimerManager.getInstance().isTaskTimerActive) {
RecoveryTimerManager.getInstance().scheduleTask(
(timerDelay * 60 * 1000).toLong(),
......
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