This commit is contained in:
lixiaopeng
2021-05-31 14:47:35 +08:00
parent 22b95521ce
commit 117e7b120c
10 changed files with 43 additions and 8 deletions

View File

@@ -1104,8 +1104,36 @@ public class EntranceFragment extends MvpFragment<EntranceView, EntrancePresente
});
}
private boolean mLastStatusIsVr = false;
@Override
public void onMapModeChanged(EnumMapUI ui) {
Log.d("liyz", "fragment onMapModeChanged -----> ");
if (DebugConfig.getCarMachineType() != DebugConfig.CAR_MACHINE_TYPE_LENOVO ) {
if ( ui == EnumMapUI.Type_VR ) {
Log.d("liyz", "onMapModeChanged mLastStatusIsVr = " + mLastStatusIsVr + "--ui = " +ui);
if ( !mLastStatusIsVr ) {
MogoApisHandler.getInstance().getApis().getStatusManagerApi().setVrMode( TAG, true );
MapCenterPointStrategy.resetByChangeMode();
// MapMarkerManager.getInstance().redrawMarkerByStyleChanged();
if (DebugConfig.getCarMachineType() != DebugConfig.CAR_MACHINE_TYPE_LENOVO ) {
AIAssist.getInstance( getContext() ).speakTTSVoice( "已开启鹰眼模式" );
}
mLastStatusIsVr = true;
}
} else {
if ( mLastStatusIsVr ) {
mLastStatusIsVr = false;
MogoApisHandler.getInstance().getApis().getStatusManagerApi().setVrMode( TAG, false );
MapCenterPointStrategy.resetByChangeMode();
// MapMarkerManager.getInstance().redrawMarkerByStyleChanged();
if (DebugConfig.getCarMachineType() != DebugConfig.CAR_MACHINE_TYPE_LENOVO ) {
AIAssist.getInstance( getContext() ).speakTTSVoice( "已退出鹰眼模式" );
}
}
}
}
if (mCameraMode == null) {
return;
}
@@ -1117,6 +1145,7 @@ public class EntranceFragment extends MvpFragment<EntranceView, EntrancePresente
// } else if( ui == EnumMapUI.NorthUP_2D ){
// mMove2CurrentLocation.setImageResource( R.drawable.icon_car_up );
// }
}
@Override