This commit is contained in:
wangcongtao
2020-12-07 16:30:37 +08:00
parent 1557af276b
commit e1082ac994
15 changed files with 197 additions and 72 deletions

View File

@@ -171,7 +171,7 @@ public class AMapNaviViewWrapper implements IMogoMapView,
}
mMapView.setRouteOverlayVisible( false );
mMapView.setCarOverlayVisible( false );
setUIMode( EnumMapUI.CarUp_2D, null );
setUIMode( EnumMapUI.NorthUP_2D, null );
}
private void initListeners() {

View File

@@ -16,6 +16,7 @@ import com.amap.api.maps.model.animation.AnimationSet;
import com.amap.api.maps.model.animation.ScaleAnimation;
import com.amap.api.maps.model.animation.TranslateAnimation;
import com.amap.api.maps.utils.overlay.MovingPointOverlay;
import com.autonavi.amap.mapcore.IPoint;
import com.mogo.commons.AbsMogoApplication;
import com.mogo.map.MogoLatLng;
import com.mogo.map.impl.amap.AMapWrapper;
@@ -517,4 +518,11 @@ public class AMapMarkerWrapper implements IMogoMarker, Observer {
}
return mMarker.isInfoWindowShown();
}
@Override
public void setGps( boolean isGps ) {
MarkerOptions options = mMarker.getOptions();
options.setGps( isGps );
mMarker.setMarkerOptions( options );
}
}

View File

@@ -485,4 +485,11 @@ public class AMapMarkerWrapper implements IMogoMarker, Observer {
public boolean isInfoWindowShowing() {
return mMarker.isInfoWindowShown();
}
@Override
public void setGps( boolean isGps ) {
if ( mMarker != null ) {
mMarker.setGps( isGps );
}
}
}

View File

@@ -3,6 +3,8 @@ package com.mogo.map;
import android.os.Parcel;
import android.os.Parcelable;
import java.util.Objects;
/**
* @author congtaowang
* @since 2019-12-18
@@ -40,6 +42,21 @@ public class MogoLatLng implements Parcelable {
return lon;
}
@Override
public boolean equals( Object o ) {
if ( this == o ) return true;
if ( o == null || getClass() != o.getClass() ) return false;
MogoLatLng latLng = ( MogoLatLng ) o;
return Double.compare( latLng.lat, lat ) == 0 &&
Double.compare( latLng.lon, lon ) == 0;
}
@Override
public int hashCode() {
return Objects.hash( lat, lng, lon );
}
@Override
public String toString() {
return "MogoLatLng{" +

View File

@@ -324,4 +324,10 @@ public interface IMogoMarker {
* @return
*/
boolean isInfoWindowShowing();
/**
* 设置是否是gps
* @param isGps
*/
void setGps(boolean isGps);
}