[6.7.0][Feat]添加地图容器到Taxi布局中
This commit is contained in:
@@ -8,7 +8,6 @@ import android.os.Handler;
|
||||
import android.os.Looper;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewStub;
|
||||
import android.view.animation.LinearInterpolator;
|
||||
import android.widget.FrameLayout;
|
||||
import android.widget.ImageView;
|
||||
@@ -16,7 +15,6 @@ import android.widget.RelativeLayout;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.appcompat.widget.AppCompatImageView;
|
||||
import androidx.constraintlayout.widget.ConstraintLayout;
|
||||
import androidx.constraintlayout.widget.Group;
|
||||
import androidx.fragment.app.FragmentTransaction;
|
||||
@@ -29,8 +27,7 @@ import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotControlManager
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotStatusListenerManager;
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutopilotRecordListenerManager;
|
||||
import com.mogo.eagle.core.function.call.devatools.CallerDevaToolsManager;
|
||||
import com.mogo.eagle.core.function.view.MapBizView;
|
||||
import com.mogo.eagle.core.function.smp.view.SmallMapView;
|
||||
import com.mogo.eagle.core.function.hmi.map.MapContainerLayout;
|
||||
import com.mogo.eagle.core.function.view.MapRoamView;
|
||||
import com.mogo.eagle.core.utilcode.mogo.view.OnPreventFastClickListener;
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils;
|
||||
@@ -61,7 +58,6 @@ public abstract class BaseTaxiTabFragment<V extends IView, P extends Presenter<V
|
||||
protected TextView mDriverRole;
|
||||
protected FrameLayout flStationPanelContainer;
|
||||
private FrameLayout flNaviPanelContainer;
|
||||
private MapBizView mapBizView;
|
||||
private MapRoamView mapRoamView;
|
||||
private Group groupTestPanel;
|
||||
private FrameLayout mSpeedView;
|
||||
@@ -73,9 +69,8 @@ public abstract class BaseTaxiTabFragment<V extends IView, P extends Presenter<V
|
||||
protected TaxiAmapNaviFragment ochAmapNaviFragment = null;
|
||||
protected TaxiRottingNaviFragment taxiRottingNaviFragment = null;
|
||||
|
||||
protected SmallMapView smallMapView;
|
||||
protected AppCompatImageView acivShowGuid;
|
||||
|
||||
// protected AppCompatImageView acivShowGuid;
|
||||
private MapContainerLayout mapContainerLayout;
|
||||
private OverMapDialog overMapDialog;
|
||||
private final Handler mHandler = new Handler(Looper.getMainLooper());
|
||||
|
||||
@@ -86,7 +81,7 @@ public abstract class BaseTaxiTabFragment<V extends IView, P extends Presenter<V
|
||||
|
||||
@Override
|
||||
protected void initViews() {
|
||||
mapBizView = findViewById(R.id.mapBizView);
|
||||
mapContainerLayout = findViewById(R.id.mapContainerLayout);
|
||||
mapRoamView = findViewById(R.id.mapRoamView);
|
||||
groupTestPanel = findViewById(R.id.groupTestPanel);
|
||||
ctvAutopilotStatusRL = findViewById(R.id.module_mogo_och_autopilot_status);
|
||||
@@ -169,41 +164,37 @@ public abstract class BaseTaxiTabFragment<V extends IView, P extends Presenter<V
|
||||
showRottingToStationFragment(false);
|
||||
});
|
||||
|
||||
|
||||
smallMapView = findViewById(R.id.smallMapView);
|
||||
acivShowGuid = findViewById(R.id.aciv_show_guid);
|
||||
smallMapView.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
if(overMapDialog==null){
|
||||
overMapDialog = new OverMapDialog(getContext());
|
||||
}
|
||||
acivShowGuid.setVisibility(View.GONE);
|
||||
overMapDialog.showDialog();
|
||||
}
|
||||
});
|
||||
// smallMapView = findViewById(R.id.smallMapView);
|
||||
// acivShowGuid = findViewById(R.id.aciv_show_guid);
|
||||
// smallMapView.setOnClickListener(new View.OnClickListener() {
|
||||
// @Override
|
||||
// public void onClick(View v) {
|
||||
// if(overMapDialog==null){
|
||||
// overMapDialog = new OverMapDialog(getContext());
|
||||
// }
|
||||
// acivShowGuid.setVisibility(View.GONE);
|
||||
// overMapDialog.showDialog();
|
||||
// }
|
||||
// });
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void initViews(Bundle savedInstanceState) {
|
||||
super.initViews(savedInstanceState);
|
||||
mapBizView.onCreate(savedInstanceState);
|
||||
mapContainerLayout.onCreate(savedInstanceState);
|
||||
mapRoamView.onCreate(savedInstanceState);
|
||||
smallMapView.onCreateView(savedInstanceState);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onResume() {
|
||||
super.onResume();
|
||||
mapBizView.onResume();
|
||||
smallMapView.onResume();
|
||||
mapContainerLayout.onResume();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onPause() {
|
||||
super.onPause();
|
||||
mapBizView.onPause();
|
||||
smallMapView.onPause();
|
||||
mapContainerLayout.onPause();
|
||||
}
|
||||
|
||||
protected void onChangeOperationStatus() {
|
||||
@@ -213,24 +204,21 @@ public abstract class BaseTaxiTabFragment<V extends IView, P extends Presenter<V
|
||||
@Override
|
||||
public void onLowMemory() {
|
||||
super.onLowMemory();
|
||||
mapBizView.onLowMemory();
|
||||
mapContainerLayout.onLowMemory();
|
||||
mapRoamView.onLowMemory();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onSaveInstanceState(@NonNull Bundle outState) {
|
||||
super.onSaveInstanceState(outState);
|
||||
mapBizView.onSaveInstanceState(outState);
|
||||
mapContainerLayout.onSaveInstanceState(outState);
|
||||
mapRoamView.onSaveInstanceState(outState);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onDestroyView() {
|
||||
mapBizView.onDestroy();
|
||||
mapContainerLayout.onDestroy();
|
||||
mapRoamView.onDestroy();
|
||||
if(smallMapView != null){
|
||||
smallMapView.onDestroy();
|
||||
}
|
||||
if(overMapDialog!=null) {
|
||||
overMapDialog.hideDialog();
|
||||
overMapDialog.destory();
|
||||
@@ -242,7 +230,7 @@ public abstract class BaseTaxiTabFragment<V extends IView, P extends Presenter<V
|
||||
mDriverRole = null;
|
||||
flStationPanelContainer = null;
|
||||
flNaviPanelContainer = null;
|
||||
mapBizView = null;
|
||||
mapContainerLayout = null;
|
||||
mapRoamView = null;
|
||||
groupTestPanel = null;
|
||||
mSpeedView = null;
|
||||
@@ -251,7 +239,6 @@ public abstract class BaseTaxiTabFragment<V extends IView, P extends Presenter<V
|
||||
mCloseNaviIcon = null;
|
||||
ochAmapNaviFragment = null;
|
||||
taxiRottingNaviFragment = null;
|
||||
smallMapView = null;
|
||||
CallerAutopilotRecordListenerManager.INSTANCE.removeListener(TAG);
|
||||
}
|
||||
|
||||
@@ -483,11 +470,9 @@ public abstract class BaseTaxiTabFragment<V extends IView, P extends Presenter<V
|
||||
transaction.commitAllowingStateLoss();
|
||||
mCloseNaviIcon.setVisibility(View.VISIBLE);
|
||||
flNaviPanelContainer.setVisibility(View.VISIBLE);
|
||||
smallMapView.setVisibility(View.GONE);
|
||||
} else {
|
||||
mCloseNaviIcon.setVisibility(View.GONE);
|
||||
flNaviPanelContainer.setVisibility(View.INVISIBLE);
|
||||
smallMapView.setVisibility(View.VISIBLE);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -526,12 +511,10 @@ public abstract class BaseTaxiTabFragment<V extends IView, P extends Presenter<V
|
||||
transaction.commitAllowingStateLoss();
|
||||
mCloseNaviIcon.setVisibility(View.VISIBLE);
|
||||
flNaviPanelContainer.setVisibility(View.VISIBLE);
|
||||
smallMapView.setVisibility(View.GONE);
|
||||
} else {
|
||||
closeRouteViewIFHadeAdd();
|
||||
mCloseNaviIcon.setVisibility(View.GONE);
|
||||
flNaviPanelContainer.setVisibility(View.INVISIBLE);
|
||||
smallMapView.setVisibility(View.VISIBLE);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -539,9 +522,9 @@ public abstract class BaseTaxiTabFragment<V extends IView, P extends Presenter<V
|
||||
public abstract void startNaviToEndStation(boolean isShow);
|
||||
|
||||
public void setGuidShow() {
|
||||
acivShowGuid.setVisibility(View.VISIBLE);
|
||||
// acivShowGuid.setVisibility(View.VISIBLE);
|
||||
}
|
||||
public void setGuidHide(){
|
||||
acivShowGuid.setVisibility(View.GONE);
|
||||
// acivShowGuid.setVisibility(View.GONE);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -6,12 +6,6 @@
|
||||
android:layout_height="match_parent"
|
||||
android:layout_marginTop="@dimen/dp_72">
|
||||
|
||||
<com.mogo.eagle.core.function.view.MapBizView
|
||||
android:id="@+id/mapBizView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
app:isWeatherEnable="false" />
|
||||
|
||||
<com.mogo.eagle.core.function.hmi.ui.setting.ToggleDebugViewTrigger
|
||||
android:layout_width="@dimen/dp_400"
|
||||
android:layout_height="@dimen/dp_100"
|
||||
@@ -371,47 +365,44 @@
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent" />
|
||||
|
||||
<androidx.appcompat.widget.AppCompatImageView
|
||||
android:id="@+id/aciv_show_guid"
|
||||
android:layout_width="@dimen/dp_209"
|
||||
android:layout_height="@dimen/dp_91"
|
||||
android:layout_marginBottom="-32dp"
|
||||
android:src="@drawable/taxi_overmap_tag"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintBottom_toTopOf="@+id/smallMapView"
|
||||
app:layout_constraintEnd_toEndOf="@+id/smallMapView"
|
||||
app:layout_constraintStart_toStartOf="@+id/smallMapView" />
|
||||
<!-- <androidx.appcompat.widget.AppCompatImageView-->
|
||||
<!-- android:id="@+id/aciv_show_guid"-->
|
||||
<!-- android:layout_width="@dimen/dp_209"-->
|
||||
<!-- android:layout_height="@dimen/dp_91"-->
|
||||
<!-- android:layout_marginBottom="-32dp"-->
|
||||
<!-- android:src="@drawable/taxi_overmap_tag"-->
|
||||
<!-- android:visibility="gone"-->
|
||||
<!-- app:layout_constraintBottom_toTopOf="@+id/smallMapView"-->
|
||||
<!-- app:layout_constraintEnd_toEndOf="@+id/smallMapView"-->
|
||||
<!-- app:layout_constraintStart_toStartOf="@+id/smallMapView" />-->
|
||||
|
||||
<com.mogo.eagle.core.function.smp.view.SmallMapView
|
||||
android:id="@+id/smallMapView"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginRight="30dp"
|
||||
android:layout_marginBottom="30dp"
|
||||
android:visibility="visible"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent" />
|
||||
<!-- TODO:"挪到ExchangeChildLayout中去" -->
|
||||
<!-- <com.mogo.eagle.core.function.hmi.ui.viewport.VisualAngleToggleView-->
|
||||
<!-- android:id="@+id/visualAngleToggle"-->
|
||||
<!-- android:layout_width="wrap_content"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- app:layout_constraintEnd_toEndOf="parent"-->
|
||||
<!-- app:layout_constraintBottom_toTopOf="@+id/smallMapView"-->
|
||||
<!-- android:layout_marginEnd="@dimen/dp_50"-->
|
||||
<!-- android:layout_marginBottom="@dimen/dp_30"/>-->
|
||||
|
||||
<com.mogo.eagle.core.function.hmi.ui.viewport.VisualAngleToggleView
|
||||
android:id="@+id/visualAngleToggle"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintBottom_toTopOf="@+id/smallMapView"
|
||||
android:layout_marginEnd="@dimen/dp_50"
|
||||
android:layout_marginBottom="@dimen/dp_30"/>
|
||||
|
||||
<com.mogo.eagle.core.function.hmi.ui.mofang.MoFangStatusView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintTop_toTopOf="@+id/visualAngleToggle"
|
||||
app:layout_constraintEnd_toStartOf="@+id/visualAngleToggle"/>
|
||||
<!-- <com.mogo.eagle.core.function.hmi.ui.mofang.MoFangStatusView-->
|
||||
<!-- android:layout_width="wrap_content"-->
|
||||
<!-- android:layout_height="wrap_content"-->
|
||||
<!-- app:layout_constraintTop_toTopOf="@+id/visualAngleToggle"-->
|
||||
<!-- app:layout_constraintEnd_toStartOf="@+id/visualAngleToggle"/>-->
|
||||
|
||||
<com.mogo.och.common.module.wigets.LoadingMapStatusView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" />
|
||||
|
||||
|
||||
<com.mogo.eagle.core.function.hmi.map.MapContainerLayout
|
||||
android:id="@+id/mapContainerLayout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
/>
|
||||
|
||||
<com.mogo.eagle.core.function.hmi.bone.BoneContainerView
|
||||
android:id="@+id/boneContainerView"
|
||||
|
||||
Reference in New Issue
Block a user