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

      0  

    Default Unanswered: List with video

    Unanswered: List with video


    I'm trying create a list with xtype video inside, but i am not getting.

    i tried to use a defaultType on dataview but i need to use grouped and in there this don't work.

    My test:

    list
    Code:
    {
       xtype: 'list',
       disableSelection: true,
       flex: 1,
       useComponents: true, 
       defaultType: 'profilefavoritesitem',
       grouped: true
    }
    dataitem
    Code:
    Ext.define('Reed.view.Profile.Favorites.Item', {
        extend: 'Ext.dataview.component.DataItem',
        requires: ['Ext.Container'],
        xtype: 'profilefavoritesitem',
        
        config: {
            nameButton: true,
    
    
            dataMap: {
                getNameButton: {
                    setHtml: 'name'
                }
            }
        },
    
    
        applyNameButton: function(config) {
            return Ext.factory(config, Ext.Container, this.getNameButton());
        },
    
    
        updateNameButton: function(newNameButton, oldNameButton) {
            if (oldNameButton) {
                this.remove(oldNameButton);
            }
    
    
            if (newNameButton) {
                this.add(newNameButton);
            }
        }
    });
    In the list if i change the xtype list to dataview the item works, but the group disappears.

    Anybody can help me?

    Thanks,
    []s

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    St. Louis, MO
    Posts
    33,714
    Vote Rating
    436
    Answers
    3113
    mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of mitchellsimoens has much to be proud of

      0  

    Default


    Currently, components within lists is not supported and the docs will be updated to say useComponents is not a config option.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    http://www.JSONPLint.com - Source to lint your JSONP!

    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 almost in print!

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

  3. #3
    Sencha - Sencha Touch Dev Team rdougan's Avatar
    Join Date
    Oct 2008
    Posts
    1,156
    Vote Rating
    4
    Answers
    93
    rdougan is on a distinguished road

      0  

    Default


    Yeah - a easy way to get around this is to extend DataView and then simply set your baseCls to 'x-list'.
    Sencha Inc.
    Robert Dougan - @rdougan
    Sencha Touch 2 and Ext JS 4 Core Team Member, SASS/Theming Wizard.