Skip to content

Commit

Permalink
parsed coordinates from geojson, ready to add polyline via JNI mapbox…
Browse files Browse the repository at this point in the history
  • Loading branch information
hallahan committed Jul 15, 2015
1 parent 7c5fde4 commit 82e88a6
Show file tree
Hide file tree
Showing 7 changed files with 4,156 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -64,5 +64,5 @@ public CircleOptions strokeWidth (float width) {
// public CircleOptions zIndex (float zIndex) {
//
// }

}
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,10 @@ public List<List<LatLng>> getHoles() {
return polygon.holes;
}

public Polygon getPolygon() {
return polygon;
}

public int getStrokeColor() {
return polygon.strokeColor;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,10 @@ public List<LatLng> getPoints() {
return polyline.points;
}

public Polyline getPolyline() {
return polyline;
}

public float getWidth() {
return polyline.width;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@
import com.mapbox.mapboxgl.annotations.Annotation;
import com.mapbox.mapboxgl.annotations.Marker;
import com.mapbox.mapboxgl.annotations.MarkerOptions;
import com.mapbox.mapboxgl.annotations.Polyline;
import com.mapbox.mapboxgl.annotations.PolylineOptions;
import com.mapbox.mapboxgl.geometry.LatLng;
import com.mapbox.mapboxgl.geometry.LatLngZoom;

Expand Down Expand Up @@ -221,6 +223,12 @@ public Marker addMarker(MarkerOptions markerOptions) {
return marker;
}

public Polyline addPolyline(PolylineOptions polylineOptions) {
Polyline polyline = polylineOptions.getPolyline();

return polyline;
}

public void removeAnnotation(Annotation annotation) {
long id = annotation.getId();
mNativeMapView.removeAnnotation(id);
Expand Down
Loading

0 comments on commit 82e88a6

Please sign in to comment.