修复了数据引起的marker

This commit is contained in:
董宏宇
2020-01-13 20:44:46 +08:00
parent b64197643e
commit ee2b4991b5
14 changed files with 127 additions and 126 deletions

View File

@@ -375,10 +375,10 @@ public class TanluCardViewFragment extends MvpFragment<IView, Presenter<IView>>
* @param exploreWay
*/
private void handleData(MarkerExploreWay exploreWay) {
if (exploreWay != null && exploreWay.getFileType() != null) {
if (exploreWay.getFileType().equals("0")) { //图片
if (exploreWay != null ) {
if (exploreWay.getFileType()==0) { //图片
refreshPhotoData(exploreWay);
} else if (exploreWay.getFileType().equals("1")) { //视频
} else if (exploreWay.getFileType()==1) { //视频
refreshVideoData(exploreWay);
}
} else {
@@ -483,10 +483,10 @@ public class TanluCardViewFragment extends MvpFragment<IView, Presenter<IView>>
//展示第一个数据
MarkerExploreWay markerExploreWay = markerExploreWayList.get(0);
if (markerExploreWay != null && markerExploreWay.getFileType() != null) {
if (markerExploreWay.getFileType().equals("0")) { //图片
if (markerExploreWay != null) {
if (markerExploreWay.getFileType()==0) { //图片
refreshPhotoData(markerExploreWay);
} else if (markerExploreWay.getFileType().equals("1")) { //视频
} else if (markerExploreWay.getFileType()==1) { //视频
refreshVideoData(markerExploreWay);
}
}

View File

@@ -10,7 +10,7 @@ import java.text.DecimalFormat;
public class Utils {
//处理距离大于1000时四舍五入保留一位小数
public static String handleDistance(long distance) {
public static String handleDistance(double distance) {
if (distance < 1000) {
return distance + "M";
} else {