diff --git a/OCH/mogo-och-common-module/src/main/java/com/mogo/och/common/module/wigets/ZhiView.kt b/OCH/mogo-och-common-module/src/main/java/com/mogo/och/common/module/wigets/ZhiView.kt index 188b742898..e3c3144fc9 100644 --- a/OCH/mogo-och-common-module/src/main/java/com/mogo/och/common/module/wigets/ZhiView.kt +++ b/OCH/mogo-och-common-module/src/main/java/com/mogo/och/common/module/wigets/ZhiView.kt @@ -35,7 +35,7 @@ class ZhiView @JvmOverloads constructor( const val TAG = "ZhiView" } - private var currentAnim = FrameAnimatorContainer(R.array.xiaozhi_normal, 24,this) + private var currentAnim = FrameAnimatorContainer(R.array.xiaozhi_normal, 12,this) @Volatile private var status = ZhiRecordWinUi.RecordStatus.STATUS_SILENCE diff --git a/OCH/taxi/passenger/src/main/java/com/mogo/och/taxi/passenger/ui/check/TaxiPassengerCheckView.kt b/OCH/taxi/passenger/src/main/java/com/mogo/och/taxi/passenger/ui/check/TaxiPassengerCheckView.kt index ba7274a282..a7f4aff444 100644 --- a/OCH/taxi/passenger/src/main/java/com/mogo/och/taxi/passenger/ui/check/TaxiPassengerCheckView.kt +++ b/OCH/taxi/passenger/src/main/java/com/mogo/och/taxi/passenger/ui/check/TaxiPassengerCheckView.kt @@ -11,12 +11,16 @@ import android.view.View import android.widget.RelativeLayout import android.widget.TextView import com.mogo.commons.voice.AIAssist +import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger.d import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant import com.mogo.eagle.core.utilcode.util.ToastUtils +import com.mogo.och.common.module.utils.FrameAnimatorContainer import com.mogo.och.common.module.voice.VoiceNotice import com.mogo.och.taxi.passenger.R import com.mogo.och.taxi.passenger.callback.ITaxiPassengerCommonValueCallback +import com.mogo.och.taxi.passenger.ui.arrived.ArrivedView +import kotlinx.android.synthetic.main.taxi_p_passenger_check_panel.view.iv_zhi_normal import kotlinx.android.synthetic.main.taxi_p_passenger_check_panel.view.tv_passenger_count import kotlinx.android.synthetic.main.taxi_p_passenger_check_panel.view.tv_passenger_end import kotlinx.android.synthetic.main.taxi_p_passenger_check_panel.view.tv_passenger_start @@ -60,6 +64,8 @@ class TaxiPassengerCheckView :RelativeLayout, View.OnClickListener { private val numSelect = arrayOfNulls(4) private val numSelectTextView = arrayOfNulls(4) + private var taxiPxiaozhiCheck: FrameAnimatorContainer?=null + private fun initView(context: Context) { d(SceneConstant.M_TAXI_P + TAG, "initView") LayoutInflater.from(context).inflate(R.layout.taxi_p_passenger_check_panel, this, true) @@ -68,6 +74,23 @@ class TaxiPassengerCheckView :RelativeLayout, View.OnClickListener { numSelectTextView[1] = tv_taxi_passenger_number_second numSelectTextView[2] = tv_taxi_passenger_number_third numSelectTextView[3] = tv_taxi_passenger_number_fourth + + taxiPxiaozhiCheck = FrameAnimatorContainer(R.array.xiaozhi_normal, 12,iv_zhi_normal) + taxiPxiaozhiCheck?.setOnAnimStopListener(object : FrameAnimatorContainer.OnAnimationStoppedListener{ + override fun AnimationStopped() { + CallerLogger.d(SceneConstant.M_TAXI_P + ArrivedView.TAG, "动画暂停") + } + }) + } + + override fun onAttachedToWindow() { + super.onAttachedToWindow() + taxiPxiaozhiCheck?.start() + } + + override fun onDetachedFromWindow() { + super.onDetachedFromWindow() + taxiPxiaozhiCheck?.stop() } private fun keyBoardLogic() { diff --git a/OCH/taxi/passenger/src/main/res/layout/taxi_p_passenger_check_panel.xml b/OCH/taxi/passenger/src/main/res/layout/taxi_p_passenger_check_panel.xml index 776b51c367..fe1331decf 100644 --- a/OCH/taxi/passenger/src/main/res/layout/taxi_p_passenger_check_panel.xml +++ b/OCH/taxi/passenger/src/main/res/layout/taxi_p_passenger_check_panel.xml @@ -303,13 +303,14 @@ + android:layout_width="@dimen/dp_360" + android:layout_height="@dimen/dp_360"/> diff --git a/OCH/taxi/unmanned-passenger/src/main/java/com/mogo/och/taxi/passenger/ui/check/TaxiPassengerCheckView.kt b/OCH/taxi/unmanned-passenger/src/main/java/com/mogo/och/taxi/passenger/ui/check/TaxiPassengerCheckView.kt index fd439578db..dad6f5f563 100644 --- a/OCH/taxi/unmanned-passenger/src/main/java/com/mogo/och/taxi/passenger/ui/check/TaxiPassengerCheckView.kt +++ b/OCH/taxi/unmanned-passenger/src/main/java/com/mogo/och/taxi/passenger/ui/check/TaxiPassengerCheckView.kt @@ -12,13 +12,17 @@ import android.widget.TextView import androidx.core.content.ContextCompat import androidx.lifecycle.ViewModelProvider import com.mogo.commons.voice.AIAssist +import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger.d import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant import com.mogo.eagle.core.utilcode.util.OverlayViewUtils import com.mogo.eagle.core.utilcode.util.ToastUtils +import com.mogo.och.common.module.utils.FrameAnimatorContainer import com.mogo.och.common.module.voice.VoiceNotice import com.mogo.och.taxi.passenger.R +import com.mogo.och.taxi.passenger.ui.arrived.ArrivedView import com.mogo.och.taxi.passenger.widget.WindowRelativeLayout +import kotlinx.android.synthetic.main.taxi_p_passenger_check_panel.view.iv_zhi_normal import kotlinx.android.synthetic.main.taxi_p_passenger_check_panel.view.tv_passenger_count import kotlinx.android.synthetic.main.taxi_p_passenger_check_panel.view.tv_passenger_end import kotlinx.android.synthetic.main.taxi_p_passenger_check_panel.view.tv_passenger_start @@ -61,6 +65,8 @@ class TaxiPassengerCheckView : WindowRelativeLayout, View.OnClickListener, private val numSelectTextView = arrayOfNulls(4) private lateinit var viewModel:ChekViewModel + private var taxiPxiaozhiCheck: FrameAnimatorContainer?=null + private fun initView(context: Context) { d(SceneConstant.M_TAXI_P + TAG, "initView") @@ -70,6 +76,13 @@ class TaxiPassengerCheckView : WindowRelativeLayout, View.OnClickListener, numSelectTextView[1] = tv_taxi_passenger_number_second numSelectTextView[2] = tv_taxi_passenger_number_third numSelectTextView[3] = tv_taxi_passenger_number_fourth + + taxiPxiaozhiCheck = FrameAnimatorContainer(R.array.xiaozhi_normal, 12,iv_zhi_normal) + taxiPxiaozhiCheck?.setOnAnimStopListener(object : FrameAnimatorContainer.OnAnimationStoppedListener{ + override fun AnimationStopped() { + CallerLogger.d(SceneConstant.M_TAXI_P + ArrivedView.TAG, "动画暂停") + } + }) } private fun keyBoardLogic() { @@ -129,6 +142,12 @@ class TaxiPassengerCheckView : WindowRelativeLayout, View.OnClickListener, super.onAttachedToWindow() viewModel = ViewModelProvider(this).get(ChekViewModel::class.java) viewModel.setStartAutopilotCallback(this) + taxiPxiaozhiCheck?.start() + } + + override fun onDetachedFromWindow() { + super.onDetachedFromWindow() + taxiPxiaozhiCheck?.stop() } private fun selectIndex(i: Int) { diff --git a/OCH/taxi/unmanned-passenger/src/main/java/com/mogo/och/taxi/passenger/ui/startautopilot/StartAutopilotView.kt b/OCH/taxi/unmanned-passenger/src/main/java/com/mogo/och/taxi/passenger/ui/startautopilot/StartAutopilotView.kt index f462d85284..732172250c 100644 --- a/OCH/taxi/unmanned-passenger/src/main/java/com/mogo/och/taxi/passenger/ui/startautopilot/StartAutopilotView.kt +++ b/OCH/taxi/unmanned-passenger/src/main/java/com/mogo/och/taxi/passenger/ui/startautopilot/StartAutopilotView.kt @@ -100,7 +100,7 @@ class StartAutopilotView : WindowRelativeLayout, StartAutopilotViewModel.StartAu CallerLogger.d(SceneConstant.M_TAXI_P + TAG, "可以启动自驾动画暂停") } }) - taxiPXiaozhiBelt = FrameAnimatorContainer(R.array.xiaozhi_belt, 24, iv_xiaozhi_belt) + taxiPXiaozhiBelt = FrameAnimatorContainer(R.array.xiaozhi_belt, 20, iv_xiaozhi_belt) taxiPXiaozhiBelt?.setOnAnimStopListener(object : FrameAnimatorContainer.OnAnimationStoppedListener { override fun AnimationStopped() { diff --git a/OCH/taxi/unmanned-passenger/src/main/res/layout/taxi_p_passenger_check_panel.xml b/OCH/taxi/unmanned-passenger/src/main/res/layout/taxi_p_passenger_check_panel.xml index 776b51c367..fe1331decf 100644 --- a/OCH/taxi/unmanned-passenger/src/main/res/layout/taxi_p_passenger_check_panel.xml +++ b/OCH/taxi/unmanned-passenger/src/main/res/layout/taxi_p_passenger_check_panel.xml @@ -303,13 +303,14 @@ + android:layout_width="@dimen/dp_360" + android:layout_height="@dimen/dp_360"/>