-
1 Sep 2010 8:40 AM #1
Question about the performance of the listeners and the handler
Question about the performance of the listeners and the handler
Hi,
I like to know, if I need a click event what do I need to use. the listeners or the handler?
Does the listeners take more performance?
Thanks,
Noam
-
1 Sep 2010 9:15 AM #2
handler is linked to button//menu
if you're looking on source code you can found the answer of your "question" :
I hope that this source code give to you some comprehension information !PHP Code:// private method of Ext.Button = Ext.extend(Ext.BoxComponent,...
onClick : function(e){
.......
this.fireEvent('click', this, e);
if(this.handler){
//this.el.removeClass('x-btn-over');
this.handler.call(this.scope || this, this, e);
}
}
},
For me, the only good information that have some interest, is that click event is called before handler method ))
-
1 Sep 2010 9:24 AM #3
I'm sorry for the misunderstanding, I have to be sure.
The example you give is proving that handler is better, right (when we lisen to 'click' event)?
Similar Threads
-
Any Check Item handler/listeners that fire after checked=true?
By Daz in forum Ext 3.x: Help & DiscussionReplies: 9Last Post: 11 Jun 2010, 7:39 AM -
What's the difference between handler: and listeners:
By borg in forum Ext 3.x: Help & DiscussionReplies: 3Last Post: 4 Dec 2009, 8:44 AM -
Observable listeners handler not fired
By StevenJ in forum Ext 2.x: Help & DiscussionReplies: 6Last Post: 19 May 2009, 11:48 PM -
Question about handler and listeners for a toolbar button
By dddu88 in forum Ext 2.x: Help & DiscussionReplies: 4Last Post: 14 Mar 2008, 6:33 AM -
Question about listeners in 1.0
By j555 in forum Ext 2.x: Help & DiscussionReplies: 1Last Post: 6 Mar 2007, 5:39 PM


Reply With Quote