路径规划
This commit is contained in:
@@ -6,7 +6,6 @@ import androidx.multidex.MultiDex;
|
||||
|
||||
import com.mogo.commons.AbsMogoApplication;
|
||||
import com.mogo.commons.debug.DebugConfig;
|
||||
import com.mogo.module.carchatting.CallChatConstant;
|
||||
import com.mogo.module.common.MogoModule;
|
||||
import com.mogo.module.common.MogoModulePaths;
|
||||
import com.mogo.module.onlinecar.OnLineCarConstants;
|
||||
|
||||
@@ -79,6 +79,24 @@ public class MogoCalculatePath {
|
||||
this.mTrafficLights = mTrafficLights;
|
||||
}
|
||||
|
||||
|
||||
|
||||
private StringBuilder mDescBuilder = null;
|
||||
|
||||
public String getDesc() {
|
||||
if ( mDescBuilder == null ) {
|
||||
mDescBuilder = new StringBuilder();
|
||||
int lightsSize = getTrafficLights();
|
||||
if ( lightsSize > 0 ) {
|
||||
mDescBuilder.append( "红绿灯" ).append( lightsSize ).append( "个" );
|
||||
}
|
||||
//mDescBuilder.append( " " );
|
||||
//mDescBuilder.append( "收费" ).append( mPath.getTollCost() ).append( "元" );
|
||||
}
|
||||
|
||||
return mDescBuilder.toString();
|
||||
}
|
||||
|
||||
public String getTagId() {
|
||||
return mTagId;
|
||||
}
|
||||
|
||||
@@ -42,7 +42,7 @@ public class MogoModulePaths {
|
||||
* 搜索页面模块实例化路径
|
||||
*/
|
||||
@Keep
|
||||
public static final String PATH_MODULE_SEARCH= "navi/search/ui";
|
||||
public static final String PATH_MODULE_SEARCH= "/navi/search/ui";
|
||||
|
||||
/**
|
||||
* 搜索页面Activity实例化路径
|
||||
@@ -58,6 +58,16 @@ public class MogoModulePaths {
|
||||
public static final String PATH_FRAGMENT_SEARCH = "/navi/search";
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 搜索 fragment
|
||||
*/
|
||||
@Keep
|
||||
public static final String PATH_FRAGMENT_CHOOSE_PAHT = "/navi/search";
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 按类别搜索 fragment
|
||||
*/
|
||||
|
||||
@@ -20,6 +20,10 @@ public class AMapConstants {
|
||||
*/
|
||||
public static final String KEY_SET_HOME_COMPONY = "key_home";
|
||||
|
||||
/**
|
||||
* 序列号实体的Key
|
||||
*/
|
||||
public static final String KEY_PARCELABLE = "key_Parcelable";
|
||||
|
||||
/**
|
||||
* 点击当前位置按钮的地图缩放级别
|
||||
|
||||
@@ -1,8 +1,14 @@
|
||||
package com.mogo.module.navi.constants
|
||||
|
||||
import android.content.Context
|
||||
import androidx.fragment.app.Fragment
|
||||
import com.alibaba.android.arouter.launcher.ARouter
|
||||
import com.mogo.map.navi.IMogoNavi
|
||||
import com.mogo.service.MogoServicePaths
|
||||
import com.mogo.service.fragmentmanager.FragmentDescriptor
|
||||
import com.mogo.service.fragmentmanager.IMogoFragmentManager
|
||||
import com.mogo.service.map.IMogoMapService
|
||||
import com.mogo.service.module.IMogoRegisterCenter
|
||||
|
||||
/**
|
||||
*@author zyz
|
||||
@@ -13,7 +19,28 @@ object SearchServiceHolder {
|
||||
val fragmentManager:IMogoFragmentManager = ARouter.getInstance().build(
|
||||
MogoServicePaths.PATH_FRAGMENT_MANAGER
|
||||
).navigation() as IMogoFragmentManager
|
||||
val mapService:IMogoMapService = ARouter.getInstance().build(
|
||||
MogoServicePaths.PATH_SERVICES_MAP
|
||||
).navigation() as IMogoMapService
|
||||
val listenerCenter:IMogoRegisterCenter = ARouter.getInstance().build(
|
||||
MogoServicePaths.PATH_REGISTER_CENTER
|
||||
).navigation() as IMogoRegisterCenter
|
||||
|
||||
|
||||
fun push(
|
||||
fragment: Fragment,
|
||||
tag: String
|
||||
) {
|
||||
val builder = FragmentDescriptor.Builder()
|
||||
builder.fragment(fragment)
|
||||
val build = builder.tag(tag)
|
||||
.build()
|
||||
fragmentManager.push(build)
|
||||
}
|
||||
|
||||
|
||||
fun getNavi(context: Context):IMogoNavi{
|
||||
return mapService.getNavi(context)
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,73 @@
|
||||
package com.mogo.module.navi.ui.adapter;
|
||||
|
||||
import android.content.Context;
|
||||
import android.view.View;
|
||||
import com.mogo.map.navi.MogoCalculatePath;
|
||||
import com.mogo.map.search.inputtips.MogoTip;
|
||||
import com.mogo.module.navi.R;
|
||||
import com.mogo.module.navi.ui.adapter.base.RecycleBaseAdapter;
|
||||
import com.mogo.module.navi.ui.adapter.base.RecycleViewHolder;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author zyz
|
||||
* 2019-08-13.
|
||||
*/
|
||||
public class CalculatePathAdapter extends RecycleBaseAdapter<MogoCalculatePath> {
|
||||
|
||||
private int current = 0;
|
||||
private int lastPosition = 0;
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
public CalculatePathAdapter(Context context, List<MogoCalculatePath> list) {
|
||||
super(context, list, R.layout.item_calculate_path_map);
|
||||
}
|
||||
|
||||
private View.OnClickListener onClickListener;
|
||||
|
||||
@Override
|
||||
public void onBindViewHolder(RecycleViewHolder holder, MogoCalculatePath item) {
|
||||
|
||||
//holder.setText(R.id.tv_position, tip.getName());
|
||||
//holder.setText(R.id.tv_position_des, tip.getAddress());
|
||||
|
||||
holder.itemView.setTag(R.id.tag_position, holder.getLayoutPosition());
|
||||
holder.itemView.setOnClickListener(onClickListener);
|
||||
holder.itemView.setSelected(current == holder.getLayoutPosition());
|
||||
|
||||
View mName = holder.getView(R.id.amap_calculate_item_strategy_name);
|
||||
holder.setText(R.id.amap_calculate_item_strategy_name, item.getStrategyName());
|
||||
mName.setBackgroundResource(getStrategyNameBkgResId(holder.getLayoutPosition()));
|
||||
holder.setText(R.id.amap_calculate_item_strategy_time, item.getTime());
|
||||
holder.setText(R.id.amap_calculate_item_strategy_distance, item.getDistance());
|
||||
holder.setText(R.id.amap_calculate_item_strategy_desc, item.getDesc());
|
||||
}
|
||||
|
||||
public void setOnClickListener(View.OnClickListener onClickListener) {
|
||||
this.onClickListener = onClickListener;
|
||||
}
|
||||
|
||||
public void setCurrent(int current) {
|
||||
this.current = current;
|
||||
notifyItemChanged(lastPosition);
|
||||
notifyItemChanged(current);
|
||||
lastPosition = current;
|
||||
}
|
||||
|
||||
public MogoCalculatePath getCurrentItem() {
|
||||
return list.get(current);
|
||||
}
|
||||
|
||||
private int getStrategyNameBkgResId(int position) {
|
||||
switch (position) {
|
||||
case 0:
|
||||
return R.drawable.amap_calculate_navi_strategy1_bkg;
|
||||
case 1:
|
||||
return R.drawable.amap_calculate_navi_strategy2_bkg;
|
||||
default:
|
||||
return R.drawable.amap_calculate_navi_strategy3_bkg;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -32,7 +32,7 @@ public class HistoryPoiAdapter extends RecycleBaseAdapter<SearchPoi> {
|
||||
holder.setText(R.id.tv_position, tip.getName());
|
||||
holder.setText(R.id.tv_position_des, tip.getAddress());
|
||||
|
||||
holder.itemView.setTag(R.id.tag_position, tip);
|
||||
holder.itemView.setTag(R.id.tag_item, tip);
|
||||
holder.itemView.setOnClickListener(onClickListener);
|
||||
|
||||
}
|
||||
|
||||
@@ -4,6 +4,7 @@ import android.content.Context;
|
||||
import android.view.View;
|
||||
import com.mogo.map.search.inputtips.MogoTip;
|
||||
import com.mogo.module.navi.R;
|
||||
import com.mogo.module.navi.bean.SearchPoi;
|
||||
import com.mogo.module.navi.ui.adapter.base.RecycleBaseAdapter;
|
||||
import com.mogo.module.navi.ui.adapter.base.RecycleViewHolder;
|
||||
import java.util.List;
|
||||
@@ -61,4 +62,9 @@ public class SearchCategoryAdapter extends RecycleBaseAdapter<MogoTip> {
|
||||
notifyItemChanged(current);
|
||||
lastPosition = current;
|
||||
}
|
||||
|
||||
|
||||
public MogoTip getCurrentItem(){
|
||||
return list.get(current);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,6 +5,7 @@ import android.view.View
|
||||
import androidx.fragment.app.Fragment
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import com.mogo.map.search.inputtips.MogoTip
|
||||
import com.mogo.module.common.MogoModulePaths
|
||||
import com.mogo.module.navi.R
|
||||
import com.mogo.module.navi.bean.SearchPoi
|
||||
import com.mogo.module.navi.constants.SearchServiceHolder
|
||||
@@ -53,6 +54,9 @@ class CategorySearchFragment : BaseSearchFragment() {
|
||||
|
||||
tv_navi_navi.setOnClickListener {
|
||||
|
||||
var newInstance = ChoosePathFragment.newInstance(mAdapter.currentItem)
|
||||
|
||||
SearchServiceHolder.push(newInstance, MogoModulePaths.PATH_FRAGMENT_CHOOSE_PAHT)
|
||||
}
|
||||
mAdapter.setOnClickListener {
|
||||
var position = it.getTag(R.id.tag_position) as Int
|
||||
|
||||
@@ -0,0 +1,105 @@
|
||||
package com.mogo.module.navi.ui.search
|
||||
|
||||
import android.os.Bundle
|
||||
import android.view.View
|
||||
import androidx.fragment.app.Fragment
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import com.mogo.map.navi.IMogoNaviListener
|
||||
import com.mogo.map.navi.MogoCalculatePath
|
||||
import com.mogo.map.navi.MogoNaviInfo
|
||||
import com.mogo.map.search.inputtips.MogoTip
|
||||
import com.mogo.module.common.MogoModulePaths
|
||||
import com.mogo.module.navi.R
|
||||
import com.mogo.module.navi.bean.EntityConvertUtils
|
||||
import com.mogo.module.navi.bean.SearchPoi
|
||||
import com.mogo.module.navi.constants.AMapConstants
|
||||
import com.mogo.module.navi.constants.SearchServiceHolder
|
||||
import com.mogo.module.navi.ui.adapter.CalculatePathAdapter
|
||||
import com.mogo.module.navi.ui.base.BaseFragment
|
||||
import kotlinx.android.synthetic.main.fragment_search_category.rv_search_result
|
||||
import kotlinx.android.synthetic.main.fragment_search_category.tv_navi_navi
|
||||
import kotlinx.android.synthetic.main.include_search_bar.et_navi_search
|
||||
import kotlinx.android.synthetic.main.include_search_bar.iv_navi_back
|
||||
|
||||
/**
|
||||
* @author zyz
|
||||
* 2020-01-09.
|
||||
*/
|
||||
class ChoosePathFragment : BaseFragment(), IMogoNaviListener {
|
||||
override fun onInitNaviFailure() {
|
||||
}
|
||||
|
||||
override fun onInitNaviSuccess() {
|
||||
}
|
||||
|
||||
override fun onNaviInfoUpdate(naviinfo: MogoNaviInfo?) {
|
||||
}
|
||||
|
||||
override fun onStartNavi() {
|
||||
}
|
||||
|
||||
override fun onStopNavi() {
|
||||
}
|
||||
|
||||
override fun onCalculateSuccess() {
|
||||
mAdapter.setDatas(SearchServiceHolder.getNavi(activity!!).calculatedStrategies)
|
||||
}
|
||||
|
||||
override fun onoCalculateFailed() {
|
||||
}
|
||||
|
||||
private lateinit var mAdapter:CalculatePathAdapter
|
||||
override fun getLayoutId(): Int {
|
||||
return R.layout.fragment_search_category
|
||||
}
|
||||
var mogoTip: MogoTip?=null
|
||||
override fun onCreate(savedInstanceState: Bundle?) {
|
||||
super.onCreate(savedInstanceState)
|
||||
mogoTip = arguments?.getParcelable<MogoTip>(AMapConstants.KEY_PARCELABLE)
|
||||
}
|
||||
|
||||
override fun onViewCreated(
|
||||
view: View,
|
||||
savedInstanceState: Bundle?
|
||||
) {
|
||||
super.onViewCreated(view, savedInstanceState)
|
||||
iv_navi_back.setOnClickListener {
|
||||
SearchServiceHolder.fragmentManager.pop()
|
||||
}
|
||||
|
||||
tv_navi_navi.text=getString(R.string.start_navi)
|
||||
|
||||
et_navi_search.setText(getString(R.string.choose_path))
|
||||
et_navi_search.isEnabled=false
|
||||
SearchServiceHolder.getNavi(context!!).naviTo(mogoTip?.point)
|
||||
|
||||
SearchServiceHolder.listenerCenter.registerMogoNaviListener(MogoModulePaths.PATH_FRAGMENT_CHOOSE_PAHT,this)
|
||||
|
||||
var arrayList = ArrayList<MogoCalculatePath>()
|
||||
mAdapter= CalculatePathAdapter(activity,arrayList)
|
||||
rv_search_result.layoutManager=LinearLayoutManager(activity,LinearLayoutManager.VERTICAL,false)
|
||||
|
||||
rv_search_result.adapter=mAdapter
|
||||
tv_navi_navi.setOnClickListener {
|
||||
SearchServiceHolder.getNavi(activity!!).startNavi(true)
|
||||
}
|
||||
|
||||
mAdapter.setOnClickListener {
|
||||
var position = it.getTag(R.id.tag_position) as Int
|
||||
mAdapter.setCurrent(position)
|
||||
mAdapter.currentItem.onItemClickInteraction.onItemClicked(mAdapter.currentItem.mTagId)
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
companion object{
|
||||
fun newInstance(searchPoi: MogoTip):Fragment{
|
||||
var bundle = Bundle()
|
||||
bundle.putParcelable(AMapConstants.KEY_PARCELABLE, searchPoi)
|
||||
var choosePathFragment = ChoosePathFragment()
|
||||
choosePathFragment.arguments=bundle
|
||||
return choosePathFragment
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -15,6 +15,7 @@ import com.mogo.module.common.MogoModulePaths;
|
||||
import com.mogo.module.navi.R;
|
||||
import com.mogo.module.navi.bean.EntityConvertUtils;
|
||||
import com.mogo.module.navi.bean.SearchPoi;
|
||||
import com.mogo.module.navi.constants.AMapConstants;
|
||||
import com.mogo.module.navi.constants.SearchServiceHolder;
|
||||
import com.mogo.module.navi.ui.adapter.HistoryPoiAdapter;
|
||||
import com.mogo.module.navi.ui.adapter.SearchPoiAdapter;
|
||||
@@ -70,7 +71,6 @@ public class SearchFragment extends BaseSearchFragment implements SearchView, Vi
|
||||
|
||||
@Override public void onCreate(@Nullable Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -112,7 +112,10 @@ public class SearchFragment extends BaseSearchFragment implements SearchView, Vi
|
||||
|
||||
mHistoryAdapter.setOnClickListener(new View.OnClickListener() {
|
||||
@Override public void onClick(View v) {
|
||||
|
||||
SearchPoi item = (SearchPoi) v.getTag(R.id.tag_item);
|
||||
MogoTip mogoTip = EntityConvertUtils.poi2MogoTip(item);
|
||||
SearchServiceHolder.INSTANCE.push(ChoosePathFragment.Companion.newInstance(mogoTip),
|
||||
MogoModulePaths.PATH_FRAGMENT_CHOOSE_PAHT);
|
||||
}
|
||||
});
|
||||
|
||||
@@ -121,6 +124,8 @@ public class SearchFragment extends BaseSearchFragment implements SearchView, Vi
|
||||
MogoTip tag = (MogoTip) v.getTag(R.id.tag_position);
|
||||
SearchPoi searchPoi = EntityConvertUtils.tipToPoi(tag);
|
||||
mSearchPresenter.insert(searchPoi);
|
||||
SearchServiceHolder.INSTANCE.push(ChoosePathFragment.Companion.newInstance(tag),
|
||||
MogoModulePaths.PATH_FRAGMENT_CHOOSE_PAHT);
|
||||
}
|
||||
});
|
||||
|
||||
@@ -132,7 +137,7 @@ public class SearchFragment extends BaseSearchFragment implements SearchView, Vi
|
||||
|
||||
findViewById(R.id.tv_navi_setting).setOnClickListener(new View.OnClickListener() {
|
||||
@Override public void onClick(View v) {
|
||||
push(new NaviSettingFragment(),MogoModulePaths.PATH_FRAGMENT_SETTING);
|
||||
push(new NaviSettingFragment(), MogoModulePaths.PATH_FRAGMENT_SETTING);
|
||||
}
|
||||
});
|
||||
|
||||
@@ -155,7 +160,7 @@ public class SearchFragment extends BaseSearchFragment implements SearchView, Vi
|
||||
findViewById(R.id.tv_navi_park).setOnClickListener(this);
|
||||
}
|
||||
|
||||
private void push(Fragment fragment,String tag) {
|
||||
private void push(Fragment fragment, String tag) {
|
||||
FragmentDescriptor.Builder builder = new FragmentDescriptor.Builder();
|
||||
builder.fragment(fragment);
|
||||
FragmentDescriptor build =
|
||||
@@ -386,7 +391,7 @@ public class SearchFragment extends BaseSearchFragment implements SearchView, Vi
|
||||
@Override public void onClick(View v) {
|
||||
TextView category = (TextView) v;
|
||||
String text = category.getText().toString();
|
||||
push(CategorySearchFragment.Companion.newInstance(text),MogoModulePaths.PATH_FRAGMENT_SEARCH_CATEGORY);
|
||||
|
||||
push(CategorySearchFragment.Companion.newInstance(text),
|
||||
MogoModulePaths.PATH_FRAGMENT_SEARCH_CATEGORY);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<solid android:color="#5B6CFF" />
|
||||
<corners android:radius="5dp" />
|
||||
</shape>
|
||||
</item>
|
||||
</selector>
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item >
|
||||
<shape android:shape="rectangle">
|
||||
<solid android:color="#43CEDF" />
|
||||
<corners android:radius="5dp" />
|
||||
</shape>
|
||||
</item>
|
||||
</selector>
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item >
|
||||
<shape android:shape="rectangle">
|
||||
<solid android:color="#B6B6B6" />
|
||||
<corners android:radius="5dp" />
|
||||
</shape>
|
||||
</item>
|
||||
</selector>
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item>
|
||||
<shape android:shape="rectangle">
|
||||
<solid android:color="#5B6CFF" />
|
||||
<corners android:radius="5dp" />
|
||||
</shape>
|
||||
</item>
|
||||
</selector>
|
||||
@@ -24,6 +24,7 @@
|
||||
android:id="@+id/rv_search_result"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_marginBottom="@dimen/dp_100"
|
||||
/>
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,84 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<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="match_parent"
|
||||
android:background="@drawable/selector_item_category_background"
|
||||
android:layout_height="@dimen/dp_226">
|
||||
|
||||
|
||||
<TextView
|
||||
android:id="@+id/amap_calculate_item_strategy_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_48"
|
||||
android:layout_marginLeft="@dimen/dp_40"
|
||||
android:layout_marginTop="@dimen/dp_26"
|
||||
android:background="@drawable/amap_calculate_navi_strategy_name_bkg"
|
||||
android:gravity="center"
|
||||
android:paddingLeft="8.5dp"
|
||||
android:paddingRight="8.5dp"
|
||||
android:textColor="#ccffffff"
|
||||
android:textSize="@dimen/sp_30"
|
||||
app:layout_constraintLeft_toLeftOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
tools:text="距离最短" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/amap_calculate_item_strategy_time"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_70"
|
||||
android:layout_marginTop="4.5dp"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/dp_50"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/amap_calculate_item_strategy_name"
|
||||
app:layout_constraintTop_toBottomOf="@+id/amap_calculate_item_strategy_name"
|
||||
tools:text="40小时55分" />
|
||||
|
||||
<View
|
||||
android:id="@+id/amap_calculate_item_strategy_divider"
|
||||
android:layout_width="1dp"
|
||||
android:layout_height="20dp"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:background="@color/white_10"
|
||||
app:layout_constraintBottom_toBottomOf="@+id/amap_calculate_item_strategy_time"
|
||||
app:layout_constraintLeft_toRightOf="@+id/amap_calculate_item_strategy_time"
|
||||
app:layout_constraintTop_toTopOf="@+id/amap_calculate_item_strategy_time" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/amap_calculate_item_strategy_distance"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_70"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:autoSizeMaxTextSize="25dp"
|
||||
android:autoSizeMinTextSize="18dp"
|
||||
android:autoSizeStepGranularity="1dp"
|
||||
android:autoSizeTextType="uniform"
|
||||
android:ellipsize="end"
|
||||
android:gravity="center"
|
||||
android:maxLines="1"
|
||||
android:textColor="@color/white"
|
||||
android:textSize="@dimen/dp_50"
|
||||
app:layout_constraintLeft_toRightOf="@+id/amap_calculate_item_strategy_divider"
|
||||
app:layout_constraintTop_toTopOf="@+id/amap_calculate_item_strategy_time"
|
||||
tools:text="2000.5公里" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/amap_calculate_item_strategy_desc"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_42"
|
||||
android:layout_marginTop="2dp"
|
||||
android:gravity="center"
|
||||
android:textColor="@color/white_80"
|
||||
android:textSize="@dimen/dp_30"
|
||||
app:layout_constraintLeft_toLeftOf="@+id/amap_calculate_item_strategy_time"
|
||||
app:layout_constraintTop_toBottomOf="@+id/amap_calculate_item_strategy_time"
|
||||
tools:text="红绿灯4个 收费5元" />
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="1dp"
|
||||
android:layout_marginLeft="20dp"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
android:background="#1a000000" />
|
||||
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -1,4 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<item name="tag_position" type="id"/>
|
||||
<item name="tag_item" type="id"/>
|
||||
</resources>
|
||||
@@ -31,4 +31,6 @@
|
||||
<string name="set_as_home_navi">设为家</string>
|
||||
<string name="set_as_compony_navi">设为公司</string>
|
||||
<string name="navi_to_there">导航去这里</string>
|
||||
<string name="start_navi">开始导航</string>
|
||||
<string name="choose_path">路线选择</string>
|
||||
</resources>
|
||||
|
||||
Reference in New Issue
Block a user