diff --git a/gradle.properties b/gradle.properties index 7ced486484..fb0de27a8b 100644 --- a/gradle.properties +++ b/gradle.properties @@ -42,7 +42,7 @@ MOGO_MODULE_COMMON_VERSION=1.1.0.12 MOGO_MODULE_MAIN_VERSION=1.1.0.12 MOGO_MODULE_MAP_VERSION=1.1.0.12 MOGO_MODULE_SERVICE_VERSION=1.1.0.12 -MOGO_MODULE_EXTENSIONS_VERSION=1.1.0.12 +MOGO_MODULE_EXTENSIONS_VERSION=1.1.0.13 MOGO_MODULE_SEARCH_VERSION=1.1.0.12 MOGO_MODULE_BACK_VERSION=1.1.0.12 MOGO_MODULE_GPS_SIMULATOR_VERSION=1.1.0.12 @@ -54,7 +54,7 @@ MOGO_MODULE_GUIDE_VERSION=1.1.0.12 ## 工程外部模块 # 探路 -MOGO_MODULE_TANLU_VERSION=1.0.5-SNAPSHOT +MOGO_MODULE_TANLU_VERSION=1.0.6-SNAPSHOT # 车聊聊 CARCHATTING_VERSION=1.0.4-SNAPSHOT # 车聊聊接口 diff --git a/modules/mogo-module-extensions/src/main/java/com/mogo/module/extensions/utils/TopViewAnimHelper.java b/modules/mogo-module-extensions/src/main/java/com/mogo/module/extensions/utils/TopViewAnimHelper.java index 397dca9d50..3884ab3f96 100644 --- a/modules/mogo-module-extensions/src/main/java/com/mogo/module/extensions/utils/TopViewAnimHelper.java +++ b/modules/mogo-module-extensions/src/main/java/com/mogo/module/extensions/utils/TopViewAnimHelper.java @@ -7,6 +7,8 @@ import android.transition.TransitionManager; import android.util.ArrayMap; import android.view.View; import android.view.ViewGroup; +import android.view.animation.BounceInterpolator; +import android.view.animation.OvershootInterpolator; import android.widget.ImageView; import android.widget.TextView; @@ -113,11 +115,14 @@ public class TopViewAnimHelper { IMogoTopViewStatusListener listener; if (isTopViewOut) { listener = statusListenerMap.remove(currentAnimatingView); - }else{ + if(listener!=null) { + listener.onViewRemoved(currentAnimatingView); + } + } else { listener = statusListenerMap.get(currentAnimatingView); - } - if (listener != null) { - listener.onViewAdded(currentAnimatingView); + if(listener!=null) { + listener.onViewAdded(currentAnimatingView); + } } } @@ -148,8 +153,9 @@ public class TopViewAnimHelper { private View currentAnimatingView = null; - public void startTopInAnim(View view, ViewGroup.LayoutParams params, IMogoTopViewStatusListener statusListener) { - Logger.d(TAG, "startTopInAnim====="+isTopViewOut); + public void startTopInAnim(View view, ViewGroup.LayoutParams params, + IMogoTopViewStatusListener statusListener) { + Logger.d(TAG, "startTopInAnim=====" + isTopViewOut); if (view == null) { throw new IllegalArgumentException("method addTopView params view is null"); } @@ -231,9 +237,9 @@ public class TopViewAnimHelper { naviBg.getLayoutParams().height = (int) topMotionLayout.getContext().getResources().getDimension(R.dimen.module_ext_navi_info_panel_small_height); int scene = 0; - if(naviBg.getVisibility() == View.VISIBLE){ + if (naviBg.getVisibility() == View.VISIBLE) { scene = Scene.NAVI_WITH_ROAD_EVENT; - }else{ + } else { scene = Scene.AIMLESS_WITH_ROAD_EVENT; } Logger.d(TAG, "show top setMapCenterPointByScene: " + scene); @@ -245,9 +251,9 @@ public class TopViewAnimHelper { /** * 退出最新的(也就是最上面的)view */ - private void startLatestTopOutAnim(){ - if (topContainer.getChildCount() > 0) { - startTopOutAnim(topContainer.getChildAt(topContainer.getChildCount() - 1)); + private void startLatestTopOutAnim() { + if (topContainer.getChildCount() > 0) { + startTopOutAnim(topContainer.getChildAt(topContainer.getChildCount() - 1)); } } @@ -255,9 +261,10 @@ public class TopViewAnimHelper { Logger.d("TopViewAnimHelper", "startTopOutAnim====="); if (!isTopViewOut) { - if(topContainer.getChildCount() >1){ + if (topContainer.getChildCount() > 1) { // 顶部view包含多个view,只推出当前view,不进行整体上移 - Logger.d(TAG, "小view退出: " + view.getTranslationY() + " height: " + view.getHeight()); + Logger.d(TAG, + "小view退出: " + view.getTranslationY() + " height: " + view.getHeight()); view.animate().translationY(-(view.getHeight())).setDuration(500).setListener(new Animator.AnimatorListener() { @Override public void onAnimationStart(Animator animation) { @@ -266,13 +273,13 @@ public class TopViewAnimHelper { @Override public void onAnimationEnd(Animator animation) { - Logger.d(TAG,"onAnimationEnd: "+view); + Logger.d(TAG, "onAnimationEnd: " + view); viewCaches.remove(view); topContainer.removeView(view); IMogoTopViewStatusListener listener = statusListenerMap.remove(view); if (listener != null) { listener.onViewRemoved(view); - }else{ + } else { Logger.d(TAG, "listener is null"); } } @@ -288,7 +295,7 @@ public class TopViewAnimHelper { } }).start(); - }else { + } else { // 顶部view仅剩一个view,需要整体上移 currentAnimatingView = view; isTopViewOut = true; @@ -299,7 +306,7 @@ public class TopViewAnimHelper { } constraintSet.clone(topMotionLayout); - constraintSet.clear(R.id.module_entrance_id_top_container,ConstraintSet.TOP); + constraintSet.clear(R.id.module_entrance_id_top_container, ConstraintSet.TOP); constraintSet.connect(R.id.module_entrance_id_top_container, ConstraintSet.BOTTOM, R.id.module_entrance_id_top_motion_layout, ConstraintSet.TOP); TransitionManager.beginDelayedTransition(topMotionLayout, transition); @@ -326,9 +333,9 @@ public class TopViewAnimHelper { naviBg.getLayoutParams().height = (int) topMotionLayout.getContext().getResources().getDimension(R.dimen.module_ext_navi_info_panel_height); int scene = 0; - if(naviBg.getVisibility() == View.VISIBLE){ + if (naviBg.getVisibility() == View.VISIBLE) { scene = Scene.NAVI; - }else{ + } else { scene = Scene.AIMLESS; } Logger.d(TAG, "hide top setMapCenterPointByScene: " + scene); @@ -399,9 +406,9 @@ public class TopViewAnimHelper { remainTimeGroup.setVisibility(View.GONE); arriveTimeGroup.setVisibility(View.GONE); int scene = 0; - if(isTopViewOut){ + if (isTopViewOut) { scene = Scene.AIMLESS_WITH_ROAD_EVENT; - }else{ + } else { scene = Scene.AIMLESS; } Logger.d(TAG, "hide navi setMapCenterPointByScene: " + scene); diff --git a/modules/mogo-module-extensions/src/main/res/layout/module_ext_layout_entrance.xml b/modules/mogo-module-extensions/src/main/res/layout/module_ext_layout_entrance.xml index 4344dd07df..7dedbe8be2 100644 --- a/modules/mogo-module-extensions/src/main/res/layout/module_ext_layout_entrance.xml +++ b/modules/mogo-module-extensions/src/main/res/layout/module_ext_layout_entrance.xml @@ -28,6 +28,9 @@ android:layout_width="@dimen/module_ext_navi_info_panel_width" android:layout_height="@dimen/module_ext_navi_info_panel_height" android:background="@drawable/module_ext_dw_navi_info_panel_bkg" + android:focusable="true" + android:clickable="true" + app:layout_constraintHorizontal_bias="0.501" app:layout_constraintLeft_toLeftOf="@id/module_entrance_id_top_container" app:layout_constraintRight_toRightOf="@id/module_entrance_id_top_container" app:layout_constraintTop_toBottomOf="@id/module_entrance_id_top_container" /> diff --git a/modules/mogo-module-share/src/main/res/drawable-ldpi/module_share_title_icon.png b/modules/mogo-module-share/src/main/res/drawable-ldpi/module_share_title_icon.png new file mode 100644 index 0000000000..62daa43114 Binary files /dev/null and b/modules/mogo-module-share/src/main/res/drawable-ldpi/module_share_title_icon.png differ diff --git a/modules/mogo-module-share/src/main/res/drawable-xhdpi/module_share_title_icon.png b/modules/mogo-module-share/src/main/res/drawable-xhdpi/module_share_title_icon.png new file mode 100644 index 0000000000..cb48ea6deb Binary files /dev/null and b/modules/mogo-module-share/src/main/res/drawable-xhdpi/module_share_title_icon.png differ diff --git a/modules/mogo-module-share/src/main/res/layout/launcher_dialog_share_2.xml b/modules/mogo-module-share/src/main/res/layout/launcher_dialog_share_2.xml index d9408ba5b3..7d79054f71 100644 --- a/modules/mogo-module-share/src/main/res/layout/launcher_dialog_share_2.xml +++ b/modules/mogo-module-share/src/main/res/layout/launcher_dialog_share_2.xml @@ -24,6 +24,9 @@ android:layout_height="wrap_content" android:layout_marginTop="@dimen/share_module_title_margin_top" android:text="我要分享" + android:drawableLeft="@drawable/module_share_title_icon" + android:drawableRight="@drawable/module_share_title_icon" + android:drawablePadding="@dimen/dp_40" android:textColor="@color/white" android:textSize="@dimen/share_module_title_content" android:textStyle="bold" @@ -47,7 +50,7 @@ android:id="@+id/tvBlock" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:layout_marginStart="@dimen/dp_116" + android:layout_marginStart="@dimen/dp_164" android:layout_marginTop="@dimen/dp_30" android:text="拥堵" android:textColor="#fff" @@ -145,7 +148,7 @@ android:id="@+id/tvConstruction" android:layout_width="wrap_content" android:layout_height="wrap_content" - android:layout_marginEnd="@dimen/dp_116" + android:layout_marginEnd="@dimen/dp_132" android:gravity="center" android:text="施工" android:textColor="#fff"