feat: play supplied audio on electronic photo completion
This commit is contained in:
@@ -47,6 +47,7 @@ class LocalAudioPlayService @Inject constructor(
|
||||
AppRoutes.PHOTO_SELECT to R.raw.upload_unpaid_result_page,
|
||||
AppRoutes.PRINTING to R.raw.printing_page,
|
||||
AppRoutes.PRINT_SUCCESS to R.raw.print_complete_page,
|
||||
ELECTRONIC_COMPLETION_AUDIO_KEY to R.raw.electronic_complete_page,
|
||||
// 特殊状态页面
|
||||
"face_recognition_recognizing" to R.raw.face_recognition_recognizing_page,
|
||||
"face_recognition_failed" to R.raw.face_recognition_failed_page,
|
||||
@@ -112,10 +113,6 @@ class LocalAudioPlayService @Inject constructor(
|
||||
|
||||
// 同一结果页根据入口选择播报,避免最近照片误播识别成功。
|
||||
val audioKey = localAudioKeyForRoute(route)
|
||||
if (audioKey == ELECTRONIC_COMPLETION_AUDIO_KEY) {
|
||||
stop()
|
||||
return
|
||||
}
|
||||
|
||||
val audioResId = ROUTE_TO_AUDIO_MAP[audioKey]
|
||||
if (audioResId == null) {
|
||||
|
||||
@@ -3,7 +3,7 @@ package com.yzx.kiosk.audio
|
||||
import com.yzx.kiosk.navigation.routes.AppRoutes
|
||||
import java.net.URLDecoder
|
||||
|
||||
internal const val ELECTRONIC_COMPLETION_AUDIO_KEY = "electronic_completion_silent"
|
||||
internal const val ELECTRONIC_COMPLETION_AUDIO_KEY = "electronic_completion"
|
||||
|
||||
internal const val RECENT_PHOTOS_AUDIO_KEY = "recent_photos_result"
|
||||
|
||||
|
||||
Binary file not shown.
Reference in New Issue
Block a user