-
13 Jan 2013 10:42 PM #1
Answered: ExtJS 4.1 MVC detect splitbutton's menu's 'click' event
Answered: ExtJS 4.1 MVC detect splitbutton's menu's 'click' event
How can I detect the 'click' event of a splitbutton's menu in a controller?
For example,I have splitbutton
I cannot detect the button A or button B in controller like thisCode:{ xtype : 'splitbutton', icon-Cls: 'mycls', text: 'mysplitbutton', menu : { items : [ {text : 'button A',action : 'A'}, {text : 'button B',action : 'B'} ] } }
Code:....some code.... init : function(){ this.control({ 'button[action=A]' : { click : this.myFucntionToButtonA } }); }
-
Best Answer Posted by panbayi
Eh....,it's solves.I should have added 'xtype : "button" 'in each item property.
-
13 Jan 2013 11:53 PM #2
Eh....,it's solves.I should have added 'xtype : "button" 'in each item property.


Reply With Quote