1. #1
    Sencha User
    Join Date
    Jul 2011
    Posts
    15
    Vote Rating
    0
    ispypie is on a distinguished road

      0  

    Default Unanswered: Google Maps Very Slow

    Unanswered: Google Maps Very Slow


    Hi
    I am trying to display a google map as part of my ui. Basically it is just taking an absolute age (minutes) to render the map. I get a grey box with some google text where the map should be and then go and make myself a coffee and maybe if I am lucky I may have a part of a map when I return. Eventually it does (most of the time) render the map.

    I searched around and found the gmap panel for v3 of the maps api. I had same issue so then created my own panel with the following in afterRender taken from GmapPanel and google maps sample.

    PHP Code:
       afterRender: function () {
     
            
    this.callParent(arguments);
     
            var 
    myOptions = {
                
    center: new google.maps.LatLng(-34.397150.644),
                
    zoom8,
                
    mapTypeIdgoogle.maps.MapTypeId.ROADMAP
            
    };
            var 
    map = new google.maps.Map(this.body.dommyOptions);

            
    google.maps.event.addListener(map'load', function () {
                
    console.log('loaded map');
            });
     
        }, 
    Its still the same. Has anyone had similar issue or any idea what may be the issue?

    Thanks

    Mark

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    37,642
    Vote Rating
    899
    Answers
    3574
    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


    Are you using the extension from Ext JS 3 or 4?
    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
    Jul 2011
    Posts
    15
    Vote Rating
    0
    ispypie is on a distinguished road

      0  

    Default


    I was using the version below to work with V3 of the maps api but then I copied the code I posted above from this extension into my own panel just to try and get a bare bones map rendered. I got the impression the panel shipped with Extjs4 works with maps api v2.
    https://github.com/VinylFox/ExtJS.ux.GMapPanel

    Sorry think I misread the question I should have said in original post I am using Extjs 4.

    thanks

    Mark

  4. #4
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    37,642
    Vote Rating
    899
    Answers
    3574
    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


    The version on his blog is for Ext JS 3 which probably won't work well in Ext JS 4.
    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
    Jul 2011
    Posts
    15
    Vote Rating
    0
    ispypie is on a distinguished road

      0  

    Default


    I am guessing people are using maps in 4??
    Really I am just trying to figure out whether there's an issue there or its something I am doing that's causing an issue. Even when I just try to initialise the app with the map in the viewport (rather than nested further down) it still behaves the same. I am still pretty new to Ext and first time working with maps so wonder whether there is something I am missing.

  6. #6
    Sencha Premium Member lorezyra's Avatar
    Join Date
    Dec 2007
    Location
    Japan -- 日本
    Posts
    638
    Vote Rating
    18
    Answers
    9
    lorezyra will become famous soon enough lorezyra will become famous soon enough

      0  

    Default


    Look here for the latest version of GMapPanel...

    http://www.sencha.com/forum/showthre...t-JS-4-running
    Perfection as a goal is a nice idea that can point one in a specific direction. However, since "perfection" is an ever changing (evolving?) and moving target, one must admit that perfection can never be obtained...

    When in doubt, check the d4mn source code!
    ================================================
    And here are my terms...
    1. I don't care if you use my source code. (Known as "Code.")
    2. I don't care if I get any monetary compensation.
    3. I do care to receive credit for Code provided. So, please keep my name in the comments for Code provided.
    4. Code is provided without warranty "AS-IS" and I claim absolutely no warranty nor liability to the quality, security, and run-ability on any platform.
    5. By using Code, you accept all risk inherit with Code regardless if Code has known and yet to be discovered bugs.
    6. You are welcome to change and improve the Code to best meet your needs.
    7. I don't care if you use the Code in a commercial or open-source project.
    8. You are not required to contact me prior to using the Code.
    ================================================
    Simple. Enjoy.

  7. #7
    Sencha User
    Join Date
    Jul 2011
    Posts
    15
    Vote Rating
    0
    ispypie is on a distinguished road

      0  

    Default


    Thanks lorezyra not sure why I didn't pick up that thread in my search. I am pretty sure that's the one I am using although those guys seem to have it working.

Thread Participants: 2