Coder Social home page Coder Social logo

titanium-mapbox-android's Introduction

Mapbox Android SDK Wrapper for Titanium

Uses the mbpages branch of the Mapbox Android SDK.

Current State of Development

This is a work in progress,

  • Uses the example map examples.map-i87786ca.
  • For the current iteration, the goal is to expose some API’s from ti.map for setting the location, zoom, and markers.

Source & Test App

The root of this repo contains the module source code and the test app respectively.

Example

var mapbox = require('flg.mapbox');

var mapView = mapbox.createMapView({
	width : Titanium.UI.FILL,
	height : Titanium.UI.FILL,
	top : 3,
	bottom : 3,
	left : 3,
	right : 3,
	region : {
		latitude : 39.743878,
		longitude :  -105.020118,
		latitudeDelta : 0.0005,
		longitudeDelta : 0.0005
	},
	userLocation : showUserLocation
});

win.add(mapView);
win.open();

Properties

region

Dictionary with keys:

  • latitude
  • longitude
  • latitudeDelta
  • longitudeDelta

userLocation

Boolean, show or hide the current location on the map.

annotations

Array of dictionaries with keys:

  • title
  • subtitle
  • latitude
  • longitude

Methods

setRegion

setUserLocation

setAnnotations

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.