[5.2.8]
[shuttle_p] [status bar]
This commit is contained in:
@@ -22,22 +22,13 @@ class ScannerStateView @JvmOverloads constructor(
|
||||
|
||||
override fun stateChange(newBindValue: BindStatus, newOpentValue: OpenStatus) {
|
||||
CallerLogger.d(SceneConstant.M_BUS_P + TAG, "newBindValue = $newBindValue newOpentValue = $newOpentValue")
|
||||
when (newBindValue) {
|
||||
BindStatus.BIND_SUCCEED -> {
|
||||
// 绑定成功
|
||||
when (newOpentValue) {
|
||||
OpenStatus.Open -> {
|
||||
//成功打开
|
||||
visibility = View.GONE
|
||||
}
|
||||
OpenStatus.Unopen -> {
|
||||
// 打开失败
|
||||
setImageResource(R.drawable.driver_connect_statis)
|
||||
}
|
||||
}
|
||||
when (newOpentValue) {
|
||||
OpenStatus.Open -> {
|
||||
//成功打开
|
||||
visibility = View.GONE
|
||||
}
|
||||
else ->{
|
||||
// 绑定失败
|
||||
OpenStatus.Unopen -> {
|
||||
// 打开失败
|
||||
setImageResource(R.drawable.driver_connect_statis)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,6 +3,9 @@ package com.mogo.och.shuttle.passenger.provider;
|
||||
import android.content.Context;
|
||||
import android.view.View;
|
||||
|
||||
import com.mogo.eagle.core.data.config.FunctionBuildConfig;
|
||||
import com.mogo.eagle.core.utilcode.mogo.AppIdentityModeUtils;
|
||||
import com.mogo.och.shuttle.passenger.ui.BusPStatusBarView;
|
||||
import com.mogo.och.shuttle.passenger.ui.widget.M2StatusBarView;
|
||||
import androidx.annotation.NonNull;
|
||||
|
||||
@@ -17,13 +20,16 @@ import com.mogo.eagle.core.function.api.hmi.view.IStatusViewLayout;
|
||||
* 根据优先级控制显示 window view.
|
||||
*/
|
||||
@Route( path = MogoServicePaths.PATH_STATUS_VIEW_MANAGER )
|
||||
public class M2StatusViewManager implements IStatusViewLayout {
|
||||
|
||||
|
||||
public class StatusViewManager implements IStatusViewLayout {
|
||||
@NonNull
|
||||
@Override
|
||||
public View getStatusView(Context context) {
|
||||
return new M2StatusBarView(context);
|
||||
if (AppIdentityModeUtils.isM2(FunctionBuildConfig.appIdentityMode)) {
|
||||
return new M2StatusBarView(context);
|
||||
} else if (AppIdentityModeUtils.isJL(FunctionBuildConfig.appIdentityMode)) {
|
||||
return new BusPStatusBarView(context);
|
||||
}
|
||||
return new BusPStatusBarView(context);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -1,33 +0,0 @@
|
||||
package com.mogo.och.shuttle.passenger.provider;
|
||||
|
||||
import android.content.Context;
|
||||
import android.view.View;
|
||||
|
||||
import com.mogo.och.shuttle.passenger.ui.BusPStatusBarView;
|
||||
import androidx.annotation.NonNull;
|
||||
|
||||
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||
import com.mogo.eagle.core.data.constants.MogoServicePaths;
|
||||
import com.mogo.eagle.core.function.api.hmi.view.IStatusViewLayout;
|
||||
|
||||
/**
|
||||
* @author congtaowang
|
||||
* @since 2020-01-06
|
||||
* <p>
|
||||
* 根据优先级控制显示 window view.
|
||||
*/
|
||||
@Route( path = MogoServicePaths.PATH_STATUS_VIEW_MANAGER )
|
||||
public class B1StatusViewManager implements IStatusViewLayout {
|
||||
|
||||
|
||||
@NonNull
|
||||
@Override
|
||||
public View getStatusView(Context context) {
|
||||
return new BusPStatusBarView(context);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void init(Context context) {
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user