Merge remote-tracking branch 'origin/demo/shunyi_v2v_merge' into demo/shunyi_v2v_merge

This commit is contained in:
yangjingjing
2020-09-18 19:02:18 +08:00
77 changed files with 147 additions and 32 deletions

View File

@@ -345,7 +345,6 @@ dependencies {
}
implementation rootProject.ext.dependencies.moduletanluapi
implementation rootProject.ext.dependencies.mogomonitor
implementation rootProject.ext.dependencies.mogomodulewidgets
implementation rootProject.ext.dependencies.mogomoduleback
implementation rootProject.ext.dependencies.guideshow
} else {
@@ -363,7 +362,6 @@ dependencies {
}
implementation project(':libraries:mogo-tanlu-api')
implementation project(':modules:mogo-module-monitor')
implementation project(':modules:mogo-module-widgets')
implementation project(':modules:mogo-module-back')
implementation project(':modules:mogo-module-guide')
}
@@ -375,6 +373,7 @@ dependencies {
apply from: "./functions/leftpanel.gradle"
apply from: "./functions/skin.gradle"
apply from: "./functions/crashreport.gradle"
apply from: "./functions/widgets.gradle"
}
android.applicationVariants.all { variant ->

View File

@@ -0,0 +1,9 @@
// 悬浮控件:独立 app 和 launcher
project.dependencies {
if (Boolean.valueOf(RELEASE)) {
independentImplementation rootProject.ext.dependencies.mogomodulewidgets
} else {
independentImplementation project(':modules:mogo-module-widgets')
}
}

View File

@@ -23,7 +23,6 @@ import com.mogo.module.service.ServiceConst;
import com.mogo.module.tanlu.constant.TanluConstants;
import com.mogo.module.v2x.V2XConst;
import com.mogo.module.v2x.utils.ObuConfig;
import com.mogo.module.widgets.MogoWidgetsProvider;
import com.mogo.service.IMogoServiceApis;
import com.mogo.service.MogoServicePaths;
import com.mogo.service.passport.IMogoTicketCallback;
@@ -76,7 +75,7 @@ public class MogoApplication extends AbsMogoApplication {
MogoModulePaths.addModule( new MogoModule( BackToLauncherConst.MODULE_PATH, BackToLauncherConst.MODULE_NAME ) );
MogoModulePaths.addModule( new MogoModule( MediaConstants.TAG, MediaConstants.MODULE_TYPE ) );
} else {
MogoModulePaths.addBaseModule( new MogoModule( MogoWidgetsProvider.PATH, MogoWidgetsProvider.NAME ) );
MogoModulePaths.addBaseModule( new MogoModule( MogoServicePaths.PATH_WIDGETS, MogoServicePaths.PATH_WIDGETS ) );
}
if ( DebugConfig.getCarMachineType() != DebugConfig.CAR_MACHINE_TYPE_BYD ) {
MogoModulePaths.addModule( new MogoModule( CallChatConstant.PROVIDER, CallChatConstant.MODULE_NAME ) );

View File

@@ -273,6 +273,7 @@ public class AMapNaviViewWrapper implements IMogoMapView,
@Override
public void onTouch( MotionEvent motionEvent ) {
MogoMapListenerHandler.getInstance().onTouch( motionEvent );
changeMyLocationType2UnFollow();
}
/**
@@ -456,6 +457,7 @@ public class AMapNaviViewWrapper implements IMogoMapView,
break;
}
mMapView.setViewOptions( options );
changeMyLocationType2Follow();
}
}
@@ -527,6 +529,12 @@ public class AMapNaviViewWrapper implements IMogoMapView,
style = new MyLocationStyle();
}
style.showMyLocation( visible );
if ( mCurrentUIMode == EnumMapUI.CarUp_2D
|| mCurrentUIMode == EnumMapUI.CarUp_3D ) {
style.myLocationType( MyLocationStyle.LOCATION_TYPE_LOCATION_ROTATE_NO_CENTER );
} else {
style.myLocationType( MyLocationStyle.LOCATION_TYPE_FOLLOW );
}
if ( visible ) {
// 强制刷新一遍车标
style.myLocationIcon( BitmapDescriptorFactory.fromResource( mCarCursorOption.getCarCursorRes() ) );
@@ -548,17 +556,69 @@ public class AMapNaviViewWrapper implements IMogoMapView,
if ( style == null ) {
style = new MyLocationStyle();
}
if ( mCurrentUIMode == EnumMapUI.CarUp_2D
|| mCurrentUIMode == EnumMapUI.CarUp_3D ) {
style.myLocationType( MyLocationStyle.LOCATION_TYPE_LOCATION_ROTATE_NO_CENTER );
} else {
style.myLocationType( MyLocationStyle.LOCATION_TYPE_FOLLOW );
}
style.showMyLocation( true );
style.myLocationIcon( BitmapDescriptorFactory.fromView( view ) );
mMapView.getMap().setMyLocationStyle( style );
}
}
private void changeMyLocationType2UnFollow(){
if ( mCurrentUIMode == null ) {
return;
}
if ( !checkAMapView() ) {
return;
}
MyLocationStyle style = getMyLocationStyle();
if ( style == null ) {
style = new MyLocationStyle();
}
switch ( mCurrentUIMode ) {
case NorthUP_2D:
style.myLocationType( MyLocationStyle.LOCATION_TYPE_FOLLOW_NO_CENTER );
break;
case CarUp_2D:
case CarUp_3D:
style.myLocationType( MyLocationStyle.LOCATION_TYPE_LOCATION_ROTATE_NO_CENTER );
break;
}
mMapView.getMap().setMyLocationStyle( style );
}
private void changeMyLocationType2Follow() {
if ( mCurrentUIMode == null ) {
return;
}
if ( !checkAMapView() ) {
return;
}
MyLocationStyle style = getMyLocationStyle();
if ( style == null ) {
style = new MyLocationStyle();
}
switch ( mCurrentUIMode ) {
case NorthUP_2D:
style.myLocationType( MyLocationStyle.LOCATION_TYPE_FOLLOW );
break;
case CarUp_2D:
case CarUp_3D:
style.myLocationType( MyLocationStyle.LOCATION_TYPE_LOCATION_ROTATE );
break;
}
mMapView.getMap().setMyLocationStyle( style );
}
public void initMyLocation() {
if ( checkAMapView() ) {
mMapView.getMap().setMyLocationEnabled( true );
MyLocationStyle style = getMyLocationStyle();
style.myLocationType( MyLocationStyle.LOCATION_TYPE_LOCATION_ROTATE_NO_CENTER );
style.myLocationType( MyLocationStyle.LOCATION_TYPE_LOCATION_ROTATE );
style.interval( 1000 );
style.anchor( 0.5F, 0.5F );
style.strokeColor( Color.TRANSPARENT );
@@ -576,6 +636,7 @@ public class AMapNaviViewWrapper implements IMogoMapView,
}
Logger.d( TAG, "锁车" );
mMapView.recoverLockMode();
changeMyLocationType2Follow();
mIsCarLocked = true;
}
}

View File

@@ -21,8 +21,8 @@
<dimen name="module_apps_all_icon_width">50px</dimen>
<dimen name="module_apps_all_icon_height">50px</dimen>
<dimen name="module_apps_navigator_icon_width">78px</dimen>
<dimen name="module_apps_navigator_icon_height">78px</dimen>
<dimen name="module_apps_navigator_icon_width">94px</dimen>
<dimen name="module_apps_navigator_icon_height">94px</dimen>
<dimen name="module_apps_navigator_icon_divider">17px</dimen>
<dimen name="module_apps_voice_icon_width">55px</dimen>
<dimen name="module_apps_voice_icon_height">55px</dimen>

View File

@@ -55,9 +55,10 @@
android:gravity="center_horizontal"
android:orientation="vertical"
android:visibility="gone"
android:layout_marginLeft="@dimen/module_common_shadow_width_pos"
app:layout_constraintLeft_toLeftOf="@+id/module_map_id_navi_bg"
app:layout_constraintTop_toBottomOf="@+id/module_map_id_navi_bg"
tools:visibility="gone">
tools:visibility="visible">
<ImageView
android:id="@+id/module_ext_id_display_overview_icon"
@@ -127,6 +128,8 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:orientation="vertical"
android:layout_marginLeft="@dimen/module_common_shadow_width_pos"
android:layout_marginBottom="@dimen/module_common_shadow_width_pos"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintLeft_toLeftOf="parent">
@@ -140,7 +143,8 @@
android:textColor="#FFFFFF"
android:textSize="@dimen/module_ext_navi_exit_textSize"
android:textStyle="bold"
android:visibility="gone" />
android:visibility="gone"
tools:visibility="visible" />
<TextView
android:id="@+id/module_entrance_id_button2"
@@ -153,7 +157,8 @@
android:textColor="#FFFFFF"
android:textSize="@dimen/module_ext_navi_exit_textSize"
android:textStyle="bold"
android:visibility="gone" />
android:visibility="gone"
tools:visibility="visible" />
<TextView
android:id="@+id/module_entrance_id_exit_navi"
@@ -166,7 +171,8 @@
android:textColor="#FFFFFF"
android:textSize="@dimen/module_ext_navi_exit_textSize"
android:textStyle="bold"
android:visibility="gone" />
android:visibility="gone"
tools:visibility="visible" />
</LinearLayout>

View File

@@ -19,20 +19,15 @@
android:visibility="gone"
tools:visibility="visible" />
<!-- 时间、天气、消息 与entrance合到了一起减少一个view -->
<!-- <FrameLayout-->
<!-- android:id="@+id/module_main_id_header_fragment_container"-->
<!-- android:layout_width="match_parent"-->
<!-- android:layout_height="@dimen/module_ext_height"-->
<!-- android:layout_marginLeft="@dimen/module_main_header_fragment_container_marginLeft"-->
<!-- android:layout_marginTop="@dimen/module_main_header_fragment_container_marginTop" />-->
<!-- 左边按钮 -->
<FrameLayout
android:id="@+id/module_main_id_apps_fragment_container"
android:layout_width="@dimen/module_main_apps_fragment_container_width"
android:layout_height="match_parent"
android:padding="@dimen/module_main_apps_fragment_container_padding" />
android:paddingLeft="@dimen/module_main_apps_fragment_container_padding"
android:paddingRight="@dimen/module_main_apps_fragment_container_padding"
android:paddingTop="@dimen/module_main_apps_fragment_container_paddingTop"
android:paddingBottom="@dimen/module_main_apps_fragment_container_paddingTop"/>
<!-- 左侧浮层,布局位置目前只考虑了1+16独立app情况 -->
<FrameLayout
@@ -46,7 +41,10 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginLeft="@dimen/module_main_id_entrance_fragment_container_marginLeft"
android:padding="@dimen/module_main_entrance_fragment_container_padding" />
android:paddingLeft="@dimen/module_main_apps_fragment_container_padding"
android:paddingRight="@dimen/module_main_apps_fragment_container_padding"
android:paddingTop="@dimen/module_main_apps_fragment_container_paddingTop"
android:paddingBottom="@dimen/module_main_apps_fragment_container_paddingTop" />
<!-- 浮层-->
<FrameLayout
@@ -59,7 +57,10 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginLeft="@dimen/module_main_id_entrance_fragment_container_marginLeft"
android:padding="@dimen/module_event_fragment_container_padding" />
android:paddingLeft="@dimen/module_main_apps_fragment_container_padding"
android:paddingRight="@dimen/module_main_apps_fragment_container_padding"
android:paddingTop="@dimen/module_main_apps_fragment_container_paddingTop"
android:paddingBottom="@dimen/module_main_apps_fragment_container_paddingTop" />
<FrameLayout
android:id="@+id/module_main_id_message_history_fragment_container"

View File

@@ -0,0 +1,31 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<!-- module_main_activity_main.xml-->
<dimen name="module_main_map_left_shadow_frame_width">350px</dimen>
<dimen name="module_main_card_container_marginTop">8px</dimen>
<dimen name="module_main_card_container_width">352px</dimen>
<dimen name="module_main_card_container_height">370px</dimen>
<dimen name="module_main_card_container_marginLeft">32px</dimen>
<dimen name="module_main_card_container_marginBottom">140.5px</dimen>
<dimen name="module_main_card_container_paddingBottom">18px</dimen>
<dimen name="module_main_card_card_shadow_width_div">20px</dimen>
<dimen name="module_main_card_card_shadow_height_div">10px</dimen>
<dimen name="module_main_top_shadow_height">144px</dimen>
<dimen name="module_main_card_cover_up_margin">352px</dimen>
<dimen name="cards_container_dp_600">320px</dimen>
<dimen name="cards_container_shadow_dp_margin_top">319px</dimen>
<dimen name="module_main_apps_fragment_container_width">110px</dimen>
<dimen name="module_main_apps_fragment_container_padding">10px</dimen>
<dimen name="module_main_header_fragment_container_marginTop">15px</dimen>
<dimen name="module_main_header_fragment_container_marginLeft">460px</dimen>
<dimen name="module_main_id_entrance_fragment_container_marginLeft">444px</dimen>
<dimen name="module_main_id_left_panel_fragment_container_width">350px</dimen>
<dimen name="module_main_entrance_fragment_container_padding">10px</dimen>
<dimen name="module_main_entrance_fragment_container_padding_top">16px</dimen>
<dimen name="module_main_entrance_fragment_container_width">658px</dimen>
<dimen name="module_event_fragment_container_padding">8px</dimen>
<dimen name="module_main_apps_fragment_container_paddingTop">2px</dimen>
</resources>

View File

@@ -26,5 +26,6 @@
<dimen name="module_main_id_left_panel_fragment_container_width">635px</dimen>
<dimen name="module_main_entrance_fragment_container_width">1263px</dimen>
<dimen name="module_event_fragment_container_padding">20px</dimen>
<dimen name="module_main_apps_fragment_container_paddingTop">20px</dimen>
</resources>

View File

@@ -26,4 +26,5 @@
<dimen name="module_main_id_left_panel_fragment_container_width">340px</dimen>
<dimen name="module_main_entrance_fragment_container_width">1313px</dimen>
<dimen name="module_event_fragment_container_padding">20px</dimen>
<dimen name="module_main_apps_fragment_container_paddingTop">20px</dimen>
</resources>

View File

@@ -26,5 +26,6 @@
<dimen name="module_main_entrance_fragment_container_padding_top">16px</dimen>
<dimen name="module_main_entrance_fragment_container_width">658px</dimen>
<dimen name="module_event_fragment_container_padding">8px</dimen>
<dimen name="module_main_apps_fragment_container_paddingTop">10px</dimen>
</resources>

View File

@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<dimen name="module_media_music_state_location">462px</dimen>
<dimen name="module_media_music_state_location">468px</dimen>
<dimen name="module_media_music_state_location_x">573px</dimen>
<!-- lcc start-->
@@ -62,7 +62,7 @@
<dimen name="module_media_share_fragment_img_radius">3.2px</dimen>
<dimen name="module_media_pop_window_width">332px</dimen>
<dimen name="module_media_pop_window_height">76.7px</dimen>
<dimen name="module_media_pop_window_height">82px</dimen>
<dimen name="module_media_pop_window_inner_height">60px</dimen>
<dimen name="module_media_pop_window_inner_padding">18px</dimen>
<dimen name="module_media_pop_window_anim_img_size">44px</dimen>

View File

@@ -87,8 +87,8 @@
<dimen name="module_push_item_minHeight_vertical">310px</dimen>
<dimen name="module_push_item_maxHeight_vertical">350px</dimen>
<dimen name="module_push_content_paddingBottom_vertical">60px</dimen>
<dimen name="module_push_panel_marginTop">8px</dimen>
<dimen name="module_push_panel_marginBottom">8px</dimen>
<dimen name="module_push_panel_marginTop">2px</dimen>
<dimen name="module_push_panel_marginBottom">2px</dimen>
<dimen name="module_push_panel_marginRight">8px</dimen>
<dimen name="module_push_panel_paddingLeft">28px</dimen>
<dimen name="module_push_panel_paddingBottom">16px</dimen>

View File

@@ -87,8 +87,8 @@
<dimen name="module_push_item_minHeight_vertical">310px</dimen>
<dimen name="module_push_item_maxHeight_vertical">350px</dimen>
<dimen name="module_push_content_paddingBottom_vertical">60px</dimen>
<dimen name="module_push_panel_marginTop">8px</dimen>
<dimen name="module_push_panel_marginBottom">8px</dimen>
<dimen name="module_push_panel_marginTop">2px</dimen>
<dimen name="module_push_panel_marginBottom">2px</dimen>
<dimen name="module_push_panel_marginRight">8px</dimen>
<dimen name="module_push_panel_paddingLeft">28px</dimen>
<dimen name="module_push_panel_paddingBottom">16px</dimen>

View File

@@ -87,8 +87,8 @@
<dimen name="module_push_item_minHeight_vertical">310px</dimen>
<dimen name="module_push_item_maxHeight_vertical">350px</dimen>
<dimen name="module_push_content_paddingBottom_vertical">60px</dimen>
<dimen name="module_push_panel_marginTop">8px</dimen>
<dimen name="module_push_panel_marginBottom">8px</dimen>
<dimen name="module_push_panel_marginTop">2px</dimen>
<dimen name="module_push_panel_marginBottom">2px</dimen>
<dimen name="module_push_panel_marginRight">8px</dimen>
<dimen name="module_push_panel_paddingLeft">28px</dimen>
<dimen name="module_push_panel_paddingBottom">16px</dimen>

View File

@@ -67,7 +67,7 @@ class LauncherCardRefresher {
public static final long ONE_MINUTE = 60 * 1000L;
public static final long ONE_DAY = 24 * 60 * ONE_MINUTE;
private String mLaunchTTSText;
private long mDefaultTTSPlayInterval = 30 * ONE_MINUTE;
private long mDefaultTTSPlayInterval = 60 * ONE_MINUTE;
private LauncherCardAdvertisementData.LauncherCardAdvertisement mDefaultLauncherCardConfig;
private List< LauncherCardAdvertisementData.LauncherCardAdvertisement > mAdvertisements;
@@ -180,6 +180,7 @@ class LauncherCardRefresher {
}
mHandler.sendEmptyMessageDelayed( MSG_LOAD_NET_CONFIG, delay );
startInduceStrategy();
SharedPrefsMgr.getInstance( mContext ).putLong( KEY_LauncherCardTipLastTipTime, System.currentTimeMillis() );
}
/**
@@ -365,7 +366,7 @@ class LauncherCardRefresher {
int counter = SharedPrefsMgr.getInstance( mContext ).getInt( KEY_LauncherCardTipCounter, 0 );
if ( counter >= 5 ) {
long lastTipTime = SharedPrefsMgr.getInstance( mContext ).getLong( KEY_LauncherCardTipLastTipTime, 0L );
if ( System.currentTimeMillis() - lastTipTime < 10 * ONE_DAY ) {
if ( System.currentTimeMillis() - lastTipTime < 1 * ONE_DAY ) {
return;
} else {
SharedPrefsMgr.getInstance( mContext ).putInt( KEY_LauncherCardTipCounter, 0 );

View File

@@ -256,4 +256,9 @@ public class MogoServicePaths {
*/
@Deprecated
public static final String PATH_CRASH_WARNING = "/crash/warning";
/**
* 悬浮小控件
*/
public static final String PATH_WIDGETS = "/widgets/provider";
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 98 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 99 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 93 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 96 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 84 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 607 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 98 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 99 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 640 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 93 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 747 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 96 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 908 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 336 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 84 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 551 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 82 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 670 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 318 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 329 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 320 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 328 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 908 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 163 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 283 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 287 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 274 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.7 KiB