1. #1
    Sencha User
    Join Date
    Apr 2012
    Posts
    5
    Vote Rating
    0
    bhagdave is on a distinguished road

      0  

    Default Unanswered: iOS GeoLocation problems...

    Unanswered: iOS GeoLocation problems...


    Hi all,

    Have a problem with geolocation. Works fine on Chrome/Android but on iOS it works intermittently. It works sometimes and then nothing. The little arrow appears to say it is using GeoLocation but it does not find my location at all. Code below... Any assistance appreciated.

    this.app.geo = Ext.create('Ext.util.Geolocation', {
    autoUpdate: false,
    accuracy :1,

    scope: this,
    listeners: {
    locationupdate: function(geo) {me.geoUpdate.call(me,geo)},
    locationerror: function(geo, bTimeout, bPermissionDenied, bLocationUnavailable, message) {me.geoUpdate.call(me,geo, bTimeout, bPermissionDenied, bLocationUnavailable, message)}
    }
    });
    this.app.geo.updateLocation();

    geoUpdate: function(geo){
    if(this.view) {
    var lat = geo._latitude;
    var lng = geo._longitude;
    currentLocation = new google.maps.LatLng(lat, lng);
    this.map.setMapCenter(currentLocation);
    this.mapMoved();
    }
    },

    getError: function(geo, bTimeout, bPermissionDenied, bLocationUnavailable, message){
    console.log('getError',geo, bTimeout, bPermissionDenied, bLocationUnavailable, message);
    },

    =============== From the voiew being used ===============
    xtype: 'map',
    cls: 'map',
    itemId: 'personalMap',
    useCurrentLocation: false,
    mapOptions: {
    center: new google.maps.LatLng(51.507335, -0.127683),
    zoom: 16,
    disableDefaultUI: true,
    streetViewControl: false
    },
    listeners: {

    maprender: {
    single: true,
    scope: this,
    fn: function(map, gmap) {
    CabFix.app.getController('PersonalMap').mapRendered(map, gmap);
    }
    }
    }

  2. #2
    Ext JS Premium Member
    Join Date
    Oct 2007
    Location
    Herndon, VA
    Posts
    262
    Vote Rating
    1
    durlabh is on a distinguished road

      1  

    Default


    It is an iOS6 bug. Initial call works fine, all subsequent ones crash!

  3. #3
    Sencha User
    Join Date
    Apr 2012
    Posts
    5
    Vote Rating
    0
    bhagdave is on a distinguished road

      0  

    Default Thanks....

    Thanks....


    I do not know for certain but I thought I was having the same problem with iOS5....

Tags for this Thread