| | |
| | | while (iterator.hasNext()){ |
| | | Map.Entry<BaseDataUIBean.TYPE_,MapInfoHead>entry = iterator.next(); |
| | | MapInfoHead mapInfoHead = entry.getValue(); |
| | | BaseDataUIBean.TYPE_ key = entry.getKey(); |
| | | Log.i(TAG,"key= " + entry.getKey() + " and value= " + entry.getValue()); |
| | | if (mapInfoHead!=null){ |
| | | String str = mapInfoHead.getStr(); |
| | |
| | | entry.getKey()== BaseDataUIBean.TYPE_.car?"更新车辆模型":(entry.getKey()== BaseDataUIBean.TYPE_.road?"更新道路地图":"更新场地地图") |
| | | ,1, entry.getKey())); |
| | | if (str.contains("失败")){ |
| | | showMannualMapCar(); |
| | | showMannualMapCar(key); |
| | | |
| | | } |
| | | }else{ |
| | | showMannualMapCar(); |
| | | Log.i(TAG,"TextUtils.isEmpty(str)"); |
| | | showMannualMapCar(key); |
| | | } |
| | | }else{ |
| | | showMannualMapCar(); |
| | | Log.i(TAG,"mapInfoHead == null"); |
| | | showMannualMapCar(key); |
| | | } |
| | | |
| | | |
| | | } |
| | | }else{ |
| | | showMannualMapCar(); |
| | | Log.i(TAG,"hashMaps == null"); |
| | | showMannualMapCar(null); |
| | | } |
| | | |
| | | gpsInfoAdapter.addAll(datas); |
| | |
| | | } |
| | | }; |
| | | |
| | | private void showMannualMapCar() { |
| | | private void showMannualMapCar(BaseDataUIBean.TYPE_ key) { |
| | | String roadMapPath = ExamPlatformData.getInstance().getRoadMapPath(); |
| | | String MapPath = ExamPlatformData.getInstance().getMapPath(); |
| | | String carModelPath = ExamPlatformData.getInstance().getCarModelPath(); |
| | | if (!TextUtils.isEmpty(roadMapPath)){ |
| | | datas.add(new BaseDataUIBean(str2SpannableString("手动设置道路 "),R.mipmap.platform_pic,str2FouregourdSpannableString(roadMapPath),"",1,null)); |
| | | if (key == null){ |
| | | if (!TextUtils.isEmpty(roadMapPath)){ |
| | | datas.add(new BaseDataUIBean(str2SpannableString("手动设置道路 "),R.mipmap.platform_pic,str2FouregourdSpannableString(roadMapPath),"",1,null)); |
| | | } |
| | | if (!TextUtils.isEmpty(MapPath)){ |
| | | datas.add(new BaseDataUIBean(str2SpannableString("手动设置场地 "),R.mipmap.platform_pic,str2FouregourdSpannableString(MapPath),"",1,null)); |
| | | } |
| | | if (!TextUtils.isEmpty(carModelPath)){ |
| | | datas.add(new BaseDataUIBean(str2SpannableString("手动设置车辆 "),R.mipmap.platform_pic,str2FouregourdSpannableString(carModelPath),"",1,null)); |
| | | } |
| | | }else{ |
| | | if (key == BaseDataUIBean.TYPE_.car){ |
| | | datas.add(new BaseDataUIBean(str2SpannableString("手动设置车辆 "),R.mipmap.platform_pic,str2FouregourdSpannableString(carModelPath),"",1,null)); |
| | | } if (key == BaseDataUIBean.TYPE_.road){ |
| | | datas.add(new BaseDataUIBean(str2SpannableString("手动设置道路 "),R.mipmap.platform_pic,str2FouregourdSpannableString(roadMapPath),"",1,null)); |
| | | } if (key == BaseDataUIBean.TYPE_.yard){ |
| | | datas.add(new BaseDataUIBean(str2SpannableString("手动设置场地 "),R.mipmap.platform_pic,str2FouregourdSpannableString(MapPath),"",1,null)); |
| | | } |
| | | } |
| | | if (!TextUtils.isEmpty(MapPath)){ |
| | | datas.add(new BaseDataUIBean(str2SpannableString("手动设置场地 "),R.mipmap.platform_pic,str2FouregourdSpannableString(MapPath),"",1,null)); |
| | | } |
| | | if (!TextUtils.isEmpty(carModelPath)){ |
| | | datas.add(new BaseDataUIBean(str2SpannableString("手动设置车辆 "),R.mipmap.platform_pic,str2FouregourdSpannableString(carModelPath),"",1,null)); |
| | | } |
| | | |
| | | |
| | | } |
| | | |
| | | |