diff options
Diffstat (limited to 'platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/annotations/Marker.java')
-rw-r--r-- | platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/annotations/Marker.java | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/annotations/Marker.java b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/annotations/Marker.java index d24f020a18..38c8373104 100644 --- a/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/annotations/Marker.java +++ b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/annotations/Marker.java @@ -3,6 +3,7 @@ package com.mapbox.mapboxsdk.annotations; import android.support.annotation.NonNull; import android.support.annotation.Nullable; import android.view.View; + import com.mapbox.mapboxsdk.R; import com.mapbox.mapboxsdk.geometry.LatLng; import com.mapbox.mapboxsdk.maps.MapView; @@ -41,7 +42,7 @@ public class Marker extends Annotation { title = baseMarkerOptions.title; } - Marker(BaseMarkerViewOptions baseMarkerViewOptions){ + Marker(BaseMarkerViewOptions baseMarkerViewOptions) { position = baseMarkerViewOptions.position; snippet = baseMarkerViewOptions.snippet; icon = baseMarkerViewOptions.icon; @@ -72,6 +73,8 @@ public class Marker extends Annotation { /** * Do not use this method. Used internally by the SDK. + * + * @return true if the infoWindow is shown */ public boolean isInfoWindowShown() { return infoWindowShown; @@ -126,7 +129,7 @@ public class Marker extends Annotation { * Update only for default Marker's InfoWindow content for Title and Snippet */ private void refreshInfoWindowContent() { - if (isInfoWindowShown() && mapView != null && mapboxMap != null && mapboxMap.getInfoWindowAdapter() == null) { + if (isInfoWindowShown() && mapView != null && mapboxMap != null && mapboxMap.getInfoWindowAdapter() == null) { InfoWindow infoWindow = getInfoWindow(mapView); if (mapView.getContext() != null) { infoWindow.adaptDefaultMarker(this, mapboxMap, mapView); @@ -140,6 +143,10 @@ public class Marker extends Annotation { /** * Do not use this method. Used internally by the SDK. + * + * @param mapboxMap the hosting mapbox map + * @param mapView the hosting map view + * @return the info window that was shown */ public InfoWindow showInfoWindow(@NonNull MapboxMap mapboxMap, @NonNull MapView mapView) { setMapboxMap(mapboxMap); @@ -177,6 +184,8 @@ public class Marker extends Annotation { /** * Do not use this method. Used internally by the SDK. + * + * @param topOffsetPixels the top offset pixels. */ public void setTopOffsetPixels(int topOffsetPixels) { this.topOffsetPixels = topOffsetPixels; @@ -184,6 +193,8 @@ public class Marker extends Annotation { /** * Do not use this method. Used internally by the SDK. + * + * @param rightOffsetPixels the right offset pixels. */ public void setRightOffsetPixels(int rightOffsetPixels) { this.rightOffsetPixels = rightOffsetPixels; |