Skip to content

Instantly share code, notes, and snippets.

@otarza
Created July 5, 2012 12:48
Show Gist options
  • Save otarza/3053501 to your computer and use it in GitHub Desktop.
Save otarza/3053501 to your computer and use it in GitHub Desktop.
Titanium.Geolocation.getCurrentPosition(function (e) {
if (e.success && e.coords) {
webview.evalJS("reloadMap(" + JSON.stringify(e.coords) + ")");
var banksJson = require('mapsAjax').banksJson;
banksJson(function (points) {
webview.evalJS("putMarker(" + JSON.stringify(points) + ")");
});
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment