Skip to content

Instantly share code, notes, and snippets.

@fdansv
Created October 23, 2013 01:03
Show Gist options
  • Save fdansv/7110812 to your computer and use it in GitHub Desktop.
Save fdansv/7110812 to your computer and use it in GitHub Desktop.
MapBox Android simplest app
import com.mapbox.MapBoxView
public class SimpleMapBoxExample extends ApplicationContext {
MapBoxView map;
protected void onCreate(Bundle savedInstanceState){
super.onCreate(savedInstanceState);
// We can initialize the map with the MapBox name, coordinates and zoom level
map = new MapBoxView("examples.map-9ijuk24y", 42.65742, 2.347682, 12);
// We now set the map as the View for our Activity
this.setContentView(map);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment