Merge remote-tracking branch 'origin/dev' into qa_1.1.8_easy_mode
# Conflicts: # gradle.properties # modules/mogo-module-v2x/src/main/java/com/mogo/module/v2x/adapter/holder/V2XScenarioHistoryRoadEventVH.java
@@ -16,6 +16,7 @@ import com.mogo.module.v2x.R;
|
||||
import com.mogo.module.v2x.V2XConst;
|
||||
import com.mogo.module.v2x.adapter.holder.V2XSurroundingDetailVH;
|
||||
import com.mogo.module.v2x.entity.panel.SurroundingConstruction;
|
||||
import com.mogo.module.v2x.listener.SurroundingDetailItemListener;
|
||||
import com.mogo.module.v2x.utils.RoadConditionUtils;
|
||||
import com.mogo.module.v2x.view.HeartLikeView;
|
||||
import com.mogo.module.v2x.view.HeartUnLikeView;
|
||||
@@ -39,10 +40,12 @@ public class V2XSurroundingDetailAdapter extends RecyclerView.Adapter<V2XSurroun
|
||||
private HeartLikeView mHeartLikeView;
|
||||
private HeartUnLikeView mUnHeartLikeView;
|
||||
|
||||
private SurroundingDetailItemListener mListener;
|
||||
|
||||
public V2XSurroundingDetailAdapter(Context context, List<MarkerExploreWay> list) {
|
||||
public V2XSurroundingDetailAdapter(Context context, List<MarkerExploreWay> list, SurroundingDetailItemListener listener) {
|
||||
mContext = context;
|
||||
markerExploreWays = list;
|
||||
mListener = listener;
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -77,18 +80,19 @@ public class V2XSurroundingDetailAdapter extends RecyclerView.Adapter<V2XSurroun
|
||||
mAddressTv.setText(exploreWay.getAddr());
|
||||
mTimeTv.setText(DateTimeUtils.getTimeText(exploreWay.getGenerateTime(), DateTimeUtils.MM_Yue_dd_Ri_HH_mm));
|
||||
|
||||
Logger.d(V2XConst.MODULE_NAME, "exploreWay.isFabulous() = " + exploreWay.isFabulous());
|
||||
showView(exploreWay.isFabulous());
|
||||
|
||||
mHeartLikeView.setOnClickCallListener(v -> {
|
||||
Logger.d(V2XConst.MODULE_NAME, "反馈有用 position = " + position);
|
||||
roadReportTrue(exploreWay);
|
||||
showView(true);
|
||||
mListener.onItemClickListener(v, position, exploreWay);
|
||||
});
|
||||
|
||||
mUnHeartLikeView.setOnClickCallListener(v -> {
|
||||
Logger.d(V2XConst.MODULE_NAME, "反馈无用 position = " + position);
|
||||
roadReportErr(exploreWay);
|
||||
showView(true);
|
||||
mListener.onItemClickListener(v, position, exploreWay);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -63,7 +63,7 @@ public class V2XScenarioHistoryRoadEventVH extends V2XBaseViewHolder<V2XHistoryS
|
||||
mTagEventType.setText(EventTypeUtils.getPoiTypeStr(mExploreWay.getPoiType()));
|
||||
|
||||
try {
|
||||
mTvIllegalNum.setText(mExploreWay.getUserInfo().getUserName() + "的分享 :" +
|
||||
mTvIllegalNum.setText(mExploreWay.getUserInfo().getUserName() + "的分享 " +
|
||||
TimeUtils.millis2String(mOldScenarioData.getTriggerTime(), "MM月dd日 HH:mm"));
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
|
||||
@@ -32,6 +32,7 @@ import com.mogo.module.v2x.adapter.V2XEventPagerAdapter
|
||||
import com.mogo.module.v2x.adapter.V2XSurroundingDetailAdapter
|
||||
import com.mogo.module.v2x.entity.panel.BackRefreshInfo
|
||||
import com.mogo.module.v2x.entity.panel.SurroundingConstruction
|
||||
import com.mogo.module.v2x.listener.SurroundingDetailItemListener
|
||||
import com.mogo.module.v2x.presenter.EventPanelPresenter
|
||||
import com.mogo.module.v2x.utils.TrackUtils
|
||||
import com.mogo.module.v2x.view.V2XEventPanelHistoryCountView
|
||||
@@ -49,7 +50,7 @@ import org.greenrobot.eventbus.ThreadMode
|
||||
*
|
||||
* @author tongchenfei
|
||||
*/
|
||||
class V2XEventPanelFragment : MvpFragment<V2XEventPanelFragment, EventPanelPresenter>() {
|
||||
class V2XEventPanelFragment : MvpFragment<V2XEventPanelFragment, EventPanelPresenter>() , SurroundingDetailItemListener {
|
||||
|
||||
private val TAG = "EventPanelFragment"
|
||||
|
||||
@@ -267,10 +268,14 @@ class V2XEventPanelFragment : MvpFragment<V2XEventPanelFragment, EventPanelPrese
|
||||
selectWithItem(item)
|
||||
}
|
||||
|
||||
override fun onItemClickListener(v: View?, position: Int, exploreWay: MarkerExploreWay?) {
|
||||
markerExploreWays[position].isFabulous = true
|
||||
mSurroundingDetailAdapter.notifyItemChanged(position)
|
||||
}
|
||||
|
||||
private fun initDetail() {
|
||||
mDetailRecyclerView!!.addItemDecoration(SpacesItemDecoration(resources.getDimension(R.dimen.share_item_padding).toInt()))
|
||||
mSurroundingDetailAdapter = V2XSurroundingDetailAdapter(activity, markerExploreWays)
|
||||
mSurroundingDetailAdapter = V2XSurroundingDetailAdapter(activity, markerExploreWays, this)
|
||||
mDetailRecyclerView!!.adapter = mSurroundingDetailAdapter
|
||||
val linearLayoutManager = LinearLayoutManager(activity, LinearLayoutManager.VERTICAL, false)
|
||||
mDetailRecyclerView!!.layoutManager = linearLayoutManager
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
package com.mogo.module.v2x.listener;
|
||||
|
||||
import android.view.View;
|
||||
|
||||
import com.mogo.module.common.entity.MarkerExploreWay;
|
||||
import com.mogo.module.v2x.entity.panel.SurroundingConstruction;
|
||||
|
||||
/**
|
||||
* @author lixiaopeng
|
||||
* @description
|
||||
* @since 2020/8/10
|
||||
*/
|
||||
public interface SurroundingDetailItemListener {
|
||||
void onItemClickListener(View v, int position, MarkerExploreWay exploreWay);
|
||||
}
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<corners android:radius="@dimen/dp_24"/>
|
||||
<corners android:radius="@dimen/dp_22"/>
|
||||
<gradient
|
||||
android:startColor="#B35E6079"
|
||||
android:endColor="#B33F4057"
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
android:layout_marginLeft="@dimen/module_v2x_surrounding_margin_left"
|
||||
android:gravity="center_vertical"
|
||||
android:text="周围5公里,共15条交通信息"
|
||||
android:textColor="@color/v2x_white"
|
||||
android:textColor="@color/v2x_FFF_666"
|
||||
android:textSize="@dimen/module_v2x_surrounding_top_textsize" />
|
||||
<!-- android:layout_centerInParent="true"-->
|
||||
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
android:layout_alignTop="@+id/road_case_style"
|
||||
android:layout_toLeftOf="@id/road_case_useless"
|
||||
android:gravity="left"
|
||||
android:paddingRight="@dimen/dp_28"
|
||||
android:paddingRight="@dimen/dp_35"
|
||||
android:text="100"
|
||||
android:textColor="@color/v2x_FFF_333"
|
||||
android:textSize="@dimen/share_item_text_size" />
|
||||
|
||||
|
Before Width: | Height: | Size: 2.7 KiB |
|
After Width: | Height: | Size: 3.0 KiB |
|
After Width: | Height: | Size: 3.0 KiB |
|
After Width: | Height: | Size: 11 KiB |
|
Before Width: | Height: | Size: 4.6 KiB |
|
After Width: | Height: | Size: 7.0 KiB |
|
After Width: | Height: | Size: 7.0 KiB |
|
After Width: | Height: | Size: 22 KiB |
@@ -1,8 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<corners android:radius="@dimen/dp_16" />
|
||||
<gradient
|
||||
android:angle="45"
|
||||
android:angle="180"
|
||||
android:endColor="#E6E6E6"
|
||||
android:startColor="#DDDDDD" />
|
||||
<corners android:radius="@dimen/dp_16" />
|
||||
|
||||
</shape>
|
||||
|
Before Width: | Height: | Size: 2.7 KiB |
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<corners android:radius="@dimen/dp_30" />
|
||||
<gradient
|
||||
android:angle="180"
|
||||
android:endColor="#F5F5F5"
|
||||
android:startColor="#F5F5F5" />
|
||||
</shape>
|
||||
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<corners android:radius="@dimen/dp_30" />
|
||||
<solid android:color="#F5F5F5" />
|
||||
</shape>
|
||||
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/module_carchatting_team_fragment_close_normal_light" android:state_pressed="false" />
|
||||
<item android:drawable="@drawable/module_carchatting_team_fragment_close_pressed_light" android:state_pressed="true" />
|
||||
</selector>
|
||||
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<corners android:radius="@dimen/dp_30" />
|
||||
<gradient
|
||||
android:angle="180"
|
||||
android:endColor="#F5F5F5"
|
||||
android:startColor="#FFFFFF" />
|
||||
</shape>
|
||||
|
After Width: | Height: | Size: 22 KiB |
@@ -0,0 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<corners android:radius="@dimen/dp_23" />
|
||||
<solid android:color="#DADADA" />
|
||||
</shape>
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<shape xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:shape="rectangle">
|
||||
<corners android:radius="@dimen/dp_21"/>
|
||||
<corners android:radius="@dimen/dp_22"/>
|
||||
|
||||
<gradient
|
||||
android:startColor="#579EFF"
|
||||
|
||||