1. #1
    Sencha User
    Join Date
    Mar 2012
    Location
    Hyderabad
    Posts
    12
    Vote Rating
    0
    naseerkhan is on a distinguished road

      0  

    Default Unanswered: how to place a bubble on map using geolocation with onlocationupdatate event

    Unanswered: how to place a bubble on map using geolocation with onlocationupdatate event


    Hi friends i did a small program on placing a bubble on current location using updatelocation event but it shows only default location and also it does not place a bubble on that location.

    My code is

    first.js
    =====

    MapView = Ext.extend(Ext.Panel, {
    layout: 'card',
    initComponent: function() {
    this.map = new Ext.Map({
    useCurrentLocation: true,
    mapOptions : {
    zoom: 12,
    navigationControlOptions: {
    style: google.maps.NavigationControlStyle.SMALL
    }
    },
    geo: new Ext.util.GeoLocation({
    autoUpdate: false,
    timeout: 1000,
    listeners: {
    locationupdate: this.onLocationUpdate,
    scope: this,
    locationerror: function(geo) {
    console.log('Location update error.');
    }
    }
    })
    });

    this.items = this.map;

    MapView.superclass.initComponent.call(this);
    },


    onLocationUpdate: function(geo) {
    var position = new google.maps.LatLng(geo.latitude, geo.longitude);




    var infowindow = new google.maps.InfoWindow({
    content: 'test info text'
    });

    var marker = new google.maps.Marker({
    position: position,
    title : 'Your location!',
    map: this.map
    });
    }
    });

    It does not work properly. It does not show current location and also it doesnot place a bubble.

    Pls help me because i am new to this technology.

    And also i have one small doubt i.e

    when a person moving from one location to another location then automatically a bubble has to place at that location with the given time and also i need to draw a line among those bubbles.


    pls help me this is urgent for me.



    Thanks and Regards,
    Naseerkhan

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    35,677
    Answers
    3355
    Vote Rating
    749
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    Has the maprender event fired when the location is found?
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha User
    Join Date
    Mar 2012
    Location
    Hyderabad
    Posts
    12
    Vote Rating
    0
    naseerkhan is on a distinguished road

      0  

    Default


    Map displayed with default location. It calls only locationerror event but it is not reaching locationupdate event

    thats why it shows default location.

    I have one doubt i.e how to find whether maprender event has fired or not?

    I tried so many examples which are placed in the forum but those also not working

    I tested it on emulator only but i didn't test it in mobile.

    Pls tell me the solution for this.


    Thank in advance.

  4. #4
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    35,677
    Answers
    3355
    Vote Rating
    749
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    Ext.Map will fire a maprender event. You shouldn't try to add a marker or anything to the map until that is fired.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  5. #5
    Sencha User
    Join Date
    Mar 2012
    Location
    Hyderabad
    Posts
    12
    Vote Rating
    0
    naseerkhan is on a distinguished road

      0  

    Default


    Ok thank you

Thread Participants: 1

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar