Take the 2-minute tour ×  I am using phonegap, jquerymobile the
googlemap API to get my current position and to watch my
position.  For this, when I lunch my map page, my position is
shown with a marker and the marker move when I move. Even if it
works excpeted when I close my App (onPause).  Here is my code
(you can tell me how I can perfect it :o) )
$('#home').live("pagebeforeshow", function() {
if($('#googleAPI').length != 0){
//showMap('mapHome',position.coords.latitude,
position.coords.longitude);// Canvas, lat, long              var
latLng = new google.maps.LatLng(position.coords.latitude,positio
n.coords.longitude);              // Google Map options
var myOptions = {                 zoom: 17,
//zoomControl   : 1,                 center: latLng,
mapTypeId: google.maps.MapTypeId.ROADMAP////ROADMAP, SATELLITE,
HYBRID and TERRAIN              // Create the Google Map, set
options             Tracking.mapy = new
google.maps.Map(document.getElem