[6.7.0][启自驾指引] 优化代码逻辑

This commit is contained in:
renwj
2024-10-24 11:02:07 +08:00
parent adbd022654
commit 46b2fbb594

View File

@@ -233,17 +233,19 @@ object StatusManager {
}
}?.forEachIndexed { index, status ->
val shl = 1 shl index
xor = if (status is RouteDownloadStatus) {
if (status.state == RouteStart) {
if (status.isException()) {
xor = if (status is RouteDownloadStatus) {
if (status.state == RouteStart) {
xor or shl
} else {
xor or (shl shl 1)
}
} else {
if (status is OtherErrorStatus) {
CallerDevaToolsManager.getExtra().putString(R.id.autopilot_start_error.toString(), status.reason?.getUnableLaunchReason())
}
xor or shl
} else {
xor or (shl shl 1)
}
} else {
if (status is OtherErrorStatus) {
CallerDevaToolsManager.getExtra().putString(R.id.autopilot_start_error.toString(), status.reason?.getUnableLaunchReason())
}
xor or shl
}
}
return xor