parent
328b62e757
commit
8ebaad0144
|
|
@ -78,7 +78,6 @@ fun HomeScreen(
|
|||
val TAG = "Rabbit_HomeScreen"
|
||||
val context = LocalContext.current
|
||||
val scope: CoroutineScope = rememberCoroutineScope()
|
||||
// val progressPair = mutableStateMapOf<String, Float>()
|
||||
val progressPair = remember { mutableStateMapOf<String, Float>() }
|
||||
|
||||
// 获取当前路由状态
|
||||
|
|
@ -217,19 +216,19 @@ fun HomeScreen(
|
|||
UniMpUpdate.DOWNLOAD_START -> {
|
||||
//资源开始下载
|
||||
progressPair.apply { put(uniMpId, 0f) }
|
||||
Log.i("HomeScreen", "DOWNLOAD_START")
|
||||
Log.i(TAG, "DOWNLOAD_START")
|
||||
}
|
||||
|
||||
UniMpUpdate.DOWNLOAD_FINISH -> {
|
||||
//资源下载完成
|
||||
progressPair.apply { put(uniMpId, 1f) }
|
||||
Log.i("HomeScreen", "DOWNLOAD_FINISH")
|
||||
Log.i(TAG, "DOWNLOAD_FINISH")
|
||||
}
|
||||
|
||||
UniMpUpdate.DOWNLOAD_FAIL -> {
|
||||
//资源下载失败
|
||||
progressPair.apply { put(uniMpId, -1f) }
|
||||
Log.i("HomeScreen", "DOWNLOAD_FAIL")
|
||||
Log.i(TAG, "DOWNLOAD_FAIL")
|
||||
}
|
||||
|
||||
else -> {
|
||||
|
|
@ -242,7 +241,7 @@ fun HomeScreen(
|
|||
)
|
||||
}
|
||||
Log.i(
|
||||
"HomeScreen",
|
||||
TAG,
|
||||
"DOWNLOAD_PROGRESS:$progress"
|
||||
)
|
||||
}
|
||||
|
|
@ -347,19 +346,19 @@ fun HomeScreen(
|
|||
UniMpUpdate.DOWNLOAD_START -> {
|
||||
//资源开始下载
|
||||
progressPair.apply { put(uniMpId, 0f) }
|
||||
Log.i("HomeScreen", "DOWNLOAD_START")
|
||||
Log.i(TAG, "DOWNLOAD_START")
|
||||
}
|
||||
|
||||
UniMpUpdate.DOWNLOAD_FINISH -> {
|
||||
//资源下载完成
|
||||
progressPair.apply { put(uniMpId, 1f) }
|
||||
Log.i("HomeScreen", "DOWNLOAD_FINISH")
|
||||
Log.i(TAG, "DOWNLOAD_FINISH")
|
||||
}
|
||||
|
||||
UniMpUpdate.DOWNLOAD_FAIL -> {
|
||||
//资源下载失败
|
||||
progressPair.apply { put(uniMpId, -1f) }
|
||||
Log.i("HomeScreen", "DOWNLOAD_FAIL")
|
||||
Log.i(TAG, "DOWNLOAD_FAIL")
|
||||
}
|
||||
|
||||
else -> {
|
||||
|
|
@ -372,7 +371,7 @@ fun HomeScreen(
|
|||
)
|
||||
}
|
||||
Log.i(
|
||||
"HomeScreen",
|
||||
TAG,
|
||||
"DOWNLOAD_PROGRESS:$progress"
|
||||
)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -363,8 +363,8 @@ object UniAppUtils {
|
|||
val stringBuilder = StringBuilder()
|
||||
stringBuilder.append("-------------> 📤 header start<-------------\n")
|
||||
stringBuilder.append("│ x-token = ${PreferenceUtil.getXToken()}\n")
|
||||
stringBuilder.append("│ x-version = android\n")
|
||||
stringBuilder.append("│ x-platform = ${getAppVersionName()}\n")
|
||||
stringBuilder.append("│ x-version = ${getAppVersionName()}\n")
|
||||
stringBuilder.append("│ x-platform = android\n")
|
||||
stringBuilder.append("│ x-device-id = ${DeviceIdentifier.getAndroidID(applicationContext)}\n")
|
||||
stringBuilder.append("│ x-mobile-brand = ${android.os.Build.BRAND}\n")
|
||||
stringBuilder.append("│ x-mobile-model = ${android.os.Build.MODEL}\n")
|
||||
|
|
@ -374,6 +374,7 @@ object UniAppUtils {
|
|||
stringBuilder.append("│ host = ${Constants.RELEASE_BASE_URL}\n")
|
||||
stringBuilder.append("│ decrypt = ${Constants.AESDecrypt}\n")
|
||||
stringBuilder.append("│ decrypt = ${Constants.Signature}\n")
|
||||
stringBuilder.append("│ isCombo = ok\n")
|
||||
stringBuilder.append("-------------> header end <-------------")
|
||||
Log.i("UniAppUtils", stringBuilder.toString())
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue