PDA

View Full Version : What's meaning of onMouseDown in Ext.form.TextField?



cyrilluce
10 Nov 2010, 12:41 AM
initEvents : function(){
...
if(this.selectOnFocus || this.emptyText){
this.mon(this.el, 'mousedown', this.onMouseDown, this);
...



onMouseDown: function(e){
if(!this.hasFocus){
this.mon(this.el, 'mouseup', Ext.emptyFn, this, { single: true, preventDefault: true });
}
},


I have google for the default action of mouseup, but found nothing.
What's meaning of these code? :-/

P.S.
I'm trying to find a proper solution for this bug (http://www.sencha.com/forum/showthread.php?114292-OPEN-1381-Click-TextField-while-a-menu-is-active-emptyText-remains.).