1. #1
    Sencha User
    Join Date
    Apr 2009
    Posts
    14
    Answers
    1
    Vote Rating
    0
    Smeraldo is on a distinguished road

      0  

    Default Unanswered: Add a Map in a Tab Panel

    Unanswered: Add a Map in a Tab Panel


    Hi,

    how can I add a Map in a Tab Panel?

    Here is my code:

    Code:
    Ext.create("Ext.tab.Panel", {
        fullscreen: true,
        tabBarPosition: 'bottom',
        items: [
            {
                title: 'Home',
                iconCls: 'home',
                cls: 'home',
                scrollable: true,
                html: [
                    '<center><br>Welcome!</center>'
                ].join("")
            },
            {
                title: 'Map',
                iconCls: 'maps',
                scrollable: true,
                html: [
                    '<center><br>Map here...<br></center>'
                ].join("")
            },
            {
                xtype: 'nestedlist',
                title: 'Steps',
                iconCls: 'star',
                displayField: 'title',
                store: {
                    type: 'tree',
                    fields: [
                        'title', 'content',
                        {name: 'leaf', defaultValue: true}
                    ],
                    root: {
                        leaf: false
                    },
                    proxy: {
                        type: 'ajax',
                        url: 'steps.json',
                        reader: {
                            type: 'json',
                            rootProperty: 'steps'
                        }
                    }
                },
                detailCard: {
                    xtype: 'panel',
                    scrollable: true,
                    styleHtmlContent: true
                },
                listeners: {
                    itemtap: function(nestedList, list, index, element, post) {
                        this.getDetailCard().setHtml(post.get('content'));
                    }
                }
            }
        ]
    });
    I need to insert a Map with markers in the second tab of my Panel.

    Thanks in advance!

  2. #2
    jay@moduscreate.com's Avatar
    Join Date
    Mar 2007
    Location
    Frederick MD, NYC, DC
    Posts
    16,353
    Answers
    102
    Vote Rating
    79
    jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all

      0  

    Default


    use the map component there. There is an example showing you how to do it.

  3. #3
    Sencha User
    Join Date
    Apr 2009
    Posts
    14
    Answers
    1
    Vote Rating
    0
    Smeraldo is on a distinguished road

      0  

    Default


    Quote Originally Posted by jay@moduscreate.com View Post
    use the map component there. There is an example showing you how to do it.
    Thanks, but... where can I find the example?

    I have found just this one: http://docs.sencha.com/touch/2-0/#!/example/maps

  4. #4
    Sencha User
    Join Date
    Apr 2009
    Posts
    14
    Answers
    1
    Vote Rating
    0
    Smeraldo is on a distinguished road

      0  

    Default


    If I do this:

    Code:
    Ext.create("Ext.tab.Panel", {
        //layout: 'card',
        fullscreen: true,
        tabBarPosition: 'bottom',
        items: [
            {
                title: 'Home',
                iconCls: 'home',
                cls: 'home',
                scrollable: true,
                html: [
                    '<center><br>Welcome<br></center>'
                ].join("")
            },
            {
                xtype: 'map',
                useCurrentLocation: true
            }
        ]
    });
    I receive this error from the console:

    Uncaught Error: [ERROR][Ext.Container#doAdd] Adding a card to a tab container without specifying any tab configuration

    Edit:

    adding "title" and "iconCls" I have no errors, but I have a blank area instead of the map...

    Here my code:


    Code:
    Ext.create("Ext.tab.Panel", {
        layout: 'card',
        fullscreen: true,
        tabBarPosition: 'bottom',
        items: [
            {
                title: 'Home',
                iconCls: 'home',
                cls: 'home',
                scrollable: true,
                html: [
                    '<center><br>Welcome<br></center>'
                ].join("")
            },
            {
                title: 'Map',
                iconCls: 'maps',
                xtype: 'map',
                useCurrentLocation: true
            }
        ]
    });

  5. #5
    Sencha User
    Join Date
    Oct 2013
    Posts
    7
    Vote Rating
    0
    lexan1982 is on a distinguished road

      0  

    Default


    I have blank area only at the iOS. In the Web and in the Android device all right.
    Why?

  6. #6
    Sencha User
    Join Date
    Oct 2013
    Posts
    7
    Vote Rating
    0
    lexan1982 is on a distinguished road

      0  

    Default


    I see example map
    1. sencha phonegap init
    2. sencha app build native
    3. at the Xcode project change config.xml
    Code:
    // disable it 
    //<access origin="http://127.0.0.1*" />
    
    <access origin="*" /> // work

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