开发者

Ext.Button into Ext.List Sencha Touch

开发者 https://www.devze.com 2023-04-06 10:34 出处:网络
I am new in Sencha Touch Can I add Ext.Button into a Ext.List i开发者_StackOverflowf yes then how Thanks

I am new in Sencha Touch

Can I add Ext.Button into a Ext.List

i开发者_StackOverflowf yes then how

Thanks Amit Battan


It's been discussed on the Sencha Forum...

http://www.sencha.com/forum/showthread.php?118790-Buttons-%28and-other-widgets%29-in-Ext.List-or-Ext.DataView


I don't think you can. Maybe it's possible but I'm sure very complicated. Do you need to add the button per list item or per list? If per list item, do you need to add more the one button?


From the question, as simple as it is, the only way that I have been able to get a button into a list is by creating a titlebar and docked to the top and in that titlebar having a button in it. This can be achieved in a view file.

   this.add({
                xtype: 'titlebar',
                docked: 'top',
                title: 'Courses',
                items:[{
                    xtype: 'button',
                    align: 'left',
                    iconCls: 'add',
                    iconMask: true,
                    handler: function(){
                        var panel = Ext.create('UniversityData.view.EntryForm');
                        panel.showBy(this);
                    }
                    }]
            });

This would go in your view's config section

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号