Merge branch 'dev2_aiSdk' into qa_och_taxi2
# Conflicts: # libraries/map-custom/build.gradle
15
.idea/codeStyles/Project.xml
generated
@@ -1,13 +1,11 @@
|
||||
<component name="ProjectCodeStyleConfiguration">
|
||||
<code_scheme name="Project" version="173">
|
||||
<option name="AUTODETECT_INDENTS" value="false" />
|
||||
<JavaCodeStyleSettings>
|
||||
<option name="FIELD_NAME_PREFIX" value="m" />
|
||||
</JavaCodeStyleSettings>
|
||||
<JetCodeStyleSettings>
|
||||
<option name="PACKAGES_TO_USE_STAR_IMPORTS">
|
||||
<value>
|
||||
<package name="java.util" withSubpackages="false" static="false" />
|
||||
<package name="kotlinx.android.synthetic" withSubpackages="true" static="false" />
|
||||
<package name="io.ktor" withSubpackages="true" static="false" />
|
||||
</value>
|
||||
</option>
|
||||
<option name="CODE_STYLE_DEFAULTS" value="KOTLIN_OFFICIAL" />
|
||||
</JetCodeStyleSettings>
|
||||
<codeStyleSettings language="XML">
|
||||
<indentOptions>
|
||||
@@ -121,5 +119,8 @@
|
||||
</rules>
|
||||
</arrangement>
|
||||
</codeStyleSettings>
|
||||
<codeStyleSettings language="kotlin">
|
||||
<option name="CODE_STYLE_DEFAULTS" value="KOTLIN_OFFICIAL" />
|
||||
</codeStyleSettings>
|
||||
</code_scheme>
|
||||
</component>
|
||||
3
.idea/gradle.xml
generated
@@ -25,8 +25,6 @@
|
||||
<option value="$PROJECT_DIR$/foudations/httpdns-tencent" />
|
||||
<option value="$PROJECT_DIR$/foudations/mogo-aicloud-services-apk" />
|
||||
<option value="$PROJECT_DIR$/foudations/mogo-aicloud-services-sdk" />
|
||||
<option value="$PROJECT_DIR$/foudations/mogo-base-services-apk" />
|
||||
<option value="$PROJECT_DIR$/foudations/mogo-base-services-sdk" />
|
||||
<option value="$PROJECT_DIR$/foudations/mogo-base-websocket-sdk" />
|
||||
<option value="$PROJECT_DIR$/foudations/mogo-commons" />
|
||||
<option value="$PROJECT_DIR$/foudations/mogo-utils" />
|
||||
@@ -82,6 +80,7 @@
|
||||
<option value="$PROJECT_DIR$/test/crashreport" />
|
||||
<option value="$PROJECT_DIR$/test/crashreport-bugly" />
|
||||
<option value="$PROJECT_DIR$/test/crashreport-noop" />
|
||||
<option value="$PROJECT_DIR$/test/crashreport-upgrade" />
|
||||
<option value="$PROJECT_DIR$/tts" />
|
||||
<option value="$PROJECT_DIR$/tts/tts-base" />
|
||||
<option value="$PROJECT_DIR$/tts/tts-di" />
|
||||
|
||||
@@ -59,18 +59,18 @@ public class OchBusStationAdapter extends RecyclerView.Adapter<OchBusStationAdap
|
||||
if (currentStation == 0) {
|
||||
// 在起始点
|
||||
holder.tvStationName.setTextColor(context.getResources().getColor(R.color.module_mogo_och_bus_arrived_station_name_text_color));
|
||||
holder.ivIcon.setImageResource(R.drawable.module_mogo_och_bus_icon_arrived_station);
|
||||
holder.ivIcon.setImageResource(R.drawable.module_mogo_och_icon_arrived_station);
|
||||
holder.vDashBottom.setColor(context.getResources().getColor(R.color.module_mogo_och_bus_not_arrive_dash_color));
|
||||
} else {
|
||||
holder.tvStationName.setTextColor(context.getResources().getColor(R.color.module_mogo_och_bus_current_station_name_text_color));
|
||||
holder.ivIcon.setImageResource(R.drawable.module_mogo_och_bus_icon_arriving_station);
|
||||
holder.ivIcon.setImageResource(R.drawable.module_mogo_och_icon_arriving_station);
|
||||
holder.vDashTop.setGradient(context.getResources().getColor(R.color.module_mogo_och_bus_arriving_start_dash_color), context.getResources().getColor(R.color.module_mogo_och_bus_arriving_end_dash_color));
|
||||
holder.vDashBottom.setColor(context.getResources().getColor(R.color.module_mogo_och_bus_not_arrive_dash_color));
|
||||
}
|
||||
} else if (position < currentStation) {
|
||||
// 驶过
|
||||
holder.tvStationName.setTextColor(context.getResources().getColor(R.color.module_mogo_och_bus_arrived_station_name_text_color));
|
||||
holder.ivIcon.setImageResource(R.drawable.module_mogo_och_bus_icon_arrived_station);
|
||||
holder.ivIcon.setImageResource(R.drawable.module_mogo_och_icon_arrived_station);
|
||||
if (position == currentStation - 1) {
|
||||
holder.vDashBottom.setGradient(context.getResources().getColor(R.color.module_mogo_och_bus_leaving_start_dash_color), context.getResources().getColor(R.color.module_mogo_och_bus_leaving_end_dash_color));
|
||||
holder.vDashTop.setColor(context.getResources().getColor(R.color.module_mogo_och_bus_arrived_dash_color));
|
||||
|
||||
@@ -6,6 +6,7 @@ import android.widget.TextView;
|
||||
import androidx.annotation.NonNull;
|
||||
|
||||
import com.mogo.commons.debug.DebugConfig;
|
||||
import com.mogo.commons.voice.AIAssist;
|
||||
import com.mogo.module.common.MogoApisHandler;
|
||||
import com.mogo.och.BaseOchFragment;
|
||||
import com.mogo.och.bus.R;
|
||||
@@ -158,9 +159,9 @@ public class OchBusFragment extends BaseOchFragment< OchBusFragment, OchBusPrese
|
||||
if ( isArriveEndStation ) {
|
||||
showSlidePanle( "单程结束" );
|
||||
} else if ( isArriveAtStartStation ) {
|
||||
showSlidePanle( "滑动出车" );
|
||||
showSlidePanle( "滑动出发" );
|
||||
} else if ( isArriveAtStation ) {
|
||||
showSlidePanle( "准备出发" );
|
||||
showSlidePanle( "滑动出发" );
|
||||
}
|
||||
|
||||
mCurrentStationName.setText( currentStationName );
|
||||
@@ -220,10 +221,11 @@ public class OchBusFragment extends BaseOchFragment< OchBusFragment, OchBusPrese
|
||||
isOperationStatus = launch;
|
||||
if ( launch ) {
|
||||
tvOperationStatus.setText( "收车" );
|
||||
showSlidePanle("准备出发");
|
||||
showSlidePanle("滑动出发");
|
||||
showPanel();
|
||||
} else {
|
||||
tvOperationStatus.setText( "出车" );
|
||||
AIAssist.getInstance(getContext()).speakTTSVoice("已收车");
|
||||
tvOperationStatus.setText("出车");
|
||||
hideSlidePanel();
|
||||
hidPanel();
|
||||
}
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="@dimen/module_och_bus_panel_width"
|
||||
android:layout_height="@dimen/module_och_bus_panel_height"
|
||||
android:layout_width="@dimen/module_mogo_och_autopilot_order_bg_width"
|
||||
android:layout_height="@dimen/module_mogo_och_autopilot_order_bg_height"
|
||||
android:background="@drawable/module_och_bus_panel_bkg"
|
||||
android:orientation="vertical">
|
||||
|
||||
@@ -12,16 +12,16 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="right"
|
||||
android:layout_marginTop="16px"
|
||||
android:layout_marginRight="16px"
|
||||
android:layout_marginTop="@dimen/module_mogo_och_autopilot_order_tag_m_t"
|
||||
android:layout_marginRight="@dimen/module_mogo_och_autopilot_order_tag_m_r"
|
||||
android:background="@drawable/module_och_bus_panel_anchor_bkg"
|
||||
android:paddingLeft="8px"
|
||||
android:paddingTop="1px"
|
||||
android:paddingRight="8px"
|
||||
android:paddingBottom="1px"
|
||||
android:paddingLeft="@dimen/module_mogo_och_autopilot_order_tag_p_r"
|
||||
android:paddingTop="2px"
|
||||
android:paddingRight="@dimen/module_mogo_och_autopilot_order_tag_p_r"
|
||||
android:paddingBottom="2px"
|
||||
android:text="小巴车"
|
||||
android:textColor="#FFF"
|
||||
android:textSize="16px"
|
||||
android:textSize="@dimen/module_mogo_och_autopilot_order_tag_height"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
@@ -40,7 +40,7 @@
|
||||
android:layout_marginLeft="14px"
|
||||
android:text="当前站点:"
|
||||
android:textColor="#8E9DD4"
|
||||
android:textSize="20px"
|
||||
android:textSize="@dimen/module_och_bus_order_start_station_anchor_textSize"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintLeft_toRightOf="@+id/greenDot"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
@@ -50,8 +50,9 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="6px"
|
||||
android:text="--"
|
||||
android:textColor="#FFF"
|
||||
android:textSize="26px"
|
||||
android:textSize="@dimen/module_mogo_och_bus_station_name_text_size"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/module_och_bus_current_station_anchor"
|
||||
app:layout_constraintTop_toBottomOf="@+id/module_och_bus_current_station_anchor"
|
||||
@@ -63,7 +64,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:text="始"
|
||||
android:textColor="#8E9DD4"
|
||||
android:textSize="20px"
|
||||
android:textSize="@dimen/module_mogo_och_bus_station_notice_text_size"
|
||||
android:textStyle="bold"
|
||||
android:visibility="invisible"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/module_och_bus_current_station"
|
||||
@@ -75,10 +76,10 @@
|
||||
android:id="@+id/module_och_bus_next_station_anchor"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="27px"
|
||||
android:layout_marginTop="@dimen/module_och_bus_order_distance_anchor_marginTop"
|
||||
android:text="下一站:"
|
||||
android:textColor="#8E9DD4"
|
||||
android:textSize="20px"
|
||||
android:textSize="@dimen/module_och_bus_order_start_station_anchor_textSize"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/module_och_bus_current_station"
|
||||
app:layout_constraintTop_toBottomOf="@+id/module_och_bus_current_station" />
|
||||
@@ -87,8 +88,9 @@
|
||||
android:id="@+id/module_och_bus_order_end_station"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="--"
|
||||
android:textColor="#FFF"
|
||||
android:textSize="@dimen/module_och_bus_order_start_station_textSize"
|
||||
android:textSize="@dimen/module_mogo_och_bus_station_name_text_size"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/module_och_bus_next_station_anchor"
|
||||
app:layout_constraintTop_toBottomOf="@+id/module_och_bus_next_station_anchor"
|
||||
@@ -100,7 +102,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:text="终"
|
||||
android:textColor="#8E9DD4"
|
||||
android:textSize="20px"
|
||||
android:textSize="@dimen/module_mogo_och_bus_station_notice_text_size"
|
||||
android:textStyle="bold"
|
||||
android:visibility="invisible"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/module_och_bus_order_end_station"
|
||||
@@ -113,7 +115,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="14px"
|
||||
android:src="@drawable/module_mogo_och_bus_icon_arrived_station"
|
||||
android:src="@drawable/module_mogo_och_icon_arrived_station"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/module_och_bus_current_station"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/module_och_bus_current_station" />
|
||||
@@ -121,23 +123,23 @@
|
||||
<ImageView
|
||||
android:id="@+id/dotLine"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/module_och_bus_dot_line"
|
||||
android:layout_height="0dp"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/module_och_dot_line"
|
||||
app:layout_constraintBottom_toTopOf="@+id/blueDot"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/greenDot"
|
||||
app:layout_constraintRight_toRightOf="@+id/greenDot"
|
||||
app:layout_constraintTop_toBottomOf="@+id/greenDot" />
|
||||
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/blueDot"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/module_mogo_och_bus_icon_arriving_station"
|
||||
android:src="@drawable/module_mogo_och_icon_arriving_station"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/module_och_bus_order_end_station"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/greenDot"
|
||||
app:layout_constraintTop_toTopOf="@+id/module_och_bus_order_end_station" />
|
||||
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
</LinearLayout>
|
||||
@@ -26,7 +26,7 @@
|
||||
android:layout_width="20px"
|
||||
android:layout_height="20px"
|
||||
android:scaleType="center"
|
||||
android:src="@drawable/module_mogo_och_bus_icon_arrived_station"
|
||||
android:src="@drawable/module_mogo_och_icon_arrived_station"
|
||||
app:layout_constraintBottom_toBottomOf="@id/module_mogo_och_bus_station_name"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintVertical_bias="0.4"
|
||||
|
||||
@@ -0,0 +1,63 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<!-- 本套资源适配分体机xhdpi -->
|
||||
<dimen name="module_mogo_och_bus_station_panel_width">300px</dimen>
|
||||
<dimen name="module_mogo_och_bus_station_panel_height">348px</dimen>
|
||||
<dimen name="module_mogo_och_bus_two_station_panel_height">211px</dimen>
|
||||
<dimen name="module_mogo_och_bus_three_station_panel_height">276px</dimen>
|
||||
|
||||
|
||||
<dimen name="module_mogo_och_bus_station_list_height">220px</dimen>
|
||||
<dimen name="module_mogo_och_bus_two_station_list_height">98px</dimen>
|
||||
<dimen name="module_mogo_och_bus_three_station_list_height">159px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_bus_current_station_name_text_size">32px</dimen>
|
||||
<dimen name="module_mogo_och_bus_current_station_notice_text_size">20px</dimen>
|
||||
<dimen name="module_mogo_och_bus_station_name_text_size">42px</dimen>
|
||||
<dimen name="module_mogo_och_bus_station_notice_text_size">32px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_bus_station_name_margin_left">15px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_bus_station_panel_padding_top">20px</dimen>
|
||||
<dimen name="module_mogo_och_bus_station_panel_padding_left">36px</dimen>
|
||||
<dimen name="module_mogo_och_bus_station_panel_padding_bottom">28px</dimen>
|
||||
<dimen name="module_mogo_och_bus_station_panel_padding_right">36px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_bus_station_panel_guide_offset_left">3px</dimen>
|
||||
<dimen name="module_mogo_och_bus_station_panel_guide_offset_right">3px</dimen>
|
||||
<dimen name="module_mogo_och_bus_station_panel_guide_offset_top">17px</dimen>
|
||||
<dimen name="module_mogo_och_bus_station_panel_guide_offset_bottom">17px</dimen>
|
||||
|
||||
|
||||
<dimen name="module_och_bus_panel_width">300px</dimen>
|
||||
<dimen name="module_och_bus_panel_height">270px</dimen>
|
||||
<dimen name="module_och_bus_order_status_marginLeft">30px</dimen>
|
||||
<dimen name="module_och_bus_order_status_marginTop">24px</dimen>
|
||||
<dimen name="module_och_bus_order_status_textSize">24px</dimen>
|
||||
<dimen name="module_och_bus_order_status_divider_height">1px</dimen>
|
||||
<dimen name="module_och_bus_order_status_divider_marginLeft">30px</dimen>
|
||||
<dimen name="module_och_bus_order_status_divider_marginTop">23px</dimen>
|
||||
<dimen name="module_och_bus_order_status_divider_marginRight">30px</dimen>
|
||||
<dimen name="module_och_bus_order_status_stationInfo_height">146px</dimen>
|
||||
<dimen name="module_och_bus_order_status_stationInfo_paddingLeft">20px</dimen>
|
||||
<dimen name="module_och_bus_order_status_stationInfo_paddingTop">23px</dimen>
|
||||
<dimen name="module_och_bus_order_status_stationInfo_paddingRight">30px</dimen>
|
||||
<dimen name="module_och_bus_order_status_stationInfo_paddingBottom">23px</dimen>
|
||||
<dimen name="module_och_bus_order_start_station_textSize">26px</dimen>
|
||||
<dimen name="module_och_bus_order_start_station_anchor_textSize">32px</dimen>
|
||||
<dimen name="module_och_bus_order_end_station_anchor_textSize">20px</dimen>
|
||||
<dimen name="module_och_bus_order_distance_container_height">80px</dimen>
|
||||
<dimen name="module_och_bus_order_distance_container_marginLeft">3px</dimen>
|
||||
<dimen name="module_och_bus_order_distance_anchor_marginTop">44.5px</dimen>
|
||||
<dimen name="module_och_bus_order_distance_anchor_textSize">20px</dimen>
|
||||
<dimen name="module_och_bus_order_distance_textSize">28px</dimen>
|
||||
<dimen name="module_och_bus_order_distance_marginRight">27px</dimen>
|
||||
|
||||
|
||||
<dimen name="module_mogo_och_autopilot_order_tag_height">25.6px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_order_tag_m_t">20px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_order_tag_m_r">20px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_order_tag_p_r">16px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_order_tag_p_l">16px</dimen>
|
||||
|
||||
</resources>
|
||||
@@ -48,10 +48,16 @@
|
||||
<dimen name="module_och_bus_order_end_station_anchor_textSize">20px</dimen>
|
||||
<dimen name="module_och_bus_order_distance_container_height">80px</dimen>
|
||||
<dimen name="module_och_bus_order_distance_container_marginLeft">3px</dimen>
|
||||
<dimen name="module_och_bus_order_distance_anchor_marginLeft">27px</dimen>
|
||||
<dimen name="module_och_bus_order_distance_anchor_marginTop">27px</dimen>
|
||||
<dimen name="module_och_bus_order_distance_anchor_textSize">20px</dimen>
|
||||
<dimen name="module_och_bus_order_distance_textSize">28px</dimen>
|
||||
<dimen name="module_och_bus_order_distance_marginRight">27px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_autopilot_order_tag_height">16px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_order_tag_m_t">16px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_order_tag_m_r">16px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_order_tag_p_r">16px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_order_tag_p_l">16px</dimen>
|
||||
|
||||
|
||||
</resources>
|
||||
@@ -46,7 +46,7 @@ class MogoOCHTaxiModel {
|
||||
/**
|
||||
* 到达起始点围栏
|
||||
*/
|
||||
public static final int ARRIVE_AT_START_STATION_DISTANCE = 10;
|
||||
public static final int ARRIVE_AT_START_STATION_DISTANCE = 20;
|
||||
|
||||
private static volatile MogoOCHTaxiModel sInstance;
|
||||
|
||||
|
||||
|
Before Width: | Height: | Size: 828 B |
|
Before Width: | Height: | Size: 323 B |
|
Before Width: | Height: | Size: 850 B |
@@ -1,45 +1,55 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="300px"
|
||||
android:layout_height="270px"
|
||||
android:layout_width="@dimen/module_mogo_och_autopilot_order_bg_width"
|
||||
android:layout_height="@dimen/module_mogo_och_autopilot_order_bg_height"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/module_och_taxi_order_status"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/module_och_taxi_order_status_marginLeft"
|
||||
android:layout_marginTop="@dimen/module_och_taxi_order_status_marginTop"
|
||||
android:text="@string/module_och_taxi_order_status_ph_text"
|
||||
android:textColor="@color/module_och_order_status_textColor"
|
||||
android:textSize="@dimen/module_och_taxi_order_status_textSize"
|
||||
android:textStyle="bold" />
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<View
|
||||
android:id="@+id/module_och_taxi_order_status_divider"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="@dimen/module_och_taxi_order_status_divider_height"
|
||||
android:layout_marginLeft="@dimen/module_och_taxi_order_status_divider_marginLeft"
|
||||
android:layout_marginTop="@dimen/module_och_taxi_order_status_divider_marginTop"
|
||||
android:layout_marginRight="@dimen/module_och_taxi_order_status_divider_marginRight"
|
||||
android:background="@color/module_och_taxi_order_status_divider_bkgColor" />
|
||||
android:background="@color/module_och_taxi_order_status_divider_bkgColor"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/module_och_taxi_order_status" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/module_och_taxi_order_status_stationInfo"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/module_och_taxi_order_status_stationInfo_height"
|
||||
android:layout_height="0dp"
|
||||
android:paddingLeft="@dimen/module_och_taxi_order_status_stationInfo_paddingLeft"
|
||||
android:paddingTop="@dimen/module_och_taxi_order_status_stationInfo_paddingTop"
|
||||
android:paddingRight="@dimen/module_och_taxi_order_status_stationInfo_paddingRight"
|
||||
android:paddingBottom="@dimen/module_och_taxi_order_status_stationInfo_paddingBottom">
|
||||
android:paddingBottom="@dimen/module_och_taxi_order_status_stationInfo_paddingBottom"
|
||||
app:layout_constraintBottom_toTopOf="@+id/module_och_taxi_order_distance_container"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/module_och_taxi_order_status_divider">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/greenDot"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/module_och_taxi_green_dot"
|
||||
android:src="@drawable/module_mogo_och_icon_arriving_station"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/module_och_taxi_order_start_station"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="@+id/module_och_taxi_order_start_station" />
|
||||
@@ -48,7 +58,7 @@
|
||||
android:id="@+id/module_och_taxi_order_start_station"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="5px"
|
||||
android:layout_marginLeft="@dimen/module_och_taxi_order_start_station_marginLeft"
|
||||
android:textColor="@color/module_och_order_status_textColor"
|
||||
android:textSize="@dimen/module_och_taxi_order_start_station_textSize"
|
||||
android:textStyle="bold"
|
||||
@@ -72,17 +82,18 @@
|
||||
android:id="@+id/dotLine"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="0dp"
|
||||
android:src="@drawable/module_och_taxi_dot_line"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@drawable/module_och_dot_line"
|
||||
app:layout_constraintBottom_toTopOf="@+id/blueDot"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/greenDot"
|
||||
app:layout_constraintRight_toRightOf="@+id/greenDot"
|
||||
app:layout_constraintBottom_toTopOf="@+id/blueDot"
|
||||
app:layout_constraintTop_toBottomOf="@+id/greenDot" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/blueDot"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/module_och_taxi_blue_dot"
|
||||
android:src="@drawable/module_mogo_och_icon_arrived_station"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/module_och_taxi_order_end_station"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/greenDot"
|
||||
app:layout_constraintTop_toTopOf="@+id/module_och_taxi_order_end_station" />
|
||||
@@ -118,7 +129,10 @@
|
||||
android:id="@+id/module_och_taxi_order_distance_container"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/module_och_taxi_order_distance_container_height"
|
||||
android:background="@drawable/module_och_taxi_panel_distance_bkg">
|
||||
android:background="@drawable/module_och_taxi_panel_distance_bkg"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/module_och_taxi_order_distance_anchor"
|
||||
@@ -146,4 +160,4 @@
|
||||
app:layout_constraintLeft_toRightOf="@+id/greenDot" />
|
||||
</FrameLayout>
|
||||
|
||||
</LinearLayout>
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -2,8 +2,9 @@
|
||||
<resources>
|
||||
<dimen name="module_och_taxi_panel_width">464px</dimen>
|
||||
<dimen name="module_och_taxi_panel_height">310px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_marginLeft">20px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_marginTop">20px</dimen>
|
||||
<dimen name="module_och_taxi_order_start_station_marginLeft">15px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_marginLeft">25px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_marginTop">25px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_textSize">20px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_divider_height">1px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_divider_marginLeft">20px</dimen>
|
||||
@@ -11,16 +12,16 @@
|
||||
<dimen name="module_och_taxi_order_status_divider_marginRight">20px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_stationInfo_height">140px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_stationInfo_paddingLeft">20px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_stationInfo_paddingTop">20px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_stationInfo_paddingTop">41px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_stationInfo_paddingRight">17px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_stationInfo_paddingBottom">20px</dimen>
|
||||
<dimen name="module_och_taxi_order_start_station_textSize">26px</dimen>
|
||||
<dimen name="module_och_taxi_order_start_station_anchor_textSize">20px</dimen>
|
||||
<dimen name="module_och_taxi_order_end_station_anchor_textSize">20px</dimen>
|
||||
<dimen name="module_och_taxi_order_distance_container_height">64px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_stationInfo_paddingBottom">41px</dimen>
|
||||
<dimen name="module_och_taxi_order_start_station_textSize">42px</dimen>
|
||||
<dimen name="module_och_taxi_order_start_station_anchor_textSize">32px</dimen>
|
||||
<dimen name="module_och_taxi_order_end_station_anchor_textSize">32px</dimen>
|
||||
<dimen name="module_och_taxi_order_distance_container_height">84px</dimen>
|
||||
<dimen name="module_och_taxi_order_distance_container_marginLeft">3px</dimen>
|
||||
<dimen name="module_och_taxi_order_distance_anchor_marginLeft">20px</dimen>
|
||||
<dimen name="module_och_taxi_order_distance_anchor_textSize">20px</dimen>
|
||||
<dimen name="module_och_taxi_order_distance_textSize">24px</dimen>
|
||||
<dimen name="module_och_taxi_order_distance_anchor_textSize">32px</dimen>
|
||||
<dimen name="module_och_taxi_order_distance_textSize">36px</dimen>
|
||||
<dimen name="module_och_taxi_order_distance_marginRight">17px</dimen>
|
||||
</resources>
|
||||
@@ -2,6 +2,7 @@
|
||||
<resources>
|
||||
<dimen name="module_och_taxi_panel_width">464px</dimen>
|
||||
<dimen name="module_och_taxi_panel_height">310px</dimen>
|
||||
<dimen name="module_och_taxi_order_start_station_marginLeft">5px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_marginLeft">20px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_marginTop">20px</dimen>
|
||||
<dimen name="module_och_taxi_order_status_textSize">20px</dimen>
|
||||
|
||||
@@ -3,6 +3,7 @@ package com.mogo.och.view;
|
||||
import android.animation.ObjectAnimator;
|
||||
import android.animation.ValueAnimator;
|
||||
import android.content.Context;
|
||||
import android.content.res.TypedArray;
|
||||
import android.graphics.Bitmap;
|
||||
import android.graphics.BitmapFactory;
|
||||
import android.graphics.Canvas;
|
||||
@@ -41,6 +42,14 @@ public class SlidePanelView extends View {
|
||||
|
||||
public SlidePanelView(Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
|
||||
super(context, attrs, defStyleAttr);
|
||||
TypedArray mTypedArray = context.obtainStyledAttributes(attrs, R.styleable.SlidePanelView);
|
||||
textSize = (int) mTypedArray.getDimension(R.styleable.SlidePanelView_textSize, textSize);
|
||||
BLOCK_START_X = (int) mTypedArray.getDimension(R.styleable.SlidePanelView_BLOCK_START_X, BLOCK_START_X);
|
||||
BLOCK_START_Y = (int) mTypedArray.getDimension(R.styleable.SlidePanelView_BLOCK_START_Y, BLOCK_START_Y);
|
||||
NORMAL_TEXT_MARGIN_LEFT = (int) mTypedArray.getDimension(R.styleable.SlidePanelView_NORMAL_TEXT_MARGIN_LEFT, NORMAL_TEXT_MARGIN_LEFT);
|
||||
NORMAL_TEXT_MARGIN_RIGHT = (int) mTypedArray.getDimension(R.styleable.SlidePanelView_NORMAL_TEXT_MARGIN_RIGHT, NORMAL_TEXT_MARGIN_RIGHT);
|
||||
SHORT_TEXT_MARGIN_LEFT = (int) mTypedArray.getDimension(R.styleable.SlidePanelView_SHORT_TEXT_MARGIN_LEFT, SHORT_TEXT_MARGIN_LEFT);
|
||||
SHORT_TEXT_MARGIN_RIGHT = (int) mTypedArray.getDimension(R.styleable.SlidePanelView_SHORT_TEXT_MARGIN_RIGHT, SHORT_TEXT_MARGIN_RIGHT);
|
||||
init();
|
||||
}
|
||||
|
||||
@@ -48,12 +57,13 @@ public class SlidePanelView extends View {
|
||||
private final Paint blockPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
|
||||
private final Paint textPaint = new Paint(Paint.ANTI_ALIAS_FLAG);
|
||||
|
||||
private static final int BLOCK_START_X = 15;
|
||||
private static final int BLOCK_START_Y = 15;
|
||||
private static final int NORMAL_TEXT_MARGIN_LEFT = 40;
|
||||
private static final int NORMAL_TEXT_MARGIN_RIGHT = 50;
|
||||
private static final int SHORT_TEXT_MARGIN_LEFT = 60;
|
||||
private static final int SHORT_TEXT_MARGIN_RIGHT = 70;
|
||||
private static int textSize = 40;
|
||||
private static int BLOCK_START_X = 15;
|
||||
private static int BLOCK_START_Y = 15;
|
||||
private static int NORMAL_TEXT_MARGIN_LEFT = 40;
|
||||
private static int NORMAL_TEXT_MARGIN_RIGHT = 60;
|
||||
private static int SHORT_TEXT_MARGIN_LEFT = 60;
|
||||
private static int SHORT_TEXT_MARGIN_RIGHT = 70;
|
||||
|
||||
private int textMarginLeft = NORMAL_TEXT_MARGIN_LEFT;
|
||||
private int textMarginRight = NORMAL_TEXT_MARGIN_RIGHT;
|
||||
@@ -107,7 +117,7 @@ public class SlidePanelView extends View {
|
||||
bgPaint.setStyle(Paint.Style.FILL);
|
||||
|
||||
textPaint.setStyle(Paint.Style.FILL);
|
||||
textPaint.setTextSize(40);
|
||||
textPaint.setTextSize(textSize);
|
||||
textPaint.setTextAlign(Paint.Align.LEFT);
|
||||
textGradient = new LinearGradient(-GRADIENT_OFFSET, 0, 0, 0, new int[]{0x33ffffff, 0xffffffff, 0x33ffffff}, null, Shader.TileMode.CLAMP);
|
||||
textGradient.setLocalMatrix(gradientMatrix);
|
||||
|
||||
|
After Width: | Height: | Size: 2.3 KiB |
|
After Width: | Height: | Size: 1.4 KiB |
|
After Width: | Height: | Size: 1.3 KiB |
|
After Width: | Height: | Size: 4.8 KiB |
|
After Width: | Height: | Size: 1004 B |
|
Before Width: | Height: | Size: 850 B After Width: | Height: | Size: 850 B |
|
Before Width: | Height: | Size: 828 B After Width: | Height: | Size: 828 B |
|
Before Width: | Height: | Size: 323 B After Width: | Height: | Size: 323 B |
@@ -3,8 +3,7 @@
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:paddingBottom="@dimen/module_mogo_och_margin_bottom">
|
||||
android:layout_height="match_parent">
|
||||
|
||||
<CheckedTextView
|
||||
android:id="@+id/module_mogo_och_autopilot_status"
|
||||
@@ -14,11 +13,11 @@
|
||||
android:layout_marginTop="@dimen/module_mogo_och_station_panel_container_margin_top_no_call"
|
||||
android:background="@drawable/module_mogo_och_autopilot_status_bg"
|
||||
android:drawableLeft="@drawable/module_och_bus_ic_autopilot"
|
||||
android:drawablePadding="@dimen/dp_30"
|
||||
android:elevation="@dimen/dp_10"
|
||||
android:gravity="center"
|
||||
android:paddingLeft="35px"
|
||||
android:gravity="center_vertical"
|
||||
android:paddingLeft="@dimen/module_mogo_och_operation_status_padding"
|
||||
android:text="自动驾驶"
|
||||
android:textAlignment="center"
|
||||
android:textColor="@color/module_mogo_och_autopilot_text_color_normal"
|
||||
android:textSize="@dimen/module_mogo_och_autopilot_status_text_size"
|
||||
android:textStyle="bold"
|
||||
@@ -28,9 +27,9 @@
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/module_mogo_och_station_panel_container"
|
||||
android:layout_width="300px"
|
||||
android:layout_height="270px"
|
||||
android:layout_marginTop="16px"
|
||||
android:layout_width="@dimen/module_mogo_och_autopilot_order_bg_width"
|
||||
android:layout_height="@dimen/module_mogo_och_autopilot_order_bg_height"
|
||||
android:layout_marginTop="@dimen/module_mogo_och_autopilot_order_m_t"
|
||||
android:background="@drawable/module_och_panel_bkg"
|
||||
android:elevation="@dimen/dp_10"
|
||||
android:visibility="gone"
|
||||
@@ -43,25 +42,36 @@
|
||||
android:id="@+id/module_mogo_och_operation_status"
|
||||
android:layout_width="@dimen/module_mogo_och_operation_status_bg_width"
|
||||
android:layout_height="@dimen/module_mogo_och_operation_status_bg_height"
|
||||
android:layout_marginLeft="@dimen/module_mogo_och_autopilot_status_text_m_l"
|
||||
android:layout_marginBottom="@dimen/module_mogo_och_margin_bottom"
|
||||
android:background="@drawable/module_mogo_och_operation_status_bg"
|
||||
android:gravity="center"
|
||||
android:elevation="@dimen/dp_10"
|
||||
android:text="开启"
|
||||
android:gravity="center"
|
||||
android:text="出车"
|
||||
android:textAlignment="center"
|
||||
android:textColor="@color/module_mogo_och_autopilot_text_color_selector"
|
||||
android:textSize="@dimen/module_mogo_och_autopilot_status_text_size"
|
||||
android:textStyle="bold"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/module_mogo_och_autopilot_status" />
|
||||
app:layout_constraintLeft_toLeftOf="parent" />
|
||||
|
||||
<com.mogo.och.view.SlidePanelView
|
||||
android:id="@+id/module_mogo_och_slide_panel"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginBottom="@dimen/module_mogo_och_margin_bottom"
|
||||
android:visibility="gone"
|
||||
app:BLOCK_START_X="@dimen/module_mogo_och_slide_panel_block_start_x"
|
||||
app:BLOCK_START_Y="@dimen/module_mogo_och_slide_panel_block_start_y"
|
||||
app:NORMAL_TEXT_MARGIN_LEFT="@dimen/module_mogo_och_slide_panel_normal_text_margin_left"
|
||||
app:NORMAL_TEXT_MARGIN_RIGHT="@dimen/module_mogo_och_slide_panel_normal_text_margin_right"
|
||||
app:SHORT_TEXT_MARGIN_LEFT="@dimen/module_mogo_och_slide_panel_short_text_margin_left"
|
||||
app:SHORT_TEXT_MARGIN_RIGHT="@dimen/module_mogo_och_slide_panel_short_text_margin_right"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintRight_toRightOf="parent" />
|
||||
app:layout_constraintRight_toRightOf="parent"
|
||||
app:textSize="@dimen/module_mogo_och_slide_panel_textSize"
|
||||
tools:visibility="visible" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnAutopilotDisable"
|
||||
|
||||
42
OCH/mogo-och/src/main/res/values-xhdpi-2560x1440/dimens.xml
Normal file
@@ -0,0 +1,42 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<!-- 此资源适配分体机 xhdpi -->
|
||||
<dimen name="module_mogo_och_margin_left">40px</dimen>
|
||||
<dimen name="module_mogo_och_margin_right">40px</dimen>
|
||||
<dimen name="module_mogo_och_margin_bottom">46px</dimen>
|
||||
<dimen name="module_mogo_och_margin_top">24px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_station_panel_container_margin_top_no_call">530px</dimen>
|
||||
<dimen name="module_mogo_och_station_panel_container_margin_top_with_call">492px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_slide_panel_block_start_x">20px</dimen>
|
||||
<dimen name="module_mogo_och_slide_panel_block_start_y">20px</dimen>
|
||||
<dimen name="module_mogo_och_slide_panel_normal_text_margin_left">70px</dimen>
|
||||
<dimen name="module_mogo_och_slide_panel_normal_text_margin_right">130px</dimen>
|
||||
<dimen name="module_mogo_och_slide_panel_short_text_margin_left">93px</dimen>
|
||||
<dimen name="module_mogo_och_slide_panel_short_text_margin_right">150px</dimen>
|
||||
<dimen name="module_mogo_och_slide_panel_textSize">70px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_autopilot_status_bg_corner">24px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_status_bg_width">460px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_status_bg_height">140px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_operation_status_bg_width">145px</dimen>
|
||||
<dimen name="module_mogo_och_operation_status_bg_height">145px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_operation_status_padding">92px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_autopilot_order_m_t">30px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_order_bg_width">466px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_order_bg_height">414px</dimen>
|
||||
|
||||
|
||||
<dimen name="module_mogo_och_autopilot_status_text_size">44px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_status_text_padding_top">13px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_status_text_drawable_padding">12px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_status_text_m_l">224px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_notice_text_max_width">460px</dimen>
|
||||
<dimen name="module_mogo_och_notice_text_size">30px</dimen>
|
||||
|
||||
</resources>
|
||||
12
OCH/mogo-och/src/main/res/values/attrs.xml
Normal file
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<declare-styleable name="SlidePanelView">
|
||||
<attr name="textSize" format="dimension" />
|
||||
<attr name="NORMAL_TEXT_MARGIN_LEFT" format="dimension" />
|
||||
<attr name="NORMAL_TEXT_MARGIN_RIGHT" format="dimension" />
|
||||
<attr name="SHORT_TEXT_MARGIN_LEFT" format="dimension" />
|
||||
<attr name="SHORT_TEXT_MARGIN_RIGHT" format="dimension" />
|
||||
<attr name="BLOCK_START_X" format="dimension" />
|
||||
<attr name="BLOCK_START_Y" format="dimension" />
|
||||
</declare-styleable>
|
||||
</resources>
|
||||
@@ -9,15 +9,31 @@
|
||||
<dimen name="module_mogo_och_station_panel_container_margin_top_no_call">345px</dimen>
|
||||
<dimen name="module_mogo_och_station_panel_container_margin_top_with_call">492px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_slide_panel_block_start_x">15px</dimen>
|
||||
<dimen name="module_mogo_och_slide_panel_block_start_y">15px</dimen>
|
||||
<dimen name="module_mogo_och_slide_panel_normal_text_margin_left">40px</dimen>
|
||||
<dimen name="module_mogo_och_slide_panel_normal_text_margin_right">50px</dimen>
|
||||
<dimen name="module_mogo_och_slide_panel_short_text_margin_left">50px</dimen>
|
||||
<dimen name="module_mogo_och_slide_panel_short_text_margin_right">70px</dimen>
|
||||
<dimen name="module_mogo_och_slide_panel_textSize">40px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_autopilot_status_bg_corner">24px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_status_bg_width">300px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_status_bg_height">100px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_operation_status_bg_width">108px</dimen>
|
||||
<dimen name="module_mogo_och_operation_status_bg_height">108px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_operation_status_padding">35px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_autopilot_order_m_t">15px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_order_bg_width">300px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_order_bg_height">270px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_autopilot_status_text_size">30px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_status_text_padding_top">13px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_status_text_drawable_padding">12px</dimen>
|
||||
<dimen name="module_mogo_och_autopilot_status_text_m_l">188px</dimen>
|
||||
|
||||
<dimen name="module_mogo_och_notice_text_max_width">460px</dimen>
|
||||
<dimen name="module_mogo_och_notice_text_size">30px</dimen>
|
||||
|
||||
141
app/build.gradle
@@ -76,6 +76,9 @@ android {
|
||||
f8xxLauncherOnlineRelease {
|
||||
manifest.srcFile 'src/f8xxLauncherOnlineRelease/AndroidManifest.xml'
|
||||
}
|
||||
fPadLenovoLauncherOnlineRelease {
|
||||
manifest.srcFile 'src/f8xxLauncherOnlineRelease/AndroidManifest.xml'
|
||||
}
|
||||
}
|
||||
|
||||
flavorDimensions "product", "basic", "env"
|
||||
@@ -105,13 +108,14 @@ android {
|
||||
}
|
||||
// f系列-网约车-出租车
|
||||
fochtaxi {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.fLauncherApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '0'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'true'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue, CHANNEL_VALUE: "fochtaxi"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -133,13 +137,14 @@ android {
|
||||
}
|
||||
// f系列-网约车-小巴车
|
||||
fochbus {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.fLauncherApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '0'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'true'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue,CHANNEL_VALUE: "fochbus"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -161,13 +166,14 @@ android {
|
||||
}
|
||||
// f系列-分体机全系列,未细分
|
||||
f8xx {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.fLauncherApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '0'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'true'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue,CHANNEL_VALUE: "f8xx"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -189,13 +195,14 @@ android {
|
||||
}
|
||||
// f系列-分体机
|
||||
f80x {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.fLauncherApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '0'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'true'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue, CHANNEL_VALUE: "f80x"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -215,15 +222,103 @@ android {
|
||||
// 是否需要使用工控机的rtk定位
|
||||
buildConfigField 'boolean', 'IS_USE_ADAS_RTK_LOCATION_INFO', 'true'
|
||||
}
|
||||
// 衡阳-联想Pad
|
||||
fPadLenovo {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.fLauncherApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '2'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'true'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue,CHANNEL_VALUE: "f8xx"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
buildConfigField 'boolean', 'IS_SKIN_SUPPORTED', 'true'
|
||||
// 是否支持查询导航目的地车友
|
||||
buildConfigField 'boolean', 'IS_SUPPORTED_SEARCH_DESTINATION_ONLINE_CAR_LIST', 'true'
|
||||
// 是否支持桌面卡片刷新
|
||||
buildConfigField 'boolean', 'IS_SUPPORT_LAUNCHER_CARD_REFRESH_STRATEGY', 'false'
|
||||
// 是否基于地图
|
||||
buildConfigField 'boolean', 'IS_MAP_BASED', 'true'
|
||||
// 是否加载引导模块
|
||||
buildConfigField 'boolean', 'IS_NEED_LOAD_GUIDE_MODULE', 'false'
|
||||
// 分享时是否隐藏 adas
|
||||
buildConfigField 'boolean', 'IS_NEED_HIDE_ADAS_WHEN_SHARE', 'false'
|
||||
// 是否需要实时上报坐标
|
||||
buildConfigField 'boolean', 'IS_NEED_UPLOAD_COORDINATES_IN_TIME', 'true'
|
||||
// 是否需要使用工控机的rtk定位
|
||||
buildConfigField 'boolean', 'IS_USE_ADAS_RTK_LOCATION_INFO', 'true'
|
||||
}
|
||||
// f系列-网约车-出租车
|
||||
fPadLenovoOchTaxi {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.fLauncherApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '2'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'true'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue, CHANNEL_VALUE: "fochtaxi"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
buildConfigField 'boolean', 'IS_SKIN_SUPPORTED', 'true'
|
||||
// 是否支持查询导航目的地车友
|
||||
buildConfigField 'boolean', 'IS_SUPPORTED_SEARCH_DESTINATION_ONLINE_CAR_LIST', 'true'
|
||||
// 是否支持桌面卡片刷新
|
||||
buildConfigField 'boolean', 'IS_SUPPORT_LAUNCHER_CARD_REFRESH_STRATEGY', 'false'
|
||||
// 是否基于地图
|
||||
buildConfigField 'boolean', 'IS_MAP_BASED', 'true'
|
||||
// 是否加载引导模块
|
||||
buildConfigField 'boolean', 'IS_NEED_LOAD_GUIDE_MODULE', 'false'
|
||||
// 分享时是否隐藏 adas
|
||||
buildConfigField 'boolean', 'IS_NEED_HIDE_ADAS_WHEN_SHARE', 'false'
|
||||
// 是否需要实时上报坐标
|
||||
buildConfigField 'boolean', 'IS_NEED_UPLOAD_COORDINATES_IN_TIME', 'true'
|
||||
// 是否需要使用工控机的rtk定位
|
||||
buildConfigField 'boolean', 'IS_USE_ADAS_RTK_LOCATION_INFO', 'true'
|
||||
}
|
||||
// f系列-网约车-小巴车
|
||||
fPadLenovoOchBus {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.fLauncherApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '2'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'true'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue,CHANNEL_VALUE: "fochbus"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
buildConfigField 'boolean', 'IS_SKIN_SUPPORTED', 'true'
|
||||
// 是否支持查询导航目的地车友
|
||||
buildConfigField 'boolean', 'IS_SUPPORTED_SEARCH_DESTINATION_ONLINE_CAR_LIST', 'true'
|
||||
// 是否支持桌面卡片刷新
|
||||
buildConfigField 'boolean', 'IS_SUPPORT_LAUNCHER_CARD_REFRESH_STRATEGY', 'false'
|
||||
// 是否基于地图
|
||||
buildConfigField 'boolean', 'IS_MAP_BASED', 'true'
|
||||
// 是否加载引导模块
|
||||
buildConfigField 'boolean', 'IS_NEED_LOAD_GUIDE_MODULE', 'false'
|
||||
// 分享时是否隐藏 adas
|
||||
buildConfigField 'boolean', 'IS_NEED_HIDE_ADAS_WHEN_SHARE', 'false'
|
||||
// 是否需要实时上报坐标
|
||||
buildConfigField 'boolean', 'IS_NEED_UPLOAD_COORDINATES_IN_TIME', 'true'
|
||||
// 是否需要使用工控机的rtk定位
|
||||
buildConfigField 'boolean', 'IS_USE_ADAS_RTK_LOCATION_INFO', 'true'
|
||||
}
|
||||
// f系列-分体机
|
||||
phone {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.fLauncherApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '1'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'true'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue, CHANNEL_VALUE: "phone"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -245,13 +340,14 @@ android {
|
||||
}
|
||||
// f系列-分体机-高德
|
||||
f8Amap {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.fLauncherApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '0'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'true'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.fLauncherAmapApiValue, CHANNEL_VALUE: "f8Amap"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -273,13 +369,14 @@ android {
|
||||
}
|
||||
// e系列,采用Launcher方案
|
||||
e8xx {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.launcherApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '0'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'true'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonLauncherAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonLauncherAmapApiValue, CHANNEL_VALUE: "e8xx"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -301,13 +398,14 @@ android {
|
||||
}
|
||||
// 同上
|
||||
em4 {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.launcherApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '0'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'true'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonLauncherAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonLauncherAmapApiValue, CHANNEL_VALUE: "em4"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -329,13 +427,14 @@ android {
|
||||
}
|
||||
// e系列-2+32,对标D系列2+32,采用独立app的形式
|
||||
em3 {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.independentApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '0'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'false'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonIndependentAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonIndependentAmapApiValue,CHANNEL_VALUE: "em3"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -357,13 +456,14 @@ android {
|
||||
}
|
||||
// e系列-1+16,对标D系列1+16,采用独立app形式
|
||||
em1 {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.independentApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '0'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'false'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonIndependentAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonIndependentAmapApiValue,CHANNEL_VALUE: "em1"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -385,13 +485,14 @@ android {
|
||||
}
|
||||
// e系列-1+16,对标D系列1+16,采用独立app形式
|
||||
em2 {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.independentApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '0'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'false'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonIndependentAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonIndependentAmapApiValue,CHANNEL_VALUE: "em2"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -413,13 +514,14 @@ android {
|
||||
}
|
||||
// d系列
|
||||
d8xx {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.independentApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '0'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'false'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonIndependentAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonIndependentAmapApiValue,CHANNEL_VALUE: "d8xx"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -441,13 +543,14 @@ android {
|
||||
}
|
||||
// d系列 2 + 32
|
||||
d80x {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.independentApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '0'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'false'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonIndependentAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonIndependentAmapApiValue,CHANNEL_VALUE: "d80x"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -469,13 +572,14 @@ android {
|
||||
}
|
||||
// d系列 1+16 版本
|
||||
d82x {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.independentApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,自研车机类型为0
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '0'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'false'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonIndependentAmapApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.commonIndependentAmapApiValue,CHANNEL_VALUE: "d82x"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'false'
|
||||
// 是否支持换肤
|
||||
@@ -497,13 +601,14 @@ android {
|
||||
}
|
||||
// 比亚迪
|
||||
bydauto {
|
||||
// 应用包名
|
||||
applicationId rootProject.ext.android.bydautoIndependentApplicationId
|
||||
dimension "product"
|
||||
buildConfigField 'boolean', 'AI_ASSIST_ACTIVE_STAUTS', 'false'
|
||||
// 车机类型,主要用于区分自研车机还是别人家的车机,其他车机,比亚迪定为1
|
||||
buildConfigField 'int', 'CAR_MACHINE_TYPE', '1'
|
||||
buildConfigField 'boolean', 'ROAD_EVENT_ANIMATED', 'true'
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.bydautoIndependentApiValue]
|
||||
manifestPlaceholders = [AMAP_API_VALUE: rootProject.ext.android.bydautoIndependentApiValue,CHANNEL_VALUE: "bydauto"]
|
||||
// 是否使用高德sdk自定义导航
|
||||
buildConfigField 'boolean', 'USE_CUSTOM_NAVI', 'true'
|
||||
// 是否支持换肤
|
||||
@@ -557,7 +662,7 @@ repositories {
|
||||
}
|
||||
|
||||
aspectjx {
|
||||
include "com.mogo.chat"
|
||||
include "com.mogo.chat"
|
||||
}
|
||||
|
||||
dependencies {
|
||||
@@ -602,7 +707,6 @@ dependencies {
|
||||
implementation project(':modules:mogo-module-search')
|
||||
implementation project(':modules:mogo-module-authorize')
|
||||
implementation project(':modules:mogo-module-service')
|
||||
// implementation project(':modules:mogo-module-obu')
|
||||
implementation project(':modules:mogo-module-splash')
|
||||
implementation project(':modules:mogo-module-service')
|
||||
implementation project(':modules:mogo-module-v2x')
|
||||
@@ -618,15 +722,12 @@ dependencies {
|
||||
apply from: "./functions/aicloudservices.gradle"
|
||||
apply from: "./functions/basedmap.gradle"
|
||||
apply from: "./functions/perform.gradle"
|
||||
// apply from: "./functions/baseservices.gradle"
|
||||
apply from: "./functions/socketpush.gradle"
|
||||
// apply from: "./functions/gpssimulator.gradle"
|
||||
apply from: "./functions/leftpanel.gradle"
|
||||
apply from: "./functions/skin.gradle"
|
||||
apply from: "./functions/crashreport.gradle"
|
||||
apply from: "./functions/widgets.gradle"
|
||||
apply from: "./functions/tts.gradle"
|
||||
// apply from: "./functions/httpdns.gradle"
|
||||
apply from: "./functions/backwidget.gradle"
|
||||
apply from: "./functions/mediaui.gradle"
|
||||
apply from: "./functions/bizguide.gradle"
|
||||
|
||||
@@ -28,6 +28,33 @@ project.android.productFlavors {
|
||||
}
|
||||
}
|
||||
}
|
||||
// 联想Pad
|
||||
fPadLenovo {
|
||||
externalNativeBuild {
|
||||
ndk {
|
||||
// 设置支持的SO库架构
|
||||
abiFilters "arm64-v8a"
|
||||
}
|
||||
}
|
||||
}
|
||||
// 联想Pad
|
||||
fPadLenovoOchTaxi {
|
||||
externalNativeBuild {
|
||||
ndk {
|
||||
// 设置支持的SO库架构
|
||||
abiFilters "arm64-v8a"
|
||||
}
|
||||
}
|
||||
}
|
||||
// 联想Pad
|
||||
fPadLenovoOchBus {
|
||||
externalNativeBuild {
|
||||
ndk {
|
||||
// 设置支持的SO库架构
|
||||
abiFilters "arm64-v8a"
|
||||
}
|
||||
}
|
||||
}
|
||||
// f系列-分体机
|
||||
f80x {
|
||||
externalNativeBuild {
|
||||
|
||||
@@ -12,11 +12,14 @@ project.dependencies {
|
||||
em4Implementation rootProject.ext.dependencies.mogoaicloudserviceapk
|
||||
e8xxImplementation rootProject.ext.dependencies.mogoaicloudserviceapk
|
||||
f8xxImplementation rootProject.ext.dependencies.mogoaicloudserviceapk
|
||||
fPadLenovoImplementation rootProject.ext.dependencies.mogoaicloudserviceapk
|
||||
f80xImplementation rootProject.ext.dependencies.mogoaicloudserviceapk
|
||||
f8AmapImplementation rootProject.ext.dependencies.mogoaicloudserviceapk
|
||||
em3Implementation rootProject.ext.dependencies.mogoaicloudserviceapk
|
||||
fochtaxiImplementation rootProject.ext.dependencies.mogoaicloudserviceapk
|
||||
fochbusImplementation rootProject.ext.dependencies.mogoaicloudserviceapk
|
||||
fPadLenovoOchTaxiImplementation rootProject.ext.dependencies.mogoaicloudserviceapk
|
||||
fPadLenovoOchBusImplementation rootProject.ext.dependencies.mogoaicloudserviceapk
|
||||
} else {
|
||||
bydautoImplementation project(':foudations:mogo-aicloud-services-sdk')
|
||||
phoneImplementation project(':foudations:mogo-aicloud-services-sdk')
|
||||
@@ -29,10 +32,13 @@ project.dependencies {
|
||||
em4Implementation project(':foudations:mogo-aicloud-services-apk')
|
||||
e8xxImplementation project(':foudations:mogo-aicloud-services-apk')
|
||||
f8xxImplementation project(':foudations:mogo-aicloud-services-apk')
|
||||
fPadLenovoImplementation project(':foudations:mogo-aicloud-services-apk')
|
||||
f80xImplementation project(':foudations:mogo-aicloud-services-apk')
|
||||
f8AmapImplementation project(':foudations:mogo-aicloud-services-apk')
|
||||
em3Implementation project(':foudations:mogo-aicloud-services-apk')
|
||||
fochtaxiImplementation project(':foudations:mogo-aicloud-services-apk')
|
||||
fochbusImplementation project(':foudations:mogo-aicloud-services-apk')
|
||||
fPadLenovoOchTaxiImplementation project(':foudations:mogo-aicloud-services-apk')
|
||||
fPadLenovoOchBusImplementation project(':foudations:mogo-aicloud-services-apk')
|
||||
}
|
||||
}
|
||||
@@ -4,9 +4,12 @@ project.dependencies {
|
||||
if (Boolean.valueOf(RELEASE)) {
|
||||
|
||||
f8xxImplementation rootProject.ext.dependencies.mapcustom
|
||||
fPadLenovoImplementation rootProject.ext.dependencies.mapcustom
|
||||
f80xImplementation rootProject.ext.dependencies.mapcustom
|
||||
fochtaxiImplementation rootProject.ext.dependencies.mapcustom
|
||||
fochbusImplementation rootProject.ext.dependencies.mapcustom
|
||||
fPadLenovoOchTaxiImplementation rootProject.ext.dependencies.mapcustom
|
||||
fPadLenovoOchBusImplementation rootProject.ext.dependencies.mapcustom
|
||||
phoneImplementation rootProject.ext.dependencies.mapcustom
|
||||
|
||||
f8AmapImplementation rootProject.ext.dependencies.mapamap
|
||||
@@ -22,9 +25,12 @@ project.dependencies {
|
||||
em3Implementation rootProject.ext.dependencies.mapamap
|
||||
} else {
|
||||
f8xxImplementation project(':libraries:map-custom')
|
||||
fPadLenovoImplementation project(':libraries:map-custom')
|
||||
f80xImplementation project(':libraries:map-custom')
|
||||
fochtaxiImplementation project(':libraries:map-custom')
|
||||
fochbusImplementation project(':libraries:map-custom')
|
||||
fPadLenovoOchTaxiImplementation project(':libraries:map-custom')
|
||||
fPadLenovoOchBusImplementation project(':libraries:map-custom')
|
||||
phoneImplementation project(':libraries:map-custom')
|
||||
|
||||
f8AmapImplementation project(':libraries:map-amap')
|
||||
|
||||
@@ -13,11 +13,14 @@ project.dependencies {
|
||||
em4Implementation rootProject.ext.dependencies.mogobaseserviceapk
|
||||
e8xxImplementation rootProject.ext.dependencies.mogobaseserviceapk
|
||||
f8xxImplementation rootProject.ext.dependencies.mogobaseserviceapk
|
||||
fPadLenovoImplementation rootProject.ext.dependencies.mogobaseserviceapk
|
||||
f80xImplementation rootProject.ext.dependencies.mogobaseserviceapk
|
||||
f8AmapImplementation rootProject.ext.dependencies.mogobaseserviceapk
|
||||
em3Implementation rootProject.ext.dependencies.mogobaseserviceapk
|
||||
fochtaxiImplementation rootProject.ext.dependencies.mogobaseserviceapk
|
||||
fochbusImplementation rootProject.ext.dependencies.mogobaseserviceapk
|
||||
fPadLenovoOchTaxiImplementation rootProject.ext.dependencies.mogobaseserviceapk
|
||||
fPadLenovoOchBusImplementation rootProject.ext.dependencies.mogobaseserviceapk
|
||||
} else {
|
||||
bydautoImplementation project(':foudations:mogo-base-services-sdk')
|
||||
phoneImplementation project(':foudations:mogo-base-services-sdk')
|
||||
@@ -30,10 +33,13 @@ project.dependencies {
|
||||
em4Implementation project(':foudations:mogo-base-services-apk')
|
||||
e8xxImplementation project(':foudations:mogo-base-services-apk')
|
||||
f8xxImplementation project(':foudations:mogo-base-services-apk')
|
||||
fPadLenovoImplementation project(':foudations:mogo-base-services-apk')
|
||||
f80xImplementation project(':foudations:mogo-base-services-apk')
|
||||
f8AmapImplementation project(':foudations:mogo-base-services-apk')
|
||||
em3Implementation project(':foudations:mogo-base-services-apk')
|
||||
fochtaxiImplementation project(':foudations:mogo-base-services-apk')
|
||||
fochbusImplementation project(':foudations:mogo-base-services-apk')
|
||||
fPadLenovoOchTaxiImplementation project(':foudations:mogo-base-services-apk')
|
||||
fPadLenovoOchBusImplementation project(':foudations:mogo-base-services-apk')
|
||||
}
|
||||
}
|
||||
@@ -9,11 +9,14 @@ project.dependencies {
|
||||
em4Implementation rootProject.ext.dependencies.mogomoduleguide
|
||||
e8xxImplementation rootProject.ext.dependencies.mogomoduleguide
|
||||
f8xxImplementation rootProject.ext.dependencies.mogomoduleguide
|
||||
fPadLenovoImplementation rootProject.ext.dependencies.mogomoduleguide
|
||||
f80xImplementation rootProject.ext.dependencies.mogomoduleguide
|
||||
f8AmapImplementation rootProject.ext.dependencies.mogomoduleguide
|
||||
em3Implementation rootProject.ext.dependencies.mogomoduleguide
|
||||
fochtaxiImplementation rootProject.ext.dependencies.mogomoduleguide
|
||||
fochbusImplementation rootProject.ext.dependencies.mogomoduleguide
|
||||
fPadLenovoOchTaxiImplementation rootProject.ext.dependencies.mogomoduleguide
|
||||
fPadLenovoOchBusImplementation rootProject.ext.dependencies.mogomoduleguide
|
||||
} else {
|
||||
bydautoImplementation project(':modules:mogo-module-guide')
|
||||
phoneImplementation project(':modules:mogo-module-guide')
|
||||
@@ -22,10 +25,13 @@ project.dependencies {
|
||||
em4Implementation project(':modules:mogo-module-guide')
|
||||
e8xxImplementation project(':modules:mogo-module-guide')
|
||||
f8xxImplementation project(':modules:mogo-module-guide')
|
||||
fPadLenovoImplementation project(':modules:mogo-module-guide')
|
||||
f80xImplementation project(':modules:mogo-module-guide')
|
||||
f8AmapImplementation project(':modules:mogo-module-guide')
|
||||
em3Implementation project(':modules:mogo-module-guide')
|
||||
fochtaxiImplementation project(':modules:mogo-module-guide')
|
||||
fochbusImplementation project(':modules:mogo-module-guide')
|
||||
fPadLenovoOchTaxiImplementation project(':modules:mogo-module-guide')
|
||||
fPadLenovoOchBusImplementation project(':modules:mogo-module-guide')
|
||||
}
|
||||
}
|
||||
@@ -3,11 +3,13 @@
|
||||
project.dependencies {
|
||||
if (Boolean.valueOf(RELEASE)) {
|
||||
implementation rootProject.ext.dependencies.crashreport
|
||||
implementation rootProject.ext.dependencies.crashreportupgrade
|
||||
debugImplementation rootProject.ext.dependencies.crashreportbugly
|
||||
releaseImplementation rootProject.ext.dependencies.crashreportnoop
|
||||
releaseImplementation rootProject.ext.dependencies.crashreportbugly
|
||||
} else {
|
||||
implementation project(':test:crashreport')
|
||||
debugImplementation project(':test:crashreport-bugly')
|
||||
releaseImplementation project(':test:crashreport-noop')
|
||||
implementation project(':test:crashreport-upgrade')
|
||||
implementation project(':test:crashreport-bugly')
|
||||
releaseImplementation project(':test:crashreport-bugly')
|
||||
}
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
// 基于后台轨迹模拟的gps模拟服务
|
||||
|
||||
project.dependencies {
|
||||
if (Boolean.valueOf(RELEASE)) {
|
||||
debugImplementation rootProject.ext.dependencies.gpssimulatornoop
|
||||
releaseImplementation rootProject.ext.dependencies.gpssimulatornoop
|
||||
} else {
|
||||
debugImplementation project(':modules:mogo-module-gps-simulator-noop')
|
||||
releaseImplementation project(':modules:mogo-module-gps-simulator-noop')
|
||||
}
|
||||
}
|
||||
@@ -13,11 +13,14 @@ project.dependencies {
|
||||
e8xxImplementation rootProject.ext.dependencies.moduleleftpanelnoop
|
||||
e8xxImplementation rootProject.ext.dependencies.moduleleftpanelnoop
|
||||
f8xxImplementation rootProject.ext.dependencies.moduleleftpanelnoop
|
||||
fPadLenovoImplementation rootProject.ext.dependencies.moduleleftpanelnoop
|
||||
f80xImplementation rootProject.ext.dependencies.moduleleftpanelnoop
|
||||
f8AmapImplementation rootProject.ext.dependencies.moduleleftpanelnoop
|
||||
em3Implementation rootProject.ext.dependencies.moduleleftpanelnoop
|
||||
fochtaxiImplementation rootProject.ext.dependencies.moduleleftpanelnoop
|
||||
fochbusImplementation rootProject.ext.dependencies.moduleleftpanelnoop
|
||||
fPadLenovoOchTaxiImplementation rootProject.ext.dependencies.moduleleftpanelnoop
|
||||
fPadLenovoOchBusImplementation rootProject.ext.dependencies.moduleleftpanelnoop
|
||||
phoneImplementation rootProject.ext.dependencies.moduleleftpanelnoop
|
||||
} else {
|
||||
bydautoImplementation project(':modules:mogo-module-left-panel')
|
||||
@@ -30,11 +33,14 @@ project.dependencies {
|
||||
em4Implementation project(':modules:mogo-module-left-panel-noop')
|
||||
e8xxImplementation project(':modules:mogo-module-left-panel-noop')
|
||||
f8xxImplementation project(':modules:mogo-module-left-panel-noop')
|
||||
fPadLenovoImplementation project(':modules:mogo-module-left-panel-noop')
|
||||
f80xImplementation project(':modules:mogo-module-left-panel-noop')
|
||||
f8AmapImplementation project(':modules:mogo-module-left-panel-noop')
|
||||
em3Implementation project(':modules:mogo-module-left-panel-noop')
|
||||
fochtaxiImplementation project(':modules:mogo-module-left-panel-noop')
|
||||
fochbusImplementation project(':modules:mogo-module-left-panel-noop')
|
||||
fPadLenovoOchTaxiImplementation project(':modules:mogo-module-left-panel-noop')
|
||||
fPadLenovoOchBusImplementation project(':modules:mogo-module-left-panel-noop')
|
||||
phoneImplementation project(':modules:mogo-module-left-panel-noop')
|
||||
}
|
||||
}
|
||||
@@ -10,12 +10,15 @@ project.dependencies {
|
||||
d8xxImplementation rootProject.ext.dependencies.mogoochnoop
|
||||
d80xImplementation rootProject.ext.dependencies.mogoochnoop
|
||||
f8xxImplementation rootProject.ext.dependencies.mogoochnoop
|
||||
fPadLenovoImplementation rootProject.ext.dependencies.mogoochnoop
|
||||
f80xImplementation rootProject.ext.dependencies.mogoochnoop
|
||||
f8AmapImplementation rootProject.ext.dependencies.mogoochnoop
|
||||
em4Implementation rootProject.ext.dependencies.mogoochnoop
|
||||
e8xxImplementation rootProject.ext.dependencies.mogoochnoop
|
||||
fochtaxiImplementation rootProject.ext.dependencies.mogoochtaxi
|
||||
fochbusImplementation rootProject.ext.dependencies.mogoochbus
|
||||
fPadLenovoOchTaxiImplementation rootProject.ext.dependencies.mogoochtaxi
|
||||
fPadLenovoOchBusImplementation rootProject.ext.dependencies.mogoochbus
|
||||
} else {
|
||||
bydautoImplementation project(':OCH:mogo-och-noop')
|
||||
phoneImplementation project(':OCH:mogo-och-noop')
|
||||
@@ -26,11 +29,14 @@ project.dependencies {
|
||||
d8xxImplementation project(':OCH:mogo-och-noop')
|
||||
d80xImplementation project(':OCH:mogo-och-noop')
|
||||
f8xxImplementation project(':OCH:mogo-och-noop')
|
||||
fPadLenovoImplementation project(':OCH:mogo-och-noop')
|
||||
f80xImplementation project(':OCH:mogo-och-noop')
|
||||
f8AmapImplementation project(':OCH:mogo-och-noop')
|
||||
em4Implementation project(':OCH:mogo-och-noop')
|
||||
e8xxImplementation project(':OCH:mogo-och-noop')
|
||||
fochtaxiImplementation project(':OCH:mogo-och-taxi')
|
||||
fochbusImplementation project(':OCH:mogo-och-bus')
|
||||
fPadLenovoOchTaxiImplementation project(':OCH:mogo-och-taxi')
|
||||
fPadLenovoOchBusImplementation project(':OCH:mogo-och-bus')
|
||||
}
|
||||
}
|
||||
@@ -10,15 +10,19 @@ project.dependencies {
|
||||
d8xxImplementation rootProject.ext.dependencies.skinsupportimpl
|
||||
d80xImplementation rootProject.ext.dependencies.skinsupportimpl
|
||||
f8xxImplementation rootProject.ext.dependencies.skinsupportimpl
|
||||
fPadLenovoImplementation rootProject.ext.dependencies.skinsupportimpl
|
||||
f80xImplementation rootProject.ext.dependencies.skinsupportimpl
|
||||
f8AmapImplementation rootProject.ext.dependencies.skinsupportimpl
|
||||
em4Implementation rootProject.ext.dependencies.skinsupportimpl
|
||||
e8xxImplementation rootProject.ext.dependencies.skinsupportimpl
|
||||
fochtaxiImplementation rootProject.ext.dependencies.skinsupportimpl
|
||||
fochbusImplementation rootProject.ext.dependencies.skinsupportimpl
|
||||
fPadLenovoOchTaxiImplementation rootProject.ext.dependencies.skinsupportimpl
|
||||
fPadLenovoOchBusImplementation rootProject.ext.dependencies.skinsupportimpl
|
||||
phoneImplementation rootProject.ext.dependencies.skinsupportimpl
|
||||
|
||||
f8xxImplementation rootProject.ext.dependencies.skinsupportlight
|
||||
fPadLenovoImplementation rootProject.ext.dependencies.skinsupportlight
|
||||
f80xImplementation rootProject.ext.dependencies.skinsupportlight
|
||||
f8AmapImplementation rootProject.ext.dependencies.skinsupportlight
|
||||
em4Implementation rootProject.ext.dependencies.skinsupportlight
|
||||
@@ -28,6 +32,8 @@ project.dependencies {
|
||||
em3Implementation rootProject.ext.dependencies.skinsupportlight
|
||||
fochtaxiImplementation rootProject.ext.dependencies.skinsupportlight
|
||||
fochbusImplementation rootProject.ext.dependencies.skinsupportlight
|
||||
fPadLenovoOchTaxiImplementation rootProject.ext.dependencies.skinsupportlight
|
||||
fPadLenovoOchBusImplementation rootProject.ext.dependencies.skinsupportlight
|
||||
phoneImplementation rootProject.ext.dependencies.skinsupportlight
|
||||
} else {
|
||||
|
||||
@@ -42,15 +48,19 @@ project.dependencies {
|
||||
d8xxImplementation project(':skin:mogo-skin-support-impl')
|
||||
d80xImplementation project(':skin:mogo-skin-support-impl')
|
||||
f8xxImplementation project(':skin:mogo-skin-support-impl')
|
||||
fPadLenovoImplementation project(':skin:mogo-skin-support-impl')
|
||||
f80xImplementation project(':skin:mogo-skin-support-impl')
|
||||
f8AmapImplementation project(':skin:mogo-skin-support-impl')
|
||||
em4Implementation project(':skin:mogo-skin-support-impl')
|
||||
e8xxImplementation project(':skin:mogo-skin-support-impl')
|
||||
fochtaxiImplementation project(':skin:mogo-skin-support-impl')
|
||||
fochbusImplementation project(':skin:mogo-skin-support-impl')
|
||||
fPadLenovoOchTaxiImplementation project(':skin:mogo-skin-support-impl')
|
||||
fPadLenovoOchBusImplementation project(':skin:mogo-skin-support-impl')
|
||||
phoneImplementation project(':skin:mogo-skin-support-impl')
|
||||
|
||||
f8xxImplementation project(':skin:mogo-skin-light')
|
||||
fPadLenovoImplementation project(':skin:mogo-skin-light')
|
||||
f80xImplementation project(':skin:mogo-skin-light')
|
||||
f8AmapImplementation project(':skin:mogo-skin-light')
|
||||
em4Implementation project(':skin:mogo-skin-light')
|
||||
@@ -60,6 +70,8 @@ project.dependencies {
|
||||
em3Implementation project(':skin:mogo-skin-light')
|
||||
fochtaxiImplementation project(':skin:mogo-skin-light')
|
||||
fochbusImplementation project(':skin:mogo-skin-light')
|
||||
fPadLenovoOchTaxiImplementation project(':skin:mogo-skin-light')
|
||||
fPadLenovoOchBusImplementation project(':skin:mogo-skin-light')
|
||||
phoneImplementation project(':skin:mogo-skin-light')
|
||||
}
|
||||
}
|
||||
@@ -8,12 +8,15 @@ project.dependencies {
|
||||
d8xxImplementation rootProject.ext.dependencies.ttszhi
|
||||
d80xImplementation rootProject.ext.dependencies.ttszhi
|
||||
f8xxImplementation rootProject.ext.dependencies.ttszhi
|
||||
fPadLenovoImplementation rootProject.ext.dependencies.ttszhi
|
||||
f80xImplementation rootProject.ext.dependencies.ttszhi
|
||||
f8AmapImplementation rootProject.ext.dependencies.ttszhi
|
||||
em4Implementation rootProject.ext.dependencies.ttszhi
|
||||
e8xxImplementation rootProject.ext.dependencies.ttszhi
|
||||
fochtaxiImplementation rootProject.ext.dependencies.ttszhi
|
||||
fochbusImplementation rootProject.ext.dependencies.ttszhi
|
||||
fPadLenovoOchTaxiImplementation rootProject.ext.dependencies.ttszhi
|
||||
fPadLenovoOchBusImplementation rootProject.ext.dependencies.ttszhi
|
||||
phoneImplementation rootProject.ext.dependencies.ttszhi
|
||||
} else {
|
||||
bydautoImplementation project(':tts:tts-di')
|
||||
@@ -24,12 +27,15 @@ project.dependencies {
|
||||
d8xxImplementation project(':tts:tts-zhi')
|
||||
d80xImplementation project(':tts:tts-zhi')
|
||||
f8xxImplementation project(':tts:tts-zhi')
|
||||
fPadLenovoImplementation project(':tts:tts-zhi')
|
||||
f80xImplementation project(':tts:tts-zhi')
|
||||
f8AmapImplementation project(':tts:tts-zhi')
|
||||
em4Implementation project(':tts:tts-zhi')
|
||||
e8xxImplementation project(':tts:tts-zhi')
|
||||
fochtaxiImplementation project(':tts:tts-zhi')
|
||||
fochbusImplementation project(':tts:tts-zhi')
|
||||
fPadLenovoOchTaxiImplementation project(':tts:tts-zhi')
|
||||
fPadLenovoOchBusImplementation project(':tts:tts-zhi')
|
||||
phoneImplementation project(':tts:tts-zhi')
|
||||
}
|
||||
}
|
||||
@@ -3,7 +3,7 @@
|
||||
afterEvaluate {
|
||||
|
||||
def independent = ["em3", "em1", "d80x", "d82x", "bydauto", "em2", "phone"]
|
||||
def launcher = ["f80x", "f8xx", "f8amap", "em4", "e8xx", "fochtaxi", "fochbus"]
|
||||
def launcher = ["f80x", "f8xx", "f8amap", "em4", "e8xx", "fochtaxi", "fochbus", "fPadLenovo", "fPadLenovoOchTaxi", "fPadLenovoOchBus"]
|
||||
|
||||
it.getTasks().iterator().forEachRemaining {
|
||||
def task = it
|
||||
|
||||
@@ -16,6 +16,16 @@
|
||||
android:theme="@style/AppTheme.App"
|
||||
android:resizeableActivity="false"
|
||||
tools:replace="android:label">
|
||||
|
||||
<!-- 配置APP ID -->
|
||||
<meta-data
|
||||
android:name="BUGLY_APPID"
|
||||
android:value="f3f8b0b2f1" />
|
||||
<!-- 配置APP渠道号 -->
|
||||
<meta-data
|
||||
android:name="BUGLY_APP_CHANNEL"
|
||||
android:value="${CHANNEL_VALUE}" />
|
||||
|
||||
<meta-data
|
||||
android:name="com.amap.api.v2.apikey"
|
||||
android:value="${AMAP_API_VALUE}" />
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
package com.mogo.launcher;
|
||||
|
||||
import android.content.ComponentName;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.os.Process;
|
||||
import android.text.TextUtils;
|
||||
import android.util.Log;
|
||||
|
||||
import com.alibaba.android.arouter.launcher.ARouter;
|
||||
@@ -32,8 +32,8 @@ import com.mogo.module.v2x.utils.ObuConfig;
|
||||
import com.mogo.service.IMogoServiceApis;
|
||||
import com.mogo.service.MogoServicePaths;
|
||||
import com.mogo.test.crashreport.ITestCrashReportProvider;
|
||||
import com.mogo.test.crashreport.upgrade.UpgradeReportProvider;
|
||||
import com.mogo.utils.ProcessUtils;
|
||||
import com.mogo.utils.UiThreadHandler;
|
||||
import com.mogo.utils.httpdns.HttpSimpleLocation;
|
||||
import com.mogo.utils.logger.LogLevel;
|
||||
import com.mogo.utils.logger.Logger;
|
||||
@@ -115,11 +115,24 @@ public class MogoApplication extends AbsMogoApplication {
|
||||
|
||||
LeakCanary.install(this);
|
||||
|
||||
// 初始化 bugly 升级
|
||||
ARouter.getInstance().navigation(UpgradeReportProvider.class);
|
||||
// debug 下初始化 bugly 上报
|
||||
if (DebugConfig.isDebug()) {
|
||||
ARouter.getInstance().navigation(ITestCrashReportProvider.class);
|
||||
}
|
||||
Log.i("timer", "cost " + (System.currentTimeMillis() - start) + "ms");
|
||||
|
||||
try {
|
||||
if (DebugConfig.getCarMachineType() == DebugConfig.CAR_MACHINE_TYPE_LENOVO) {
|
||||
Intent intent = new Intent();
|
||||
intent.setComponent(new ComponentName("com.zhidao.speech", "com.zhidao.speech.MainActivity"));
|
||||
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
|
||||
startActivity(intent);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -210,13 +223,26 @@ public class MogoApplication extends AbsMogoApplication {
|
||||
clientConfig.setNetMode(MogoHttpDnsConfig.HTTP_DNS_ENV_RELEASE);
|
||||
}
|
||||
// 设置是否是第三APP登录
|
||||
clientConfig.setThirdLogin(false);
|
||||
clientConfig.setThirdLogin(DebugConfig.getCarMachineType() != DebugConfig.CAR_MACHINE_TYPE_SELF_INNOVATE);
|
||||
// 设置是否输出日志
|
||||
clientConfig.setShowDebugLog(true);
|
||||
// 设置是否是直播推流的主播
|
||||
clientConfig.setAnchor(false);
|
||||
// 设置从蘑菇AI开放平台获取的APPKey
|
||||
clientConfig.setThirdPartyAppKey("wbvpzgar");
|
||||
switch (DebugConfig.getCarMachineType()) {
|
||||
// 自研车机
|
||||
case DebugConfig.CAR_MACHINE_TYPE_SELF_INNOVATE:
|
||||
clientConfig.setThirdPartyAppKey("wbvpzgar");
|
||||
break;
|
||||
// 比亚迪
|
||||
case DebugConfig.CAR_MACHINE_TYPE_BYD:
|
||||
clientConfig.setThirdPartyAppKey("bydauto");
|
||||
break;
|
||||
// 衡阳-鹰眼项目
|
||||
case DebugConfig.CAR_MACHINE_TYPE_LENOVO:
|
||||
clientConfig.setThirdPartyAppKey("pfieouqg");
|
||||
break;
|
||||
}
|
||||
// 设置应用服务AppId 长链、鉴权
|
||||
clientConfig.setServiceAppId("com.mogo.launcher");
|
||||
// 设置AI云平台分配给三方应用的签名密钥,需要从AI云平台申请
|
||||
@@ -227,7 +253,6 @@ public class MogoApplication extends AbsMogoApplication {
|
||||
// 设置是否使用MoGoAiCloud SDK内部定位进行实时数据上报
|
||||
clientConfig.setIsUseExternalLocation(true);
|
||||
|
||||
|
||||
// 设置DNS经纬度位置
|
||||
clientConfig.setIHttpDnsCurrentLocation(new IHttpDnsCurrentLocation() {
|
||||
@Override
|
||||
|
||||
@@ -12,8 +12,8 @@ ext {
|
||||
commonIndependentAmapApiValue : "1c3fbc5f5e183619ffb1e7bc01e6751f",
|
||||
compileSdkVersion : 28,
|
||||
buildToolsVersion : "29.0.2",
|
||||
minSdkVersion : 19,
|
||||
targetSdkVersion : 22,
|
||||
minSdkVersion : 22,
|
||||
targetSdkVersion : 23,
|
||||
]
|
||||
dependencies = [
|
||||
// androidx
|
||||
@@ -204,6 +204,7 @@ ext {
|
||||
crashreport : "com.mogo.test:crashreport:${CRASHREPORT_VERSION}",
|
||||
crashreportbugly : "com.mogo.test:crashreport-bugly:${CRASHREPORT_BUGLY_VERSION}",
|
||||
crashreportnoop : "com.mogo.test:crashreport-noop:${CRASHREPORT_NOOP_VERSION}",
|
||||
crashreportupgrade : "com.mogo.test:crashreport-noop:${CRASHREPORT_UPGRADE_VERSION}",
|
||||
|
||||
|
||||
skinsupportbase : "com.mogo.skin:skin-support-base:${SKIN_SUPPORT_VERSION}",
|
||||
|
||||
@@ -43,6 +43,7 @@ dependencies {
|
||||
implementation rootProject.ext.dependencies.rxjava
|
||||
implementation rootProject.ext.dependencies.accountsdk
|
||||
api rootProject.ext.dependencies.mogoaicloudrealtime
|
||||
implementation rootProject.ext.dependencies.amapnavi3dmap
|
||||
|
||||
if (Boolean.valueOf(RELEASE)) {
|
||||
implementation rootProject.ext.dependencies.mogoutils
|
||||
|
||||
@@ -11,6 +11,8 @@ import android.widget.ImageView;
|
||||
import android.widget.TextView;
|
||||
|
||||
import com.alibaba.android.arouter.launcher.ARouter;
|
||||
import com.amap.api.navi.AMapNaviView;
|
||||
import com.android.internal.policy.MyPhoneLayoutInflater;
|
||||
import com.mogo.commons.analytics.AnalyticsUtils;
|
||||
import com.mogo.commons.debug.DebugConfig;
|
||||
import com.mogo.commons.device.Devices;
|
||||
@@ -59,9 +61,17 @@ public abstract class AbsMogoApplication extends Application {
|
||||
return sApp;
|
||||
}
|
||||
|
||||
public static AMapNaviView aMapNaviView;
|
||||
|
||||
public static AMapNaviView getMapNaviView() {
|
||||
return aMapNaviView;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCreate() {
|
||||
super.onCreate();
|
||||
aMapNaviView = new AMapNaviView(this);
|
||||
aMapNaviView.onCreate(null);
|
||||
// 在设置皮肤布局填充器之前进行克隆一个出来
|
||||
mLayoutInflaterNoSkin = LayoutInflater.from(new ContextThemeWrapper(this, R.style.Theme_AppCompat)).cloneInContext(new ContextThemeWrapper(this, R.style.Theme_AppCompat));
|
||||
sApp = this;
|
||||
|
||||
@@ -79,6 +79,11 @@ public class DebugConfig {
|
||||
*/
|
||||
public static final int CAR_MACHINE_TYPE_BYD = 1;
|
||||
|
||||
/**
|
||||
* 联想PAD
|
||||
*/
|
||||
public static final int CAR_MACHINE_TYPE_LENOVO = 2;
|
||||
|
||||
private static int sCarMachineType = CAR_MACHINE_TYPE_SELF_INNOVATE;
|
||||
|
||||
/**
|
||||
@@ -471,10 +476,10 @@ public class DebugConfig {
|
||||
return result;
|
||||
}
|
||||
|
||||
public synchronized static String getStatusData(int type){
|
||||
if(type > 4){
|
||||
public synchronized static String getStatusData(int type) {
|
||||
if (type > 4) {
|
||||
return sStatus[type].toString();
|
||||
}else{
|
||||
} else {
|
||||
return "0";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,8 +1,10 @@
|
||||
package com.mogo.commons.mvp;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.Build;
|
||||
import android.os.Bundle;
|
||||
import android.view.MotionEvent;
|
||||
import android.view.View;
|
||||
import android.view.Window;
|
||||
import android.view.WindowManager;
|
||||
|
||||
@@ -40,6 +42,24 @@ public abstract class MvpActivity< V extends IView, P extends Presenter< V > >
|
||||
getLifecycle().addObserver( mPresenter );
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onResume() {
|
||||
super.onResume();
|
||||
hideBottomUIMenu();
|
||||
}
|
||||
|
||||
//隐藏导航栏
|
||||
protected void hideBottomUIMenu() {
|
||||
//隐藏虚拟按键
|
||||
if (Build.VERSION.SDK_INT >= 19) {
|
||||
//for new api versions.
|
||||
View decorView = getWindow().getDecorView();
|
||||
int uiOptions = View.SYSTEM_UI_FLAG_HIDE_NAVIGATION
|
||||
| View.SYSTEM_UI_FLAG_IMMERSIVE_STICKY ;
|
||||
decorView.setSystemUiVisibility(uiOptions);
|
||||
}
|
||||
}
|
||||
|
||||
protected void beforeSetContentView(Bundle savedInstanceState){
|
||||
|
||||
}
|
||||
|
||||
@@ -2,17 +2,15 @@ package com.mogo.commons.network;
|
||||
|
||||
import android.Manifest;
|
||||
import android.content.Context;
|
||||
import android.content.SharedPreferences;
|
||||
import android.content.pm.PackageManager;
|
||||
import android.telephony.CellLocation;
|
||||
import android.telephony.TelephonyManager;
|
||||
import android.telephony.cdma.CdmaCellLocation;
|
||||
import android.telephony.gsm.GsmCellLocation;
|
||||
import android.text.TextUtils;
|
||||
|
||||
import com.mogo.commons.AbsMogoApplication;
|
||||
import com.mogo.commons.debug.DebugConfig;
|
||||
import com.mogo.utils.storage.SharedPrefsMgr;
|
||||
import com.mogo.utils.DeviceIdUtils;
|
||||
|
||||
import java.lang.reflect.InvocationTargetException;
|
||||
import java.lang.reflect.Method;
|
||||
@@ -66,9 +64,8 @@ public class Utils {
|
||||
public static final String PROPERTIES = "android.os.SystemProperties";
|
||||
|
||||
public static String getSn() {
|
||||
|
||||
if ( DebugConfig.getCarMachineType() != DebugConfig.CAR_MACHINE_TYPE_SELF_INNOVATE ) {
|
||||
return SharedPrefsMgr.getInstance( AbsMogoApplication.getApp() ).getString( "allocated_sn" );
|
||||
return DeviceIdUtils.getDeviceId(AbsMogoApplication.getApp());
|
||||
}
|
||||
return getSystemProperties( GSM_SERIAL );
|
||||
}
|
||||
|
||||
@@ -83,4 +83,37 @@ public class ColorUtils {
|
||||
return gradientColorArr;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取一组渐变色数组
|
||||
*
|
||||
* @param startColor 开始颜色
|
||||
* @param endColor 结束颜色
|
||||
* @param step 步长
|
||||
* @return 生成的梯度颜色集合
|
||||
*/
|
||||
public static List<Integer> getGradientAlpha(String startColor, String centerColor, String endColor, int step) {
|
||||
// 将HEX转为RGB
|
||||
int[] sColor = hexToArgb(startColor);
|
||||
int[] cColor = hexToArgb(centerColor);
|
||||
int[] eColor = hexToArgb(endColor);
|
||||
|
||||
// 生成渐变色
|
||||
List<Integer> gradientColorArr = new ArrayList<>();
|
||||
|
||||
if (step >= 3) {
|
||||
// 开始颜色
|
||||
gradientColorArr.add(Color.argb(sColor[0], sColor[1], sColor[2], sColor[3]));
|
||||
// 中间颜色
|
||||
for (int i = 0; i < (step - 2); i++) {
|
||||
gradientColorArr.add(Color.argb(cColor[0], cColor[1], cColor[2], cColor[3]));
|
||||
}
|
||||
//结束颜色
|
||||
gradientColorArr.add(Color.argb(eColor[0], eColor[1], eColor[2], eColor[3]));
|
||||
} else {
|
||||
gradientColorArr.add(Color.argb(cColor[0], cColor[1], cColor[2], cColor[3]));
|
||||
}
|
||||
|
||||
return gradientColorArr;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -122,6 +122,7 @@ MOGO_MODULE_MONITOR_VERSION=2.0.12
|
||||
CRASHREPORT_VERSION=2.0.12
|
||||
CRASHREPORT_BUGLY_VERSION=2.0.12
|
||||
CRASHREPORT_NOOP_VERSION=2.0.12
|
||||
CRASHREPORT_UPGRADE_VERSION=2.0.12
|
||||
## tts
|
||||
TTS_BASE_VERSION=2.0.12
|
||||
TTS_DI_VERSION=2.0.12
|
||||
@@ -145,7 +146,7 @@ MOGO_OCH_TAXI_VERSION=1.0.0
|
||||
|
||||
######## 外部依赖引用
|
||||
# 车聊聊
|
||||
CARCHATTING_VERSION=2.2.320
|
||||
CARCHATTING_VERSION=2.2.325
|
||||
# 车聊聊接口
|
||||
CARCHATTINGPROVIDER_VERSION=1.1.11
|
||||
# websocket
|
||||
|
||||
@@ -50,6 +50,7 @@ import com.mogo.map.uicontroller.EnumMapUI;
|
||||
import com.mogo.map.uicontroller.IMogoMapUIController;
|
||||
import com.mogo.map.uicontroller.MapCameraPosition;
|
||||
import com.mogo.map.uicontroller.MapControlResult;
|
||||
import com.mogo.map.uicontroller.VisualAngleMode;
|
||||
import com.mogo.realtime.entity.ADASRecognizedResult;
|
||||
import com.mogo.utils.WindowUtils;
|
||||
import com.mogo.utils.logger.Logger;
|
||||
@@ -479,6 +480,16 @@ public class AMapNaviViewWrapper implements IMogoMapView,
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void changeMapVisualAngle(VisualAngleMode angelMode) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public VisualAngleMode getCurrentMapVisualAngle() {
|
||||
return null;
|
||||
}
|
||||
|
||||
private void setUIMode( EnumMapUI ui, AMapNaviViewOptions options ) {
|
||||
this.mCurrentUIMode = ui;
|
||||
switch ( ui ) {
|
||||
|
||||
@@ -8,7 +8,6 @@ import android.location.Location;
|
||||
import android.os.Bundle;
|
||||
import android.os.SystemClock;
|
||||
import android.os.Trace;
|
||||
import android.util.Log;
|
||||
import android.view.MotionEvent;
|
||||
import android.view.View;
|
||||
import android.view.animation.Interpolator;
|
||||
@@ -28,7 +27,6 @@ import com.amap.api.maps.model.Polyline;
|
||||
import com.amap.api.maps.model.animation.Animation;
|
||||
import com.amap.api.maps.model.animation.TranslateAnimation;
|
||||
import com.amap.api.navi.model.NaviInfo;
|
||||
import com.mogo.commons.debug.DebugConfig;
|
||||
import com.mogo.map.IMogoMap;
|
||||
import com.mogo.map.IMogoMapView;
|
||||
import com.mogo.map.MogoLatLng;
|
||||
@@ -47,6 +45,7 @@ import com.mogo.map.uicontroller.EnumMapUI;
|
||||
import com.mogo.map.uicontroller.IMogoMapUIController;
|
||||
import com.mogo.map.uicontroller.MapCameraPosition;
|
||||
import com.mogo.map.uicontroller.MapControlResult;
|
||||
import com.mogo.map.uicontroller.VisualAngleMode;
|
||||
import com.mogo.realtime.entity.ADASRecognizedResult;
|
||||
import com.mogo.utils.NetworkUtils;
|
||||
import com.mogo.utils.WindowUtils;
|
||||
@@ -384,6 +383,16 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void changeMapVisualAngle(VisualAngleMode angelMode) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public VisualAngleMode getCurrentMapVisualAngle() {
|
||||
return null;
|
||||
}
|
||||
|
||||
private boolean checkMapView() {
|
||||
if ( mMapView == null || mMapView.getMap() == null ) {
|
||||
Logger.e( TAG, "高德mapView实例为空,请检查" );
|
||||
|
||||
@@ -7,13 +7,13 @@ import android.view.View;
|
||||
import android.view.animation.Interpolator;
|
||||
|
||||
import com.mogo.map.MogoLatLng;
|
||||
import com.mogo.map.MogoMap;
|
||||
import com.mogo.map.marker.IMogoMarker;
|
||||
import com.mogo.map.uicontroller.CarCursorOption;
|
||||
import com.mogo.map.uicontroller.EnumMapUI;
|
||||
import com.mogo.map.uicontroller.IMogoMapUIController;
|
||||
import com.mogo.map.uicontroller.MapCameraPosition;
|
||||
import com.mogo.map.uicontroller.MapControlResult;
|
||||
import com.mogo.map.uicontroller.VisualAngleMode;
|
||||
import com.mogo.realtime.entity.ADASRecognizedResult;
|
||||
import com.mogo.utils.logger.Logger;
|
||||
|
||||
@@ -92,6 +92,16 @@ public class AMapUIController implements IMogoMapUIController {
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void changeMapVisualAngle(VisualAngleMode angelMode) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public VisualAngleMode getCurrentMapVisualAngle() {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void moveToCenter(MogoLatLng latLng, boolean animate) {
|
||||
if (mClient != null) {
|
||||
|
||||
@@ -67,7 +67,7 @@ dependencies {
|
||||
implementation project(':foudations:mogo-commons')
|
||||
}
|
||||
|
||||
implementation 'com.zhidaoauto.machine:map:1.0.0-vr-8.5.29'
|
||||
implementation 'com.zhidaoauto.machine:map:1.0.0-vr-8.5.31'
|
||||
// implementation 'com.zhidaoauto.machine:map:1.0.0-vr-test-3.4'
|
||||
}
|
||||
|
||||
|
||||
@@ -17,6 +17,7 @@ import android.view.animation.Interpolator;
|
||||
import android.widget.TextView;
|
||||
|
||||
import com.mogo.commons.debug.DebugConfig;
|
||||
import com.mogo.commons.voice.AIAssist;
|
||||
import com.mogo.map.IMogoMap;
|
||||
import com.mogo.map.IMogoMapView;
|
||||
import com.mogo.map.MogoLatLng;
|
||||
@@ -33,12 +34,11 @@ import com.mogo.map.uicontroller.EnumMapUI;
|
||||
import com.mogo.map.uicontroller.IMogoMapUIController;
|
||||
import com.mogo.map.uicontroller.MapCameraPosition;
|
||||
import com.mogo.map.uicontroller.MapControlResult;
|
||||
import com.mogo.map.uicontroller.VisualAngleMode;
|
||||
import com.mogo.realtime.entity.ADASRecognizedResult;
|
||||
import com.mogo.utils.TipToast;
|
||||
import com.mogo.utils.UiThreadHandler;
|
||||
import com.mogo.utils.WorkThreadHandler;
|
||||
import com.mogo.utils.logger.Logger;
|
||||
import com.mogo.utils.network.utils.GsonUtil;
|
||||
import com.zhidaoauto.map.sdk.open.MapAutoApi;
|
||||
import com.zhidaoauto.map.sdk.open.abs.MapStatusListener;
|
||||
import com.zhidaoauto.map.sdk.open.abs.OnCameraChangeListener;
|
||||
@@ -46,6 +46,7 @@ import com.zhidaoauto.map.sdk.open.abs.OnMapClickListener;
|
||||
import com.zhidaoauto.map.sdk.open.abs.OnMapLoadedListener;
|
||||
import com.zhidaoauto.map.sdk.open.abs.OnMapStyleListener;
|
||||
import com.zhidaoauto.map.sdk.open.abs.OnMapTouchListener;
|
||||
import com.zhidaoauto.map.sdk.open.abs.OnMapViewVisualAngleChangeListener;
|
||||
import com.zhidaoauto.map.sdk.open.camera.CameraPosition;
|
||||
import com.zhidaoauto.map.sdk.open.camera.CameraUpdateFactory;
|
||||
import com.zhidaoauto.map.sdk.open.camera.LatLngBounds;
|
||||
@@ -70,6 +71,10 @@ import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.concurrent.ConcurrentHashMap;
|
||||
|
||||
import static com.mogo.map.uicontroller.VisualAngleMode.MODE_CLOSE_SIGHT;
|
||||
import static com.mogo.map.uicontroller.VisualAngleMode.MODE_LONG_SIGHT;
|
||||
import static com.mogo.map.uicontroller.VisualAngleMode.MODE_MEDIUM_SIGHT;
|
||||
|
||||
public class AMapViewWrapper implements IMogoMapView,
|
||||
IMogoMapUIController,
|
||||
LocationListener,
|
||||
@@ -80,28 +85,26 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
OnMapTouchListener,
|
||||
OnMarkClickListener,
|
||||
OnMapStyleListener,
|
||||
MapStyleController.IMapStyleAutoChangedListener {
|
||||
MapStyleController.IMapStyleAutoChangedListener, OnMapViewVisualAngleChangeListener {
|
||||
|
||||
private static final String TAG = "AMapViewWrapper";
|
||||
private final MapAutoView mMapView;
|
||||
private IMogoMap mIMap;
|
||||
|
||||
private final IMogoMap mIMap;
|
||||
private AMapMarkerClickHandler mMarkerClickHandler;
|
||||
private EnumMapUI mCurrentCarUIMode;
|
||||
|
||||
private boolean mIsCarLocked = false;
|
||||
private int mLockZoom = 16;
|
||||
private long startTime;
|
||||
|
||||
private float mDefaultZoomLevel = 16.0f;
|
||||
private final CarCursorOption DEFAULT_OPTION = new CarCursorOption.Builder()
|
||||
.carCursorRes(R.drawable.map_api_ic_current_location2)
|
||||
.naviCursorRes(R.drawable.ic_amap_navi_cursor)
|
||||
.build();
|
||||
private CarCursorOption mCarCursorOption = DEFAULT_OPTION;
|
||||
|
||||
private Location mLastDriveLocationShadow = null;
|
||||
private EnumMapUI mCurrentCarUIMode;
|
||||
private EnumMapUI mCurrentUI;
|
||||
private VisualAngleMode mVisualAngleMode = MODE_MEDIUM_SIGHT;
|
||||
|
||||
private int mLockZoom = 16;
|
||||
private long startTime;
|
||||
private float mDefaultZoomLevel = 16.0f;
|
||||
private boolean mIsCarLocked = false;
|
||||
private boolean mIsLightStyle = false;
|
||||
private boolean mMapLoaded = false;
|
||||
private boolean mIsFirstLocated = true;
|
||||
@@ -206,6 +209,7 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
mMapView.registerListener(this, MapAutoApi.LISTENER_TYPE_3D);
|
||||
mMapView.setOnCameraChangeListener(this);
|
||||
mMapView.setOnMapStyleListener(this);
|
||||
mMapView.setOnMapViewVisualAngleChangeListener(this);
|
||||
Logger.d(TAG, "styleop - initListeners - setOnMapStyleListener - view %s", mMapView);
|
||||
|
||||
// mMapView.setOnPolylineClickListener( this );
|
||||
@@ -371,6 +375,21 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void changeMapVisualAngle(VisualAngleMode angelMode) {
|
||||
MapAutoViewHelper mapAutoViewHelper = mMapView.getMapAutoViewHelper();
|
||||
if (mapAutoViewHelper != null) {
|
||||
Logger.d(TAG," 用户更改视距 currentThread : " + Thread.currentThread().getName());
|
||||
mVisualAngleMode = angelMode;
|
||||
mapAutoViewHelper.setMapViewVisualAngle(angelMode.getCode());
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public VisualAngleMode getCurrentMapVisualAngle() {
|
||||
return mVisualAngleMode;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void moveToCenter(MogoLatLng latLng) {
|
||||
moveToCenter(latLng, true);
|
||||
@@ -404,9 +423,6 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
|
||||
@Override
|
||||
public void moveToCenter(MogoLatLng latLng, boolean animate) {
|
||||
if (mCurrentUI == EnumMapUI.Type_VR) {
|
||||
return;
|
||||
}
|
||||
Logger.d(TAG, "move to center %s", latLng);
|
||||
if (latLng == null || latLng.lat == 0.0d || latLng.lng == 0.0d) {
|
||||
Logger.e(TAG, "latlng = null or is illegal");
|
||||
@@ -703,8 +719,6 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
} else {
|
||||
if (mCarCursorOption.getCarCursorRes() != 0) {
|
||||
style.myLocationIcon(mCarCursorOption.getCarCursorRes());
|
||||
} else {
|
||||
style.myLocationIcon(mCarCursorOption.getCarCursorRes());
|
||||
}
|
||||
}
|
||||
mMapView.getMapAutoViewHelper().setMyLocationStyle(style);
|
||||
@@ -728,7 +742,7 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
|
||||
@Override
|
||||
public long getTileId(double lon, double lat) {
|
||||
return getMap().getUIController().getTileId(lon,lat);
|
||||
return getMap().getUIController().getTileId(lon, lat);
|
||||
}
|
||||
|
||||
private boolean isShowWarn;
|
||||
@@ -752,7 +766,7 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
if (!mIsDelayed) {
|
||||
mIsDelayed = true;
|
||||
UiThreadHandler.postDelayed(() -> {
|
||||
Logger.d(TAG, "倒计时结束");
|
||||
//Logger.d(TAG, "倒计时结束");
|
||||
mIsFirstLocated = false;
|
||||
}, 5_000L);
|
||||
}
|
||||
@@ -788,6 +802,14 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
// } else {
|
||||
//// mSelfMarker.marker3DIcon(R.raw.car);
|
||||
// }
|
||||
|
||||
// UiThreadHandler.postDelayed( () -> {
|
||||
// if (!isShowWarn) {
|
||||
// mSelfMarker.marker3DIcon(R.raw.qfpz);
|
||||
// isShowWarn = true;
|
||||
// }
|
||||
// }, 6_000L );
|
||||
|
||||
}
|
||||
|
||||
showSelfSpeed(location.getSpeed());
|
||||
@@ -860,7 +882,7 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
@Override
|
||||
public void onMapLoaded() {
|
||||
Logger.i(TAG, "autoop--onMapLoaded: ");
|
||||
mMapView.getMapAutoViewHelper().setRenderFrequency(true,50);
|
||||
mMapView.getMapAutoViewHelper().setRenderFrequency(true, 50);
|
||||
MogoMapListenerHandler.getInstance().onMapLoaded();
|
||||
mMapLoaded = true;
|
||||
CameraPosition cameraPosition = mMapView.getMapAutoViewHelper().getCameraPosition();
|
||||
@@ -897,6 +919,26 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
// Logger.i( TAG, "mapop--onMapStatusChanged-: " + type + "," + value );
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onMapViewVisualAngleChange(int i) {
|
||||
Logger.d(TAG," 地图自动更改视距 currentThread : " + Thread.currentThread().getName());
|
||||
mVisualAngleMode = getVisualAngleMode(i);
|
||||
MogoMapListenerHandler.getInstance().onMapVisualAngleChanged(mVisualAngleMode);
|
||||
}
|
||||
|
||||
private VisualAngleMode getVisualAngleMode(int mode) {
|
||||
switch (mode) {
|
||||
case 0:
|
||||
return MODE_CLOSE_SIGHT;
|
||||
case 1:
|
||||
return MODE_MEDIUM_SIGHT;
|
||||
case 2:
|
||||
return MODE_LONG_SIGHT;
|
||||
default:
|
||||
throw new IllegalStateException("mode is unCorrect");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onCameraChange(int type, int value) {
|
||||
// Logger.i( TAG, "mapop--onCameraChange-: " + type + "," + value );
|
||||
@@ -1032,7 +1074,6 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
}
|
||||
}
|
||||
|
||||
//TODO
|
||||
@Override
|
||||
public void syncLocation2Map(JSONObject data) {
|
||||
if (!checkAMapView()) {
|
||||
@@ -1193,4 +1234,5 @@ public class AMapViewWrapper implements IMogoMapView,
|
||||
public void setMarkerInfoResName(String speedVal, String val) {
|
||||
ResIdCache.putVal(speedVal, val);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -95,7 +95,7 @@ class CustomMapApiBuilder implements IMogoMapApiBuilder {
|
||||
public IMogoMapView getMapView( Context context ) {
|
||||
Log.d(TAG,"setDebugMode==true");
|
||||
NavAutoApi.INSTANCE.init( context, MapParams.Companion.init()
|
||||
.setDebugMode( true )
|
||||
.setDebugMode( false )
|
||||
.setCoordinateType( MapParams.COORDINATETYPE_GCJ02 )
|
||||
.setPerspectiveMode( MapParams.MAP_PERSPECTIVE_2D )
|
||||
.setZoom( 20 )
|
||||
|
||||
@@ -13,6 +13,7 @@ import com.mogo.map.uicontroller.EnumMapUI;
|
||||
import com.mogo.map.uicontroller.IMogoMapUIController;
|
||||
import com.mogo.map.uicontroller.MapCameraPosition;
|
||||
import com.mogo.map.uicontroller.MapControlResult;
|
||||
import com.mogo.map.uicontroller.VisualAngleMode;
|
||||
import com.mogo.realtime.entity.ADASRecognizedResult;
|
||||
import com.zhidaoauto.map.sdk.open.MapAutoApi;
|
||||
|
||||
@@ -38,9 +39,9 @@ public class AMapUIController implements IMogoMapUIController {
|
||||
}
|
||||
|
||||
public static AMapUIController getInstance() {
|
||||
if ( sInstance == null ) {
|
||||
synchronized ( AMapUIController.class ) {
|
||||
if ( sInstance == null ) {
|
||||
if (sInstance == null) {
|
||||
synchronized (AMapUIController.class) {
|
||||
if (sInstance == null) {
|
||||
sInstance = new AMapUIController();
|
||||
}
|
||||
}
|
||||
@@ -48,7 +49,7 @@ public class AMapUIController implements IMogoMapUIController {
|
||||
return sInstance;
|
||||
}
|
||||
|
||||
public void initClient( IMogoMapUIController client ) {
|
||||
public void initClient(IMogoMapUIController client) {
|
||||
this.mClient = client;
|
||||
}
|
||||
|
||||
@@ -57,87 +58,102 @@ public class AMapUIController implements IMogoMapUIController {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setTrafficEnabled( boolean visible ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.setTrafficEnabled( visible );
|
||||
public void setTrafficEnabled(boolean visible) {
|
||||
if (mClient != null) {
|
||||
mClient.setTrafficEnabled(visible);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public MapControlResult changeZoom( boolean zoom ) {
|
||||
if ( mClient != null ) {
|
||||
return mClient.changeZoom( zoom );
|
||||
public MapControlResult changeZoom(boolean zoom) {
|
||||
if (mClient != null) {
|
||||
return mClient.changeZoom(zoom);
|
||||
}
|
||||
return MapControlResult.ERROR;
|
||||
}
|
||||
|
||||
@Override
|
||||
public MapControlResult changeZoom( float zoom ) {
|
||||
if ( mClient != null ) {
|
||||
return mClient.changeZoom( zoom );
|
||||
public MapControlResult changeZoom(float zoom) {
|
||||
if (mClient != null) {
|
||||
return mClient.changeZoom(zoom);
|
||||
}
|
||||
return MapControlResult.ERROR;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void changeMapMode( EnumMapUI mode ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.changeMapMode( mode );
|
||||
public void changeMapMode(EnumMapUI mode) {
|
||||
if (mClient != null) {
|
||||
mClient.changeMapMode(mode);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void moveToCenter( MogoLatLng latLng, boolean animate ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.moveToCenter( latLng, animate );
|
||||
public void changeMapVisualAngle(VisualAngleMode angelMode) {
|
||||
if (mClient != null) {
|
||||
mClient.changeMapVisualAngle(angelMode);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void showMyLocation( boolean visible ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.showMyLocation( visible );
|
||||
public VisualAngleMode getCurrentMapVisualAngle() {
|
||||
if (mClient != null) {
|
||||
return mClient.getCurrentMapVisualAngle();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void moveToCenter(MogoLatLng latLng, boolean animate) {
|
||||
if (mClient != null) {
|
||||
mClient.moveToCenter(latLng, animate);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void showMyLocation( View view ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.showMyLocation( view );
|
||||
public void showMyLocation(boolean visible) {
|
||||
if (mClient != null) {
|
||||
mClient.showMyLocation(visible);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void showMyLocation(View view) {
|
||||
if (mClient != null) {
|
||||
mClient.showMyLocation(view);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void recoverLockMode() {
|
||||
if ( mClient != null ) {
|
||||
if (mClient != null) {
|
||||
mClient.recoverLockMode();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void loseLockMode() {
|
||||
if ( mClient != null ) {
|
||||
if (mClient != null) {
|
||||
mClient.loseLockMode();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setLockZoom( int var1 ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.setLockZoom( var1 );
|
||||
public void setLockZoom(int var1) {
|
||||
if (mClient != null) {
|
||||
mClient.setLockZoom(var1);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void displayOverview( Rect bounds ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.displayOverview( bounds );
|
||||
public void displayOverview(Rect bounds) {
|
||||
if (mClient != null) {
|
||||
mClient.displayOverview(bounds);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public float getScalePerPixel() {
|
||||
if ( mClient != null ) {
|
||||
if (mClient != null) {
|
||||
return mClient.getScalePerPixel();
|
||||
}
|
||||
return 0;
|
||||
@@ -145,7 +161,7 @@ public class AMapUIController implements IMogoMapUIController {
|
||||
|
||||
@Override
|
||||
public float getZoomLevel() {
|
||||
if ( mClient != null ) {
|
||||
if (mClient != null) {
|
||||
return mClient.getZoomLevel();
|
||||
}
|
||||
return 0;
|
||||
@@ -153,15 +169,15 @@ public class AMapUIController implements IMogoMapUIController {
|
||||
|
||||
@Override
|
||||
public float getRoadWidth(double lon, double lat, float angle, boolean isGpsLocation, boolean isRTK) {
|
||||
if ( mClient != null ) {
|
||||
return mClient.getRoadWidth(lon,lat,angle,isGpsLocation,isRTK);
|
||||
if (mClient != null) {
|
||||
return mClient.getRoadWidth(lon, lat, angle, isGpsLocation, isRTK);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public MogoLatLng getCameraNorthEastPosition() {
|
||||
if ( mClient != null ) {
|
||||
if (mClient != null) {
|
||||
return mClient.getCameraNorthEastPosition();
|
||||
}
|
||||
return null;
|
||||
@@ -169,7 +185,7 @@ public class AMapUIController implements IMogoMapUIController {
|
||||
|
||||
@Override
|
||||
public MogoLatLng getCameraSouthWestPosition() {
|
||||
if ( mClient != null ) {
|
||||
if (mClient != null) {
|
||||
return mClient.getCameraSouthWestPosition();
|
||||
}
|
||||
return null;
|
||||
@@ -177,124 +193,124 @@ public class AMapUIController implements IMogoMapUIController {
|
||||
|
||||
@Override
|
||||
public MogoLatLng getWindowCenterLocation() {
|
||||
if ( mClient != null ) {
|
||||
if (mClient != null) {
|
||||
return mClient.getWindowCenterLocation();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setPointToCenter( double mapCenterX, double mapCenterY ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.setPointToCenter( mapCenterX, mapCenterY );
|
||||
public void setPointToCenter(double mapCenterX, double mapCenterY) {
|
||||
if (mClient != null) {
|
||||
mClient.setPointToCenter(mapCenterX, mapCenterY);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public Point getLocationPointInScreen( MogoLatLng latLng ) {
|
||||
if ( mClient != null ) {
|
||||
return mClient.getLocationPointInScreen( latLng );
|
||||
public Point getLocationPointInScreen(MogoLatLng latLng) {
|
||||
if (mClient != null) {
|
||||
return mClient.getLocationPointInScreen(latLng);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public MogoLatLng getLocationMogoLatLngInScreen( Point point ) {
|
||||
if ( mClient != null ) {
|
||||
return mClient.getLocationMogoLatLngInScreen( point );
|
||||
public MogoLatLng getLocationMogoLatLngInScreen(Point point) {
|
||||
if (mClient != null) {
|
||||
return mClient.getLocationMogoLatLngInScreen(point);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void startJumpAnimation( IMogoMarker marker, float high, Interpolator interpolator,
|
||||
long duration ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.startJumpAnimation( marker, high, interpolator, duration );
|
||||
public void startJumpAnimation(IMogoMarker marker, float high, Interpolator interpolator,
|
||||
long duration) {
|
||||
if (mClient != null) {
|
||||
mClient.startJumpAnimation(marker, high, interpolator, duration);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setRenderFps( int fps ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.setRenderFps( fps );
|
||||
public void setRenderFps(int fps) {
|
||||
if (mClient != null) {
|
||||
mClient.setRenderFps(fps);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void showBounds( String tag, MogoLatLng carPosition, List< MogoLatLng > lonLats, Rect bound, boolean lockCarPosition ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.showBounds( tag, carPosition, lonLats, bound, lockCarPosition );
|
||||
public void showBounds(String tag, MogoLatLng carPosition, List<MogoLatLng> lonLats, Rect bound, boolean lockCarPosition) {
|
||||
if (mClient != null) {
|
||||
mClient.showBounds(tag, carPosition, lonLats, bound, lockCarPosition);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void forceRender() {
|
||||
if ( mClient != null ) {
|
||||
if (mClient != null) {
|
||||
mClient.forceRender();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public float calculateLineDistance( MogoLatLng p1, MogoLatLng p2 ) throws Exception {
|
||||
if ( mClient != null ) {
|
||||
return mClient.calculateLineDistance( p1, p2 );
|
||||
public float calculateLineDistance(MogoLatLng p1, MogoLatLng p2) throws Exception {
|
||||
if (mClient != null) {
|
||||
return mClient.calculateLineDistance(p1, p2);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
public EnumMapUI getCurrentUiMode() {
|
||||
if ( mClient != null ) {
|
||||
if (mClient != null) {
|
||||
return mClient.getCurrentUiMode();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void changeMyLocation( Location location ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.changeMyLocation( location );
|
||||
public void changeMyLocation(Location location) {
|
||||
if (mClient != null) {
|
||||
mClient.changeMyLocation(location);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isCarLocked() {
|
||||
if ( mClient != null ) {
|
||||
if (mClient != null) {
|
||||
return mClient.isCarLocked();
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setCarCursorOption( CarCursorOption option ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.setCarCursorOption( option );
|
||||
public void setCarCursorOption(CarCursorOption option) {
|
||||
if (mClient != null) {
|
||||
mClient.setCarCursorOption(option);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public MapCameraPosition getMapCameraPosition() {
|
||||
if ( mClient != null ) {
|
||||
if (mClient != null) {
|
||||
return mClient.getMapCameraPosition();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void changeBearing( float bearing ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.changeBearing( bearing );
|
||||
public void changeBearing(float bearing) {
|
||||
if (mClient != null) {
|
||||
mClient.changeBearing(bearing);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public long getTileId(double lon, double lat) {
|
||||
return MapAutoApi.INSTANCE.getTileID(lon,lat,13); // 13为默认获取瓦片层级级别
|
||||
return MapAutoApi.INSTANCE.getTileID(lon, lat, 13); // 13为默认获取瓦片层级级别
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setAnchorScale( float x, float y ) {
|
||||
public void setAnchorScale(float x, float y) {
|
||||
|
||||
}
|
||||
|
||||
@@ -304,51 +320,51 @@ public class AMapUIController implements IMogoMapUIController {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setAnchorRate( float rate ) {
|
||||
public void setAnchorRate(float rate) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void rtkEnable( boolean enable ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.rtkEnable( enable );
|
||||
public void rtkEnable(boolean enable) {
|
||||
if (mClient != null) {
|
||||
mClient.rtkEnable(enable);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void syncLocation2Map( JSONObject data ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.syncLocation2Map( data );
|
||||
public void syncLocation2Map(JSONObject data) {
|
||||
if (mClient != null) {
|
||||
mClient.syncLocation2Map(data);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void openVrMode( boolean zoomGestureEnable ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.openVrMode( zoomGestureEnable );
|
||||
public void openVrMode(boolean zoomGestureEnable) {
|
||||
if (mClient != null) {
|
||||
mClient.openVrMode(zoomGestureEnable);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public double[] matchRoad( String id, double lon, double lat, double angle, boolean isGpsLocation, boolean isRTK ) {
|
||||
if ( mClient != null ) {
|
||||
return mClient.matchRoad( id, lon, lat, angle, isGpsLocation, isRTK );
|
||||
public double[] matchRoad(String id, double lon, double lat, double angle, boolean isGpsLocation, boolean isRTK) {
|
||||
if (mClient != null) {
|
||||
return mClient.matchRoad(id, lon, lat, angle, isGpsLocation, isRTK);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getMarkerInfoResName( String speedVal ) {
|
||||
if ( mClient != null ) {
|
||||
return mClient.getMarkerInfoResName( speedVal );
|
||||
public String getMarkerInfoResName(String speedVal) {
|
||||
if (mClient != null) {
|
||||
return mClient.getMarkerInfoResName(speedVal);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setMarkerInfoResName( String speedVal, String val ) {
|
||||
if ( mClient != null ) {
|
||||
mClient.setMarkerInfoResName( speedVal, val );
|
||||
public void setMarkerInfoResName(String speedVal, String val) {
|
||||
if (mClient != null) {
|
||||
mClient.setMarkerInfoResName(speedVal, val);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -3,9 +3,9 @@ package com.mogo.map.listener;
|
||||
import android.view.MotionEvent;
|
||||
|
||||
import com.mogo.map.MogoLatLng;
|
||||
import com.mogo.map.location.MogoLocation;
|
||||
import com.mogo.map.model.MogoPoi;
|
||||
import com.mogo.map.uicontroller.EnumMapUI;
|
||||
import com.mogo.map.uicontroller.VisualAngleMode;
|
||||
|
||||
/**
|
||||
* @author congtaowang
|
||||
@@ -18,42 +18,56 @@ public interface IMogoMapListener {
|
||||
/**
|
||||
* 地图加载完毕
|
||||
*/
|
||||
default void onMapLoaded(){};
|
||||
default void onMapLoaded() {
|
||||
}
|
||||
|
||||
/**
|
||||
* 地图点击
|
||||
*
|
||||
* @param motionEvent
|
||||
*/
|
||||
default void onTouch( MotionEvent motionEvent ){};
|
||||
default void onTouch(MotionEvent motionEvent) {
|
||||
}
|
||||
|
||||
/**
|
||||
* 地图上的任意poi点击
|
||||
*
|
||||
* @param poi
|
||||
*/
|
||||
default void onPOIClick( MogoPoi poi ){};
|
||||
default void onPOIClick(MogoPoi poi) {
|
||||
}
|
||||
|
||||
/**
|
||||
* 地图点击
|
||||
*
|
||||
* @param latLng
|
||||
*/
|
||||
default void onMapClick( MogoLatLng latLng ){}
|
||||
default void onMapClick(MogoLatLng latLng) {
|
||||
}
|
||||
|
||||
/**
|
||||
* 地图锁定
|
||||
*
|
||||
* @param isLock
|
||||
*/
|
||||
default void onLockMap( boolean isLock ){}
|
||||
default void onLockMap(boolean isLock) {
|
||||
}
|
||||
|
||||
/**
|
||||
* 地图白天黑夜、导航视角切换
|
||||
*
|
||||
* @param ui
|
||||
*/
|
||||
default void onMapModeChanged( EnumMapUI ui ){}
|
||||
default void onMapModeChanged(EnumMapUI ui) {
|
||||
}
|
||||
|
||||
/**
|
||||
* 地图视距切换回调
|
||||
*
|
||||
* @param visualAngleMode
|
||||
*/
|
||||
default void onMapVisualAngleChanged(VisualAngleMode visualAngleMode) {
|
||||
}
|
||||
|
||||
/**
|
||||
* @param latLng 中点的经纬度
|
||||
@@ -61,5 +75,6 @@ public interface IMogoMapListener {
|
||||
* @param tilt 倾斜度
|
||||
* @param bearing 旋转角度
|
||||
*/
|
||||
default void onMapChanged( MogoLatLng latLng, float zoom, float tilt, float bearing ){}
|
||||
default void onMapChanged(MogoLatLng latLng, float zoom, float tilt, float bearing) {
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,10 +3,9 @@ package com.mogo.map.listener;
|
||||
import android.view.MotionEvent;
|
||||
|
||||
import com.mogo.map.MogoLatLng;
|
||||
import com.mogo.map.location.MogoLocation;
|
||||
import com.mogo.map.model.MogoPoi;
|
||||
import com.mogo.map.navi.MogoNaviInfo;
|
||||
import com.mogo.map.uicontroller.EnumMapUI;
|
||||
import com.mogo.map.uicontroller.VisualAngleMode;
|
||||
|
||||
/**
|
||||
* @author congtaowang
|
||||
@@ -22,9 +21,9 @@ public class MogoMapListenerHandler implements IMogoMapListener, IMogoMapListene
|
||||
}
|
||||
|
||||
public static MogoMapListenerHandler getInstance() {
|
||||
if ( sInstance == null ) {
|
||||
synchronized ( MogoMapListenerHandler.class ) {
|
||||
if ( sInstance == null ) {
|
||||
if (sInstance == null) {
|
||||
synchronized (MogoMapListenerHandler.class) {
|
||||
if (sInstance == null) {
|
||||
sInstance = new MogoMapListenerHandler();
|
||||
}
|
||||
}
|
||||
@@ -42,7 +41,7 @@ public class MogoMapListenerHandler implements IMogoMapListener, IMogoMapListene
|
||||
private IMogoMapListener mDelegateListener = null;
|
||||
|
||||
@Override
|
||||
public void registerHostMapListener( IMogoMapListener listener ) {
|
||||
public void registerHostMapListener(IMogoMapListener listener) {
|
||||
mDelegateListener = listener;
|
||||
}
|
||||
|
||||
@@ -53,50 +52,57 @@ public class MogoMapListenerHandler implements IMogoMapListener, IMogoMapListene
|
||||
|
||||
@Override
|
||||
public void onMapLoaded() {
|
||||
if ( mDelegateListener != null ) {
|
||||
if (mDelegateListener != null) {
|
||||
mDelegateListener.onMapLoaded();
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onTouch( MotionEvent motionEvent ) {
|
||||
if ( mDelegateListener != null ) {
|
||||
mDelegateListener.onTouch( motionEvent );
|
||||
public void onTouch(MotionEvent motionEvent) {
|
||||
if (mDelegateListener != null) {
|
||||
mDelegateListener.onTouch(motionEvent);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onPOIClick( MogoPoi poi ) {
|
||||
if ( mDelegateListener != null ) {
|
||||
mDelegateListener.onPOIClick( poi );
|
||||
public void onPOIClick(MogoPoi poi) {
|
||||
if (mDelegateListener != null) {
|
||||
mDelegateListener.onPOIClick(poi);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onMapClick( MogoLatLng latLng ) {
|
||||
if ( mDelegateListener != null ) {
|
||||
mDelegateListener.onMapClick( latLng );
|
||||
public void onMapClick(MogoLatLng latLng) {
|
||||
if (mDelegateListener != null) {
|
||||
mDelegateListener.onMapClick(latLng);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onLockMap( boolean isLock ) {
|
||||
if ( mDelegateListener != null ) {
|
||||
mDelegateListener.onLockMap( isLock );
|
||||
public void onLockMap(boolean isLock) {
|
||||
if (mDelegateListener != null) {
|
||||
mDelegateListener.onLockMap(isLock);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onMapModeChanged( EnumMapUI ui ) {
|
||||
if ( mDelegateListener != null ) {
|
||||
mDelegateListener.onMapModeChanged( ui );
|
||||
public void onMapModeChanged(EnumMapUI ui) {
|
||||
if (mDelegateListener != null) {
|
||||
mDelegateListener.onMapModeChanged(ui);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onMapChanged( MogoLatLng location, float zoom, float tilt, float bearing ) {
|
||||
if ( mDelegateListener != null ) {
|
||||
mDelegateListener.onMapChanged( location, zoom, tilt, bearing );
|
||||
public void onMapVisualAngleChanged(VisualAngleMode visualAngleMode) {
|
||||
if (mDelegateListener != null) {
|
||||
mDelegateListener.onMapVisualAngleChanged(visualAngleMode);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onMapChanged(MogoLatLng location, float zoom, float tilt, float bearing) {
|
||||
if (mDelegateListener != null) {
|
||||
mDelegateListener.onMapChanged(location, zoom, tilt, bearing);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -37,7 +37,7 @@ public class MogoLocationListenerRegister implements IMogoLocationListenerRegist
|
||||
return sInstance;
|
||||
}
|
||||
|
||||
private Set< IMogoLocationListener > sListeners = new HashSet<>( 10 );
|
||||
private final Set< IMogoLocationListener > sListeners = new HashSet<>( 10 );
|
||||
|
||||
/**
|
||||
* 注册定位回调
|
||||
|
||||
@@ -46,6 +46,16 @@ public interface IMogoMarkerManager {
|
||||
*/
|
||||
void removeMarkers();
|
||||
|
||||
/**
|
||||
* 显示地图上添加的所有markers
|
||||
*/
|
||||
void visibleAllMarkers();
|
||||
|
||||
/**
|
||||
* 隐藏地图上添加的所有markers
|
||||
*/
|
||||
void inVisibleAllMarkers();
|
||||
|
||||
/**
|
||||
* 获取某种类型的全部marker。
|
||||
*
|
||||
|
||||
@@ -1,7 +1,11 @@
|
||||
package com.mogo.map.marker;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.os.Build;
|
||||
import android.text.TextUtils;
|
||||
|
||||
import androidx.annotation.RequiresApi;
|
||||
|
||||
import com.mogo.map.listener.IMogoMapListener;
|
||||
import com.mogo.map.listener.IMogoMapListenerRegister;
|
||||
|
||||
@@ -43,6 +47,20 @@ public class MogoMarkersHandler implements IMogoMarkerClickListener, IMogoMarker
|
||||
sInstance = null;
|
||||
}
|
||||
|
||||
@SuppressLint("NewApi")
|
||||
public synchronized void visibleAll(){
|
||||
mServicesMarkers.values().stream()
|
||||
.filter(mogoMarkerList -> mogoMarkerList != null && !mogoMarkerList.isEmpty())
|
||||
.forEach(mogoMarkerList -> mogoMarkerList.forEach(mogoMarker -> mogoMarker.setVisible(true)));
|
||||
}
|
||||
|
||||
@SuppressLint("NewApi")
|
||||
public synchronized void inVisibleAll(){
|
||||
mServicesMarkers.values().stream()
|
||||
.filter(mogoMarkerList -> mogoMarkerList != null && !mogoMarkerList.isEmpty())
|
||||
.forEach(mogoMarkerList -> mogoMarkerList.forEach(mogoMarker -> mogoMarker.setVisible(false)));
|
||||
}
|
||||
|
||||
public synchronized void removeAll() {
|
||||
final Collection< List< IMogoMarker > > mogoMarkers = mServicesMarkers.values();
|
||||
for ( List< IMogoMarker > mogoMarkerList : mogoMarkers ) {
|
||||
|
||||
@@ -11,51 +11,70 @@ public enum EnumMapUI {
|
||||
/**
|
||||
* 正北朝上2D
|
||||
*/
|
||||
NorthUP_2D( 0, 1 ),
|
||||
NorthUP_2D(0, 1),
|
||||
/**
|
||||
* 车头朝上2D
|
||||
*/
|
||||
CarUp_2D( 1, 2 ),
|
||||
CarUp_2D(1, 2),
|
||||
|
||||
/**
|
||||
* 3D,只能头朝上
|
||||
*/
|
||||
CarUp_3D( 2, 0 ),
|
||||
CarUp_3D(2, 0),
|
||||
|
||||
/**
|
||||
* 白天模式
|
||||
*/
|
||||
Type_Light( 3, 5 ),
|
||||
Type_Light(3, 5),
|
||||
|
||||
/**
|
||||
* 夜晚模式
|
||||
*/
|
||||
Type_Night( 4, 4 ),
|
||||
Type_Night(4, 4),
|
||||
|
||||
/**
|
||||
* 夜晚模式
|
||||
*/
|
||||
Type_AUTO_LIGHT_Night( 5, 3 ),
|
||||
Type_AUTO_LIGHT_Night(5, 3),
|
||||
|
||||
/**
|
||||
* 自研地图的VR模式
|
||||
*/
|
||||
Type_VR( 0, 0 );
|
||||
Type_VR(0, 0),
|
||||
|
||||
/**
|
||||
* 视距远景
|
||||
*/
|
||||
MODE_LONG_SIGHT(6, 7),
|
||||
|
||||
/**
|
||||
* 视距中景
|
||||
*/
|
||||
MODE_MEDIUM_SIGHT(7, 8),
|
||||
|
||||
/**
|
||||
* 视距近景
|
||||
*/
|
||||
MODE_CLOSE_SIGHT(8, 6);
|
||||
|
||||
private int next;
|
||||
private int code;
|
||||
|
||||
EnumMapUI( int code, int next ) {
|
||||
EnumMapUI(int code, int next) {
|
||||
this.code = code;
|
||||
this.next = next;
|
||||
}
|
||||
|
||||
public EnumMapUI next() {
|
||||
for ( EnumMapUI value : EnumMapUI.values() ) {
|
||||
if ( value.code == next ) {
|
||||
for (EnumMapUI value : EnumMapUI.values()) {
|
||||
if (value.code == next) {
|
||||
return value;
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
public int getCode(){
|
||||
return code;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -28,50 +28,64 @@ public interface IMogoMapUIController {
|
||||
/**
|
||||
* 实时路况
|
||||
*/
|
||||
void setTrafficEnabled( boolean visible );
|
||||
void setTrafficEnabled(boolean visible);
|
||||
|
||||
/**
|
||||
* 地图缩放
|
||||
*
|
||||
* @param zoomIn true - 放大 false - 缩小
|
||||
*/
|
||||
MapControlResult changeZoom( boolean zoomIn );
|
||||
MapControlResult changeZoom(boolean zoomIn);
|
||||
|
||||
/**
|
||||
* 修改缩放级别
|
||||
*/
|
||||
MapControlResult changeZoom( float zoom );
|
||||
MapControlResult changeZoom(float zoom);
|
||||
|
||||
/**
|
||||
* 切换2D/3D模式
|
||||
*
|
||||
* @param mode true - 3D模式 false - 2D模式
|
||||
*/
|
||||
void changeMapMode( EnumMapUI mode );
|
||||
void changeMapMode(EnumMapUI mode);
|
||||
|
||||
/**
|
||||
* 切换3D模式下远距,中距,近距视角
|
||||
*
|
||||
* @param angelMode {@link VisualAngleMode}
|
||||
*/
|
||||
void changeMapVisualAngle(VisualAngleMode angelMode);
|
||||
|
||||
/**
|
||||
* 获得当前地图视距模式
|
||||
*
|
||||
* @return {@link VisualAngleMode}
|
||||
*/
|
||||
VisualAngleMode getCurrentMapVisualAngle();
|
||||
|
||||
/**
|
||||
* 将地图移动至当前位置
|
||||
*/
|
||||
default void moveToCenter( MogoLatLng latLng ) {
|
||||
moveToCenter( latLng, false );
|
||||
default void moveToCenter(MogoLatLng latLng) {
|
||||
moveToCenter(latLng, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* 将地图移动至当前位置
|
||||
*/
|
||||
void moveToCenter( MogoLatLng latLng, boolean animate );
|
||||
void moveToCenter(MogoLatLng latLng, boolean animate);
|
||||
|
||||
/**
|
||||
* 显示我的位置
|
||||
*
|
||||
* @param visible true - 显示 false - 不显示
|
||||
*/
|
||||
void showMyLocation( boolean visible );
|
||||
void showMyLocation(boolean visible);
|
||||
|
||||
/**
|
||||
* @param view
|
||||
*/
|
||||
void showMyLocation( View view );
|
||||
void showMyLocation(View view);
|
||||
|
||||
/**
|
||||
* 强调自车位置,加个动画突显一下自车位置
|
||||
@@ -83,7 +97,7 @@ public interface IMogoMapUIController {
|
||||
*
|
||||
* @param location
|
||||
*/
|
||||
void changeMyLocation( Location location );
|
||||
void changeMyLocation(Location location);
|
||||
|
||||
/**
|
||||
* 锁车
|
||||
@@ -100,14 +114,14 @@ public interface IMogoMapUIController {
|
||||
*
|
||||
* @param var1 级别 3-20
|
||||
*/
|
||||
void setLockZoom( int var1 );
|
||||
void setLockZoom(int var1);
|
||||
|
||||
/**
|
||||
* 预览全程
|
||||
*
|
||||
* @param bounds 显示范围
|
||||
*/
|
||||
void displayOverview( Rect bounds );
|
||||
void displayOverview(Rect bounds);
|
||||
|
||||
/**
|
||||
* 获取比例尺数据
|
||||
@@ -147,17 +161,17 @@ public interface IMogoMapUIController {
|
||||
* @param mapCenterX x 点位置x值与地图宽度的比例
|
||||
* @param mapCenterY y 点位置x值与地图高度的比例
|
||||
*/
|
||||
void setPointToCenter( double mapCenterX, double mapCenterY );
|
||||
void setPointToCenter(double mapCenterX, double mapCenterY);
|
||||
|
||||
/**
|
||||
* 获取经纬度对应的屏幕的位置
|
||||
*/
|
||||
Point getLocationPointInScreen( MogoLatLng latLng );
|
||||
Point getLocationPointInScreen(MogoLatLng latLng);
|
||||
|
||||
/**
|
||||
* 获取像素点对应的经纬度
|
||||
*/
|
||||
MogoLatLng getLocationMogoLatLngInScreen( Point point );
|
||||
MogoLatLng getLocationMogoLatLngInScreen(Point point);
|
||||
|
||||
/**
|
||||
* marker 跳跃动画
|
||||
@@ -170,13 +184,13 @@ public interface IMogoMapUIController {
|
||||
* @param duration 动画时间
|
||||
*/
|
||||
@Deprecated
|
||||
void startJumpAnimation( IMogoMarker marker, float high, Interpolator interpolator,
|
||||
long duration );
|
||||
void startJumpAnimation(IMogoMarker marker, float high, Interpolator interpolator,
|
||||
long duration);
|
||||
|
||||
/**
|
||||
* 设置刷新帧率
|
||||
*/
|
||||
void setRenderFps( int fps );
|
||||
void setRenderFps(int fps);
|
||||
|
||||
/**
|
||||
* @param tag 调用业务
|
||||
@@ -185,7 +199,7 @@ public interface IMogoMapUIController {
|
||||
* @param bound 地图上可显示的范围
|
||||
* @param lockCarPosition 是否锁定车辆位置
|
||||
*/
|
||||
void showBounds( String tag, MogoLatLng carPosition, List< MogoLatLng > lonLats, Rect bound, boolean lockCarPosition );
|
||||
void showBounds(String tag, MogoLatLng carPosition, List<MogoLatLng> lonLats, Rect bound, boolean lockCarPosition);
|
||||
|
||||
/**
|
||||
* 强制刷新地图
|
||||
@@ -199,7 +213,7 @@ public interface IMogoMapUIController {
|
||||
* @param p2
|
||||
* @return
|
||||
*/
|
||||
float calculateLineDistance( MogoLatLng p1, MogoLatLng p2 ) throws Exception;
|
||||
float calculateLineDistance(MogoLatLng p1, MogoLatLng p2) throws Exception;
|
||||
|
||||
/**
|
||||
* 当前的视图模式
|
||||
@@ -221,7 +235,7 @@ public interface IMogoMapUIController {
|
||||
* @param option 为空时使用
|
||||
* 默认配置
|
||||
*/
|
||||
void setCarCursorOption( @Nullable CarCursorOption option );
|
||||
void setCarCursorOption(@Nullable CarCursorOption option);
|
||||
|
||||
/**
|
||||
* 获取地图视图描述快照
|
||||
@@ -235,12 +249,13 @@ public interface IMogoMapUIController {
|
||||
*
|
||||
* @param bearing
|
||||
*/
|
||||
void changeBearing( float bearing );
|
||||
void changeBearing(float bearing);
|
||||
|
||||
void setAdasRecognizedResult(ADASRecognizedResult result);
|
||||
|
||||
/**
|
||||
* 获取瓦片id
|
||||
*
|
||||
* @param lon 经度
|
||||
* @param lat 纬度
|
||||
* @return 瓦片id
|
||||
@@ -248,11 +263,11 @@ public interface IMogoMapUIController {
|
||||
long getTileId(double lon, double lat);
|
||||
|
||||
|
||||
default void setAnchorScale( float x, float y ) {
|
||||
default void setAnchorScale(float x, float y) {
|
||||
|
||||
}
|
||||
|
||||
default void setAnchorRate( float rate ) {
|
||||
default void setAnchorRate(float rate) {
|
||||
|
||||
}
|
||||
|
||||
@@ -265,7 +280,7 @@ public interface IMogoMapUIController {
|
||||
*
|
||||
* @param enable
|
||||
*/
|
||||
default void rtkEnable( boolean enable ) {
|
||||
default void rtkEnable(boolean enable) {
|
||||
|
||||
}
|
||||
|
||||
@@ -278,7 +293,7 @@ public interface IMogoMapUIController {
|
||||
*
|
||||
* @param data
|
||||
*/
|
||||
default void syncLocation2Map( JSONObject data ) {
|
||||
default void syncLocation2Map(JSONObject data) {
|
||||
|
||||
}
|
||||
|
||||
@@ -287,7 +302,7 @@ public interface IMogoMapUIController {
|
||||
*
|
||||
* @param zoomGestureEnable 是否支持手势缩放改变地图样式
|
||||
*/
|
||||
default void openVrMode( boolean zoomGestureEnable ) {
|
||||
default void openVrMode(boolean zoomGestureEnable) {
|
||||
|
||||
}
|
||||
|
||||
@@ -301,7 +316,7 @@ public interface IMogoMapUIController {
|
||||
* @param isRTK
|
||||
* @return
|
||||
*/
|
||||
default double[] matchRoad(String id, double lon, double lat, double angle, boolean isGpsLocation, boolean isRTK ) {
|
||||
default double[] matchRoad(String id, double lon, double lat, double angle, boolean isGpsLocation, boolean isRTK) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -311,19 +326,21 @@ public interface IMogoMapUIController {
|
||||
|
||||
/**
|
||||
* 获取车速资源缓存 id
|
||||
*
|
||||
* @param speedVal
|
||||
* @return
|
||||
*/
|
||||
default String getMarkerInfoResName(String speedVal){
|
||||
default String getMarkerInfoResName(String speedVal) {
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取车速资源缓存 id
|
||||
*
|
||||
* @param speedVal
|
||||
* @return
|
||||
*/
|
||||
default void setMarkerInfoResName(String speedVal, String val){
|
||||
default void setMarkerInfoResName(String speedVal, String val) {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
package com.mogo.map.uicontroller;
|
||||
|
||||
public interface IMogoMapVisualAngle {
|
||||
|
||||
boolean isLongSight();
|
||||
|
||||
boolean isCloseSight();
|
||||
|
||||
boolean isMediumSight();
|
||||
}
|
||||
@@ -0,0 +1,44 @@
|
||||
package com.mogo.map.uicontroller;
|
||||
|
||||
public enum VisualAngleMode implements IMogoMapVisualAngle {
|
||||
|
||||
/**
|
||||
* 视距近景
|
||||
*/
|
||||
MODE_CLOSE_SIGHT(0),
|
||||
|
||||
/**
|
||||
* 视距中景
|
||||
*/
|
||||
MODE_MEDIUM_SIGHT(1),
|
||||
|
||||
/**
|
||||
* 视距远景
|
||||
*/
|
||||
MODE_LONG_SIGHT(2);
|
||||
|
||||
private int code;
|
||||
|
||||
VisualAngleMode(int code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
public int getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isLongSight() {
|
||||
return code == MODE_LONG_SIGHT.getCode();
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isCloseSight() {
|
||||
return code == MODE_CLOSE_SIGHT.getCode();
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isMediumSight() {
|
||||
return code == MODE_MEDIUM_SIGHT.getCode();
|
||||
}
|
||||
}
|
||||
@@ -12,6 +12,7 @@ import com.mogo.map.uicontroller.EnumMapUI;
|
||||
import com.mogo.map.uicontroller.IMogoMapUIController;
|
||||
import com.mogo.map.uicontroller.MapCameraPosition;
|
||||
import com.mogo.map.uicontroller.MapControlResult;
|
||||
import com.mogo.map.uicontroller.VisualAngleMode;
|
||||
import com.mogo.realtime.entity.ADASRecognizedResult;
|
||||
import com.mogo.utils.logger.Logger;
|
||||
|
||||
@@ -91,6 +92,23 @@ public class MogoMapUIController implements IMogoMapUIController {
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void changeMapVisualAngle(VisualAngleMode angelMode) {
|
||||
initDelegate();
|
||||
if (mDelegate != null) {
|
||||
Logger.d(TAG, "set VisualAngle: %s", angelMode.name());
|
||||
mDelegate.changeMapVisualAngle(angelMode);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public VisualAngleMode getCurrentMapVisualAngle() {
|
||||
initDelegate();
|
||||
if (mDelegate != null) {
|
||||
return mDelegate.getCurrentMapVisualAngle();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void moveToCenter(MogoLatLng latLng, boolean animate) {
|
||||
|
||||
@@ -98,4 +98,14 @@ public class MogoMarkerManager implements IMogoMarkerManager {
|
||||
public void removeRouteWayOverlay() {
|
||||
// RouteOverlayHelper.getInstance().removeAll();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void visibleAllMarkers() {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void inVisibleAllMarkers() {
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -68,11 +68,15 @@ object CarCorderController : TakePhotoCallback, TakeVideoCallback {
|
||||
}
|
||||
|
||||
fun initCarCorderController() {
|
||||
zdCarCoderController =
|
||||
ZdCarCoderController.getInstance(AbsMogoApplication.getApp().applicationContext)
|
||||
zdCarCoderController.addCallback(this)
|
||||
zdCarCoderController.addVideoCallback(this)
|
||||
zdCarCoderController.init()
|
||||
try {
|
||||
zdCarCoderController =
|
||||
ZdCarCoderController.getInstance(AbsMogoApplication.getApp().applicationContext)
|
||||
zdCarCoderController.addCallback(this)
|
||||
zdCarCoderController.addVideoCallback(this)
|
||||
zdCarCoderController.init()
|
||||
} catch (e: Exception) {
|
||||
e.printStackTrace()
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -44,10 +44,12 @@ dependencies {
|
||||
api rootProject.ext.dependencies.modulemain
|
||||
implementation rootProject.ext.dependencies.mogooch
|
||||
implementation rootProject.ext.dependencies.moduleservice
|
||||
implementation rootProject.ext.dependencies.moduleSmallMap
|
||||
} else {
|
||||
api project(":modules:mogo-module-main")
|
||||
implementation project(":OCH:mogo-och")
|
||||
implementation project(':modules:mogo-module-service')
|
||||
implementation project(':modules:mogo-module-smp')
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="com.zhidao.mogo.module.main.launcher">
|
||||
|
||||
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
|
||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
|
||||
<uses-permission android:name="android.permission.ACCESS_LOCATION_EXTRA_COMMANDS"/>
|
||||
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
|
||||
|
||||
<application>
|
||||
<activity
|
||||
android:name=".MainLauncherActivity"
|
||||
|
||||
@@ -1,29 +1,35 @@
|
||||
package com.zhidao.mogo.module.main.launcher;
|
||||
|
||||
import android.Manifest;
|
||||
import android.app.AlertDialog;
|
||||
import android.content.DialogInterface;
|
||||
import android.content.Intent;
|
||||
import android.content.pm.PackageManager;
|
||||
import android.net.Uri;
|
||||
import android.os.Bundle;
|
||||
import android.os.Handler;
|
||||
import android.os.Process;
|
||||
import android.provider.Settings;
|
||||
import android.text.TextUtils;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
import android.widget.FrameLayout;
|
||||
import android.widget.ImageView;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.core.app.ActivityCompat;
|
||||
import androidx.core.content.ContextCompat;
|
||||
|
||||
import com.alibaba.android.arouter.launcher.ARouter;
|
||||
import com.mogo.commons.debug.DebugConfig;
|
||||
import com.mogo.map.uicontroller.EnumMapUI;
|
||||
import com.mogo.module.common.MogoApisHandler;
|
||||
import com.mogo.module.common.entity.V2XMessageEntity;
|
||||
import com.mogo.module.main.MainActivity;
|
||||
import com.mogo.module.main.cards.MogoModulesManager;
|
||||
import com.mogo.module.main.utils.DisplayEffectsHelper;
|
||||
import com.mogo.module.service.receiver.MogoReceiver;
|
||||
import com.mogo.och.IMogoOCH;
|
||||
import com.mogo.service.intent.IMogoIntentListener;
|
||||
import com.mogo.service.statusmanager.IMogoStatusChangedListener;
|
||||
import com.mogo.service.map.IMogoSmallMapProvider;
|
||||
import com.mogo.service.statusmanager.StatusDescriptor;
|
||||
import com.mogo.service.v2x.IV2XListener;
|
||||
import com.mogo.utils.logger.Logger;
|
||||
@@ -32,6 +38,7 @@ import static com.mogo.module.common.entity.V2XMessageEntity.V2XTypeEnum.ALERT_T
|
||||
import static com.mogo.module.common.entity.V2XMessageEntity.V2XTypeEnum.ALERT_THE_FRONT_CRASH_WARNING_LEFT;
|
||||
import static com.mogo.module.common.entity.V2XMessageEntity.V2XTypeEnum.ALERT_THE_FRONT_CRASH_WARNING_RIGHT;
|
||||
import static com.mogo.module.common.entity.V2XMessageEntity.V2XTypeEnum.ALERT_THE_FRONT_CRASH_WARNING_TOP;
|
||||
import static com.mogo.utils.ProcessUtils.getPackageName;
|
||||
|
||||
/**
|
||||
* 针对作为Launcher的情况,做个性化操作
|
||||
@@ -119,7 +126,9 @@ public class MainLauncherActivity extends MainActivity implements IMogoIntentLis
|
||||
@Override
|
||||
protected void loadOthersModules() {
|
||||
super.loadOthersModules();
|
||||
Logger.d(TAG, "loadOthersModules");
|
||||
loadOCHModule();
|
||||
loadSmpModule();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -132,6 +141,16 @@ public class MainLauncherActivity extends MainActivity implements IMogoIntentLis
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 加载小地图模块
|
||||
*/
|
||||
private void loadSmpModule() {
|
||||
IMogoSmallMapProvider smp = ARouter.getInstance().navigation(IMogoSmallMapProvider.class);
|
||||
if (smp != null) {
|
||||
smp.init(this, R.id.module_main_id_smp_fragment);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onDestroy() {
|
||||
super.onDestroy();
|
||||
@@ -162,7 +181,6 @@ public class MainLauncherActivity extends MainActivity implements IMogoIntentLis
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
public void warningChangedWithDirection(int type) {
|
||||
Log.d(TAG, "显示红色预警蒙层");
|
||||
@@ -231,7 +249,7 @@ public class MainLauncherActivity extends MainActivity implements IMogoIntentLis
|
||||
|
||||
@Override
|
||||
public void onStatusChanged(StatusDescriptor descriptor, boolean isTrue) {
|
||||
super.onStatusChanged(descriptor,isTrue);
|
||||
super.onStatusChanged(descriptor, isTrue);
|
||||
if (isTrue) {
|
||||
mLeftShadowFrame.setVisibility(View.GONE);
|
||||
mApps.setVisibility(View.GONE);
|
||||
@@ -240,4 +258,5 @@ public class MainLauncherActivity extends MainActivity implements IMogoIntentLis
|
||||
mApps.setVisibility(View.VISIBLE);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -45,7 +45,6 @@
|
||||
:modules:mogo-module-left-panel
|
||||
:modules:mogo-module-left-panel-noop
|
||||
:foudations:mogo-base-services-apk
|
||||
:foudations:mogo-base-services-sdk
|
||||
:modules:mogo-module-push-base
|
||||
:modules:mogo-module-push-noop
|
||||
:modules:mogo-module-push
|
||||
|
||||
@@ -6,6 +6,7 @@ import com.mogo.map.MogoLatLng;
|
||||
import com.mogo.map.listener.IMogoMapListener;
|
||||
import com.mogo.map.model.MogoPoi;
|
||||
import com.mogo.map.uicontroller.EnumMapUI;
|
||||
import com.mogo.map.uicontroller.VisualAngleMode;
|
||||
|
||||
/**
|
||||
* @author congtaowang
|
||||
@@ -45,6 +46,11 @@ public abstract class MogoMapListenerAdapter implements IMogoMapListener {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onMapVisualAngleChanged(VisualAngleMode visualAngleMode) {
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onMapChanged( MogoLatLng latLng, float zoom, float tilt, float bearing ) {
|
||||
|
||||
|
||||
@@ -9,34 +9,37 @@ public
|
||||
*/
|
||||
enum AdasRecognizedType {
|
||||
//背景
|
||||
classIdBackground( "background", 0 ),
|
||||
classIdBackground("background", 0),
|
||||
//人
|
||||
classIdPerson( "person", 1 ),
|
||||
classIdPerson("person", 1),
|
||||
//自行车
|
||||
classIdBicycle( "bicycle", 2 ),
|
||||
classIdBicycle("bicycle", 2),
|
||||
//小轿车
|
||||
classIdCar( "car", 3 ),
|
||||
classIdCar("car", 3),
|
||||
//摩托车
|
||||
classIdMoto( "moto", 4 ),
|
||||
classIdMoto("moto", 4),
|
||||
//红绿灯
|
||||
classIdTrafficSign( "traffic_sign", 5 ),
|
||||
classIdTrafficSign("traffic_sign", 5),
|
||||
//bus
|
||||
classIdTrafficBus( "traffic_bus", 6 ),
|
||||
classIdTrafficBus("traffic_bus", 6),
|
||||
//truck
|
||||
classIdTrafficTruck( "traffic_truck", 8 ),
|
||||
classIdTrafficTruck("traffic_truck", 8),
|
||||
//stopLine
|
||||
classIdStopLine("warning_stop_line",9),
|
||||
classIdStopLine("warning_stop_line", 9),
|
||||
//预警箭头
|
||||
classIdWarningArrows("warning_arrows",10);
|
||||
classIdWarningArrows("warning_arrows", 10),
|
||||
|
||||
AdasRecognizedType( int code ) {
|
||||
//未知物体
|
||||
classIdUnKnow("unKnow", 100);
|
||||
|
||||
AdasRecognizedType(int code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
private String res = "";
|
||||
private int code = -1;
|
||||
|
||||
AdasRecognizedType( String res, int code ) {
|
||||
AdasRecognizedType(String res, int code) {
|
||||
this.res = res;
|
||||
this.code = code;
|
||||
}
|
||||
@@ -53,14 +56,18 @@ enum AdasRecognizedType {
|
||||
classIdTrafficTruck,
|
||||
classIdStopLine,
|
||||
classIdWarningArrows,
|
||||
classIdUnKnow,
|
||||
};
|
||||
|
||||
public String getRes() {
|
||||
return res;
|
||||
}
|
||||
|
||||
public static AdasRecognizedType valueFrom( int code ) {
|
||||
if ( code >= 0 && code < VAL.length ) {
|
||||
public static AdasRecognizedType valueFrom(int code) {
|
||||
if (code == 100) {
|
||||
return classIdUnKnow;
|
||||
}
|
||||
if (code >= 0 && code < VAL.length) {
|
||||
return VAL[code];
|
||||
}
|
||||
return null;
|
||||
|
||||
@@ -194,7 +194,8 @@ class BaseDrawer {
|
||||
|| recognizedType == AdasRecognizedType.classIdBicycle
|
||||
|| recognizedType == AdasRecognizedType.classIdPerson
|
||||
|| recognizedType == AdasRecognizedType.classIdTrafficBus
|
||||
|| recognizedType == AdasRecognizedType.classIdTrafficTruck;
|
||||
|| recognizedType == AdasRecognizedType.classIdTrafficTruck
|
||||
|| recognizedType == AdasRecognizedType.classIdUnKnow; //todo unKnow物体绘制
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -207,7 +208,8 @@ class BaseDrawer {
|
||||
AdasRecognizedType recognizedType = AdasRecognizedType.valueFrom(type);
|
||||
return recognizedType != AdasRecognizedType.classIdBicycle
|
||||
&& recognizedType != AdasRecognizedType.classIdMoto
|
||||
&& recognizedType != AdasRecognizedType.classIdPerson;
|
||||
&& recognizedType != AdasRecognizedType.classIdPerson
|
||||
&& recognizedType != AdasRecognizedType.classIdUnKnow; //todo unKnow物体不绘制车速
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -230,6 +232,8 @@ class BaseDrawer {
|
||||
return R.raw.stopline;
|
||||
} else if (recognizedType == AdasRecognizedType.classIdWarningArrows) {
|
||||
return R.raw.arraw;
|
||||
} else if (recognizedType == AdasRecognizedType.classIdUnKnow) { //todo unKnow物体3D模型
|
||||
return R.raw.othercar;
|
||||
}
|
||||
return R.raw.people;
|
||||
}
|
||||
@@ -248,6 +252,9 @@ class BaseDrawer {
|
||||
if (recognizedType == AdasRecognizedType.classIdTrafficBus) {
|
||||
return "#D8D8D8FF";
|
||||
}
|
||||
if (recognizedType == AdasRecognizedType.classIdUnKnow){ //todo unKnow颜色绘制
|
||||
return "#FF2894FF";
|
||||
}
|
||||
// 距离策略
|
||||
double[] coordinates = getCurCoordinates();
|
||||
double distance = CoordinateUtils.calculateLineDistance(lon, lat, coordinates[0], coordinates[1]) * 100;
|
||||
|
||||
@@ -86,31 +86,15 @@ public class V2XWarnDataDrawer extends BaseDrawer implements IMogoStatusChangedL
|
||||
MarkerShowEntity markerShowEntity = new MarkerShowEntity();
|
||||
markerShowEntity.setMarkerLocation(location);
|
||||
markerShowEntity.setMarkerType(TYPE_MARKER_CLOUD_WARN_DATA);
|
||||
|
||||
IMogoMarker bottomMarker = drawMarkerWith2Resource(markerShowEntity);
|
||||
|
||||
MogoLatLng mogoLatLng = new MogoLatLng(data.getCollisionLat(), data.getCollisionLon());
|
||||
//2D资源图片位置调整
|
||||
// MogoLatLng stopLineNew = Trigonometric.getNewLocation(data.getStopLines().get(1), 5, 180);
|
||||
// MogoLatLng newLocation = Trigonometric.getNewLocation(mogoLatLng, 5, 180);
|
||||
|
||||
IMogoMarker marker = drawMarker(markerShowEntity, modeResType(data.getType()));
|
||||
//识别物
|
||||
marker.addDynamicAnchorPosition(new MogoLatLng(
|
||||
data.getDirection() == 1 ? data.getStopLines().get(1).lat : data.getCollisionLat(),
|
||||
data.getDirection() == 1 ? data.getStopLines().get(1).lon : data.getCollisionLon()), (float) data.getHeading(), 5000);
|
||||
//识别物下方的红色圆圈
|
||||
bottomMarker.addDynamicAnchorPosition(new MogoLatLng(
|
||||
data.getDirection() == 1 ? data.getStopLines().get(1).lat : data.getCollisionLat(),
|
||||
data.getDirection() == 1 ? data.getStopLines().get(1).lon : data.getCollisionLon()), (float) data.getHeading(), 5000);
|
||||
// bottomMarker.addDynamicAnchorPosition(new MogoLatLng(
|
||||
// data.getDirection() == 1 ? stopLineNew.lat : newLocation.getLat(),
|
||||
// data.getDirection() == 1 ? stopLineNew.lon : newLocation.getLon()), (float) data.getHeading(), 5000);
|
||||
//移动完成以后,3s后消失
|
||||
UiThreadHandler.postDelayed(() -> {
|
||||
marker.remove();
|
||||
bottomMarker.remove();
|
||||
}, 8000);
|
||||
}, data.getShowTime());
|
||||
|
||||
}
|
||||
|
||||
@@ -140,7 +124,7 @@ public class V2XWarnDataDrawer extends BaseDrawer implements IMogoStatusChangedL
|
||||
.setGps(false);
|
||||
IMarkerView iMarkerView = MapMarkerAdapter.getMarkerView(mContext, markerShowEntity, options);
|
||||
options.icon3DRes(getModelRes(modeResType)); //TODO
|
||||
options.anchorColor("#FB3C3CFF"); //红色#FF3036 蓝色:#256BFF
|
||||
options.anchorColor("#FB3C3CFF");
|
||||
IMogoMarker marker = MogoApisHandler.getInstance().getApis().getMapServiceApi().getMarkerManager(mContext).addMarker(markerShowEntity.getMarkerType(), options);
|
||||
iMarkerView.setMarker(marker);
|
||||
marker.setToTop();
|
||||
@@ -196,13 +180,8 @@ public class V2XWarnDataDrawer extends BaseDrawer implements IMogoStatusChangedL
|
||||
MarkerShowEntity markerShowEntity = new MarkerShowEntity();
|
||||
markerShowEntity.setMarkerLocation(location);
|
||||
markerShowEntity.setMarkerType(TYPE_MARKER_CLOUD_STOP_LINE_DATA);
|
||||
|
||||
IMogoMarker marker = drawStopLineMarker(markerShowEntity);
|
||||
|
||||
//移动完成以后,3s后消失
|
||||
UiThreadHandler.postDelayed(() -> {
|
||||
marker.remove();
|
||||
}, 8000);
|
||||
|
||||
}
|
||||
|
||||
@@ -221,7 +200,6 @@ public class V2XWarnDataDrawer extends BaseDrawer implements IMogoStatusChangedL
|
||||
IMogoMarker marker = MogoApisHandler.getInstance().getApis().getMapServiceApi().getMarkerManager(mContext).addMarker(markerShowEntity.getMarkerType(), options);
|
||||
iMarkerView.setMarker(marker);
|
||||
marker.setToTop();
|
||||
|
||||
return marker;
|
||||
}
|
||||
|
||||
|
||||
@@ -140,6 +140,9 @@ public class SnapshotLocationController {
|
||||
mLastLocationInfo = null;
|
||||
}
|
||||
}
|
||||
if (list.size() == 0) {
|
||||
return null;
|
||||
}
|
||||
//Logger.d( TAG, "upload loc size = %s", list == null ? 0 : list.size() );
|
||||
return list;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<resources>
|
||||
<dimen name="dp_32">42px</dimen>
|
||||
<dimen name="module_v2n_tip_width">628px</dimen>
|
||||
<dimen name="module_v2n_tip_height">188px</dimen>
|
||||
<dimen name="module_v2n_tip_text_width">106px</dimen>
|
||||
<dimen name="module_v2n_tip_text_margin_right">52px</dimen>
|
||||
<dimen name="module_v2n_image_margin_left">37px</dimen>
|
||||
</resources>
|
||||
@@ -1123,5 +1123,11 @@
|
||||
<dimen name="module_map_amap_my_location_bg_size">360px</dimen>
|
||||
<dimen name="module_map_amap_my_location_icon_width">63px</dimen>
|
||||
<dimen name="module_map_amap_my_location_icon_height">96px</dimen>
|
||||
<dimen name="module_v2n_tip_width">470px</dimen>
|
||||
<dimen name="module_v2n_tip_height">140px</dimen>
|
||||
<dimen name="module_v2n_tip_text_width">100px</dimen>
|
||||
<dimen name="module_v2n_tip_text_margin_right">28px</dimen>
|
||||
<dimen name="module_v2n_image_margin_left">28px</dimen>
|
||||
|
||||
|
||||
</resources>
|
||||
|
||||
@@ -18,6 +18,7 @@ import android.widget.EditText;
|
||||
import android.widget.FrameLayout;
|
||||
import android.widget.ImageButton;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.LinearLayout;
|
||||
import android.widget.RadioButton;
|
||||
import android.widget.TextView;
|
||||
|
||||
@@ -45,6 +46,8 @@ import com.mogo.map.navi.MogoNaviInfo;
|
||||
import com.mogo.map.navi.MogoTraffic;
|
||||
import com.mogo.map.uicontroller.EnumMapUI;
|
||||
import com.mogo.map.uicontroller.IMogoMapUIController;
|
||||
import com.mogo.map.uicontroller.VisualAngleMode;
|
||||
import com.mogo.module.common.ModuleNames;
|
||||
import com.mogo.module.common.MogoApisHandler;
|
||||
import com.mogo.module.common.dialog.WMDialog;
|
||||
import com.mogo.module.common.glide.SkinAbleBitmapTarget;
|
||||
@@ -179,6 +182,11 @@ public class EntranceFragment extends MvpFragment<EntranceView, EntrancePresente
|
||||
|
||||
private boolean isShowGuide;
|
||||
|
||||
//远景和中景的切换
|
||||
private ImageView mSwitchMapModeImage;
|
||||
private FrameLayout mSwitchMapModeLayout;
|
||||
private TextView mSwitchText;
|
||||
|
||||
/**
|
||||
* 搜索莫模块
|
||||
*/
|
||||
@@ -204,7 +212,6 @@ public class EntranceFragment extends MvpFragment<EntranceView, EntrancePresente
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 内部变量标识是否在vrMode,用于方法执行过滤,避免重复或异常调用
|
||||
*/
|
||||
@@ -368,6 +375,15 @@ public class EntranceFragment extends MvpFragment<EntranceView, EntrancePresente
|
||||
tvYellow = (TextView) findViewById(R.id.tv_yellow);
|
||||
tvRed = (TextView) findViewById(R.id.tv_red);
|
||||
tvGreen = (TextView) findViewById(R.id.tv_green);
|
||||
|
||||
mSwitchMapModeLayout = (FrameLayout) findViewById(R.id.module_switch_model_layout);
|
||||
mSwitchMapModeImage = (ImageView) findViewById(R.id.module_switch_model_icon);
|
||||
mSwitchMapModeLayout.setOnClickListener(clickListener);
|
||||
mSwitchText = (TextView) findViewById(R.id.module_switch_model_text);
|
||||
|
||||
if (DebugConfig.getCarMachineType() == DebugConfig.CAR_MACHINE_TYPE_LENOVO ) {
|
||||
enterVrMode();
|
||||
}
|
||||
}
|
||||
|
||||
private int debugPanelClickCount = 0;
|
||||
@@ -377,7 +393,7 @@ public class EntranceFragment extends MvpFragment<EntranceView, EntrancePresente
|
||||
private Group groupFix;
|
||||
|
||||
private void enterVrMode() {
|
||||
if (!localIsVrMode) {
|
||||
// if (!localIsVrMode) {
|
||||
tvEnterVrMode.setVisibility(View.GONE);
|
||||
mMove2CurrentLocation.setVisibility(View.GONE);
|
||||
mUploadRoadCondition.setVisibility(View.GONE);
|
||||
@@ -399,8 +415,9 @@ public class EntranceFragment extends MvpFragment<EntranceView, EntrancePresente
|
||||
|
||||
localIsVrMode = true;
|
||||
flSpeed.setVisibility(View.VISIBLE);
|
||||
mSwitchMapModeLayout.setVisibility(View.VISIBLE);
|
||||
// clTrafficLight.setVisibility(View.VISIBLE);
|
||||
}
|
||||
// }
|
||||
}
|
||||
|
||||
private void exitVrMode() {
|
||||
@@ -426,6 +443,7 @@ public class EntranceFragment extends MvpFragment<EntranceView, EntrancePresente
|
||||
MogoApisHandler.getInstance().getApis().getRegisterCenterApi().unregisterMogoLocationListener(TAG);
|
||||
localIsVrMode = false;
|
||||
flSpeed.setVisibility(View.GONE);
|
||||
mSwitchMapModeLayout.setVisibility(View.GONE);
|
||||
clTrafficLight.setVisibility(View.GONE);
|
||||
}
|
||||
}
|
||||
@@ -706,6 +724,11 @@ public class EntranceFragment extends MvpFragment<EntranceView, EntrancePresente
|
||||
TopViewAnimHelper.getInstance().setIMogoMapUIController(mMApUIController);
|
||||
TopViewNoLinkageAnimHelper.getInstance().setIMogoMapUIController(mMApUIController);
|
||||
|
||||
// 进入vr模式,不可缩放地图
|
||||
if (DebugConfig.getCarMachineType() == DebugConfig.CAR_MACHINE_TYPE_LENOVO ) {
|
||||
UiThreadHandler.postDelayed(this::stepIntoVrMode, 3_000L );
|
||||
}
|
||||
|
||||
mClickShareVoiceStrings =
|
||||
getContext().getResources().getStringArray(R.array.click_share_voice_guide_array);
|
||||
mInnerGuideVoiceStrings =
|
||||
@@ -714,6 +737,18 @@ public class EntranceFragment extends MvpFragment<EntranceView, EntrancePresente
|
||||
getContext().getResources().getStringArray(R.array.search_voice_guide_outer_array);
|
||||
}
|
||||
|
||||
/**
|
||||
* 进入鹰眼模式,设置手势缩放地图失效
|
||||
*/
|
||||
private void stepIntoVrMode(){
|
||||
Logger.d( TAG, "进入vr模式" );
|
||||
MogoApisHandler.getInstance()
|
||||
.getApis()
|
||||
.getMapServiceApi()
|
||||
.getMapUIController()
|
||||
.openVrMode(false);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onResume() {
|
||||
super.onResume();
|
||||
@@ -1082,6 +1117,17 @@ public class EntranceFragment extends MvpFragment<EntranceView, EntrancePresente
|
||||
// }
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onMapVisualAngleChanged(VisualAngleMode visualAngleMode) {
|
||||
if (visualAngleMode.isMediumSight()) {
|
||||
mSwitchMapModeLayout.setVisibility(View.VISIBLE);
|
||||
} else if (visualAngleMode.isLongSight()) {
|
||||
mSwitchMapModeLayout.setVisibility(View.VISIBLE);
|
||||
} else if (visualAngleMode.isCloseSight()) {
|
||||
mSwitchMapModeLayout.setVisibility(View.GONE);
|
||||
}
|
||||
}
|
||||
|
||||
private static final int SEEK_HELP_NOTICE_NUM_MSG_TYPE = 401015;
|
||||
//求助已通知周围XX位车主
|
||||
private final IMogoOnMessageListener<String> seekHelpNoticeListener =
|
||||
@@ -1323,11 +1369,24 @@ public class EntranceFragment extends MvpFragment<EntranceView, EntrancePresente
|
||||
// show panel
|
||||
debugPanelGroup.setVisibility(View.VISIBLE);
|
||||
}
|
||||
}
|
||||
} else if (v.getId() == R.id.module_switch_model_layout) { //切换地图的远近视图
|
||||
if (MogoApisHandler.getInstance().getApis().getMapServiceApi().getMapUIController().getCurrentMapVisualAngle().isLongSight()) {
|
||||
MogoApisHandler.getInstance().getApis().getMapServiceApi().getMarkerManager(AbsMogoApplication.getApp()).visibleAllMarkers();
|
||||
MogoApisHandler.getInstance().getApis().getMapServiceApi()
|
||||
.getMapUIController().changeMapVisualAngle(VisualAngleMode.MODE_MEDIUM_SIGHT);
|
||||
mSwitchText.setText(R.string.module_map_model_normal);
|
||||
} else if (MogoApisHandler.getInstance().getApis().getMapServiceApi().getMapUIController().getCurrentMapVisualAngle().isMediumSight()) {
|
||||
MogoApisHandler.getInstance().getApis().getMapServiceApi().getMarkerManager(AbsMogoApplication.getApp()).inVisibleAllMarkers();
|
||||
MogoApisHandler.getInstance().getApis().getMapServiceApi()
|
||||
.getMapUIController().changeMapVisualAngle(VisualAngleMode.MODE_LONG_SIGHT);
|
||||
mSwitchText.setText(R.string.module_map_model_faster);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@Override
|
||||
public void onCarLocationChanged2(Location location) {
|
||||
vrModeNavInfoView.refreshCurrentSpeed((int) (location.getSpeed() * 3.6F));
|
||||
|
||||
@@ -75,6 +75,7 @@ public class TopViewAnimHelper {
|
||||
public void init(ConstraintLayout rootView, OnTopViewAnimSimpleListener listener) {
|
||||
topMotionLayout = rootView;
|
||||
topContainer = rootView.findViewById(R.id.module_entrance_id_top_container);
|
||||
topContainer.getLayoutParams().width = (int) getDimen(R.dimen.module_ext_top_view_width);
|
||||
animNavInfoView = rootView.findViewById(R.id.module_ext_id_anim_nav_info);
|
||||
vrModeNavInfoView = rootView.findViewById(R.id.module_ext_id_vr_nav_info);
|
||||
|
||||
|
||||
@@ -15,6 +15,8 @@ import android.view.View;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import com.mogo.module.extensions.R;
|
||||
|
||||
/**
|
||||
* created by wujifei on 2021/3/24 16:20
|
||||
* describe:
|
||||
@@ -28,7 +30,7 @@ public class ArcView extends View {
|
||||
//圆弧颜色
|
||||
private int mArcColor;
|
||||
//圆弧的画笔的宽度
|
||||
private float mStrokeWith = 10;
|
||||
private float mStrokeWith = getResources().getDimension(R.dimen.module_ext_arcView_stroke_with);
|
||||
//文字描述的paint
|
||||
private Paint mTextPaint;
|
||||
|
||||
@@ -73,11 +75,11 @@ public class ArcView extends View {
|
||||
mTextPaint.setTypeface(Typeface.defaultFromStyle(Typeface.BOLD));
|
||||
//绘制中心的数值
|
||||
mTextPaint.getTextBounds(mValue, 0, mValue.length(), mRect);
|
||||
canvas.drawText(mValue, getWidth() / 2, getHeight() / 2 + mRect.height() / 2-10, mTextPaint);
|
||||
canvas.drawText(mValue, getWidth() / 2, getHeight() / 2 + mRect.height() / 2 - 10, mTextPaint);
|
||||
|
||||
mTextPaint.setTypeface(Typeface.defaultFromStyle(Typeface.NORMAL));
|
||||
//绘制中心文字描述
|
||||
mTextPaint.setTextSize(28);
|
||||
mTextPaint.setTextSize(getResources().getDimension(R.dimen.module_ext_arcView_des_text_size));
|
||||
mTextPaint.getTextBounds(mDes, 0, mDes.length(), mRect);
|
||||
canvas.drawText(mDes, getWidth() / 2, getHeight() * 17 / 20 + mRect.height() / 2, mTextPaint);
|
||||
}
|
||||
@@ -116,7 +118,7 @@ public class ArcView extends View {
|
||||
//设置文本的对齐方式
|
||||
mTextPaint.setTextAlign(Paint.Align.CENTER);
|
||||
//mTextPaint.setTextSize(getResources().getDimensionPixelSize(R.dimen.dp_12));
|
||||
mTextPaint.setTextSize(80);
|
||||
mTextPaint.setTextSize(getResources().getDimension(R.dimen.module_ext_arcView_center_text_size));
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
After Width: | Height: | Size: 862 B |
|
After Width: | Height: | Size: 862 B |
|
After Width: | Height: | Size: 862 B |
|
After Width: | Height: | Size: 862 B |
|
After Width: | Height: | Size: 862 B |
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
|
||||
<corners android:radius="60px" />
|
||||
|
||||
<solid android:color="@color/module_switch_map_bg" />
|
||||
|
||||
</shape>
|
||||
@@ -6,8 +6,6 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
|
||||
|
||||
<include
|
||||
layout="@layout/module_ext_layout_extensions"
|
||||
android:layout_width="match_parent"
|
||||
@@ -28,8 +26,8 @@
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/fl_speed"
|
||||
android:layout_width="@dimen/dp_300"
|
||||
android:layout_height="@dimen/dp_300"
|
||||
android:layout_width="@dimen/module_ext_speed_width"
|
||||
android:layout_height="@dimen/module_ext_speed_height"
|
||||
android:layout_marginLeft="@dimen/dp_20"
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
android:background="@drawable/yi_biao_pan_bg_nor"
|
||||
@@ -41,9 +39,51 @@
|
||||
|
||||
<com.mogo.module.extensions.view.ArcView
|
||||
android:id="@+id/moudule_arc"
|
||||
android:layout_width="@dimen/dp_200"
|
||||
android:layout_height="@dimen/dp_200"
|
||||
android:layout_width="@dimen/module_ext_arcView_width"
|
||||
android:layout_height="@dimen/module_ext_arcView_height"
|
||||
android:layout_gravity="center" />
|
||||
|
||||
</FrameLayout>
|
||||
|
||||
<!--切换地图远近事件 @dimen/module_switch_map -->
|
||||
<FrameLayout
|
||||
android:id="@+id/module_switch_model_layout"
|
||||
android:layout_width="@dimen/module_switch_map"
|
||||
android:layout_height="@dimen/module_switch_map_height"
|
||||
android:layout_marginLeft="@dimen/dp_20"
|
||||
android:layout_marginBottom="26px"
|
||||
android:background="@drawable/module_switch_map_bg"
|
||||
android:elevation="@dimen/dp_10"
|
||||
android:padding="@dimen/dp_20"
|
||||
android:visibility="gone"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintLeft_toLeftOf="parent">
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/module_switch_layout"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="center_vertical"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/module_switch_model_icon"
|
||||
android:layout_width="@dimen/module_switch_image"
|
||||
android:layout_height="@dimen/module_switch_image"
|
||||
android:paddingLeft="@dimen/module_switch_margin_left"
|
||||
android:layout_gravity="left|center_vertical"
|
||||
android:src="@drawable/module_switch_map_angle" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/module_switch_model_text"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingLeft="@dimen/module_switch_margin_left"
|
||||
android:textSize="@dimen/module_switch_text_size"
|
||||
android:gravity="right|center"
|
||||
android:text="@string/module_map_model_normal"
|
||||
android:textColor="@color/module_ext_color_voice_text" />
|
||||
</LinearLayout>
|
||||
</FrameLayout>
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
|
||||
@@ -163,4 +163,5 @@
|
||||
<dimen name="module_event_live_error_text_size">36px</dimen>
|
||||
<dimen name="module_video_window_height_content">393px</dimen>
|
||||
<dimen name="module_video_window_width_content">700px</dimen>
|
||||
|
||||
</resources>
|
||||
@@ -0,0 +1,16 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<dimen name="module_ext_top_view_width_in_vr_mode">1100px</dimen>
|
||||
<dimen name="module_ext_speed_width">460px</dimen>
|
||||
<dimen name="module_ext_speed_height">460px</dimen>
|
||||
<dimen name="module_ext_arcView_width">320px</dimen>
|
||||
<dimen name="module_ext_arcView_height">320px</dimen>
|
||||
<dimen name="module_ext_arcView_stroke_with">15px</dimen>
|
||||
<dimen name="module_ext_arcView_center_text_size">110px</dimen>
|
||||
<dimen name="module_ext_arcView_des_text_size">40px</dimen>
|
||||
<dimen name="module_switch_map">279px</dimen>
|
||||
<dimen name="module_switch_map_height">119px</dimen>
|
||||
<dimen name="module_switch_margin_left">22px</dimen>
|
||||
<dimen name="module_switch_text_size">36px</dimen>
|
||||
<dimen name="module_switch_image">50px</dimen>
|
||||
</resources>
|
||||
@@ -98,7 +98,8 @@
|
||||
<dimen name="module_ext_navi_info_panel_next_info_distance_unit_textSize">40px</dimen>
|
||||
<dimen name="module_ext_navi_info_panel_next_info_distance_unit_textSize_small">30px</dimen>
|
||||
<dimen name="module_ext_navi_info_panel_next_info_road_textSize">34px</dimen>
|
||||
<dimen name="module_ext_navi_info_panel__arrive_destination_estimate_info_marginTop">24px</dimen>
|
||||
<dimen name="module_ext_navi_info_panel__arrive_destination_estimate_info_marginTop">24px
|
||||
</dimen>
|
||||
<dimen name="module_ext_navi_info_panel__arrive_destination_estimate_info_textSize">28px</dimen>
|
||||
<dimen name="module_ext_navi_info_turn_icon_margin_bottom">24px</dimen>
|
||||
<dimen name="module_ext_voice_msg_padding_top">17px</dimen>
|
||||
@@ -181,4 +182,13 @@
|
||||
<dimen name="module_video_window_height_content">393px</dimen>
|
||||
<dimen name="module_video_window_width_content">700px</dimen>
|
||||
|
||||
<dimen name="module_ext_speed_width">300px</dimen>
|
||||
<dimen name="module_ext_speed_height">300px</dimen>
|
||||
|
||||
<dimen name="module_ext_arcView_width">200px</dimen>
|
||||
<dimen name="module_ext_arcView_height">200px</dimen>
|
||||
<dimen name="module_ext_arcView_stroke_with">10px</dimen>
|
||||
<dimen name="module_ext_arcView_center_text_size">80px</dimen>
|
||||
<dimen name="module_ext_arcView_des_text_size">28px</dimen>
|
||||
|
||||
</resources>
|
||||