1. #1
    Sencha User
    Join Date
    Feb 2012
    Posts
    26
    Vote Rating
    1
    MrBeef is on a distinguished road

      0  

    Default Linking map InfoWindow to Sencha function

    Linking map InfoWindow to Sencha function


    Hi all,

    I'm trying to place a link in a Google Maps InfoWindow that, when clicked, performs a function in Sencha Touch. Specifically, when clicked, I want to switch to another tab and populate a form.

    My function to perform the tab switch (this will also populate a form):
    Code:
    function windowLink()
        {
            tabs.setActiveItem(2);
        }
    Then in my InfoWindow content variable I create the following link, but it doesn't seem to work when clicked. I've also tried using the onclick property but with no luck. I would appreciate any suggestions, thanks!

    Code:
    var content = "<a href=\"javascript:windowLink();\">some text</a>";

  2. #2
    Sencha User
    Join Date
    Feb 2012
    Posts
    253
    Vote Rating
    0
    ci11111 is on a distinguished road

      0  

    Default


    not sure it's the best solution
    but you will have to put outside Ext.application
    var windowLink ;

    then inside your app:
    Code:
    windowLink = function()
        {
            tabs.setActiveItem(2);
        }
    and finally in your infowindow:
    '<a href="javascript:windowLink();">some text</a>'

  3. #3
    Sencha User
    Join Date
    Feb 2012
    Posts
    26
    Vote Rating
    1
    MrBeef is on a distinguished road

      0  

    Default Thanks!

    Thanks!


    That works! I guess it must be a variable scope issue.

Thread Participants: 1

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi