constructs polyline object, ready to rock JNI #1716

This commit is contained in:
Nicholas Hallahan
2015-07-15 12:29:57 -07:00
parent 297190ecf1
commit 6335aecfad
3 changed files with 5 additions and 5 deletions

View File

@@ -10,6 +10,7 @@ public abstract class MultiPoint extends Annotation {
List<LatLng> points;
public MultiPoint() {
super();
points = new ArrayList<>();
}

View File

@@ -10,7 +10,6 @@ public class Polyline extends MultiPoint {
int color = Color.BLACK; // default color is black
float width = 10; // As specified by Google API Docs (in pixels)
List<LatLng> points;
public Polyline() {
super();

View File

@@ -300,10 +300,10 @@ public class MainActivity extends ActionBarActivity {
String geojsonStr = Util.loadStringFromAssets(this, "tillicum.geojson");
LatLng[] latLngs = Util.parseGeoJSONCoordinates(geojsonStr);
MapView map = mMapFragment.getMap();
// Polyline line = map.addPolyline(new PolylineOptions()
// .add(new LatLng(51.5, -0.1), new LatLng(40.7, -74.0))
// .width(5)
// .color(Color.RED));
Polyline line = map.addPolyline(new PolylineOptions()
.add(new LatLng(51.5, -0.1), new LatLng(40.7, -74.0))
.width(5)
.color(Color.RED));
} catch (IOException e) {
e.printStackTrace();
} catch (JSONException e) {