-
21 Feb 2009 4:04 PM #1
[FIXED][2.2.1 build 3186] onDocMouseDown in ToolTip reversed logic
[FIXED][2.2.1 build 3186] onDocMouseDown in ToolTip reversed logic
I believe that this code is in ToolTip.js to allow tooltips to close if the user clicks elsewhere in the document while the tip is open and autoHide is off.
Code:onDocMouseDown : function(e){ if(this.autoHide !== false && !e.within(this.el.dom)){ this.disable(); this.enable.defer(100, this); } }
However, for this to actually work, the line needs to be:
Without this change, the tip will not close if autohide is off, and if autohide is on the tip will close by itself regardless.Code:if(this.autoHide !== true && ...
Regards,
-scott
-
23 Feb 2009 10:41 PM #2
If we make that change, that means a tooltip with autoHide: false will get hidden when the user clicks the document. Or am I missing something?
Evan Trimboli
Sencha Developer
Twitter - @evantrimboli
Don't be afraid of the source code!
-
24 Feb 2009 7:00 AM #3
Yes, exactly.
Currently, if you don't have a close button and autoHide is false, there's no way to close the tooltip.
Clicking on the document to close the tooltip only when autoHide is true makes no sense, because as soon as you mouse off the object with the tooltip, the tooltip will go away anyways.
-
24 Feb 2009 8:16 AM #4
Right, I get you, fixed in SVN.
Evan Trimboli
Sencha Developer
Twitter - @evantrimboli
Don't be afraid of the source code!
-
24 Feb 2009 8:20 AM #5


Reply With Quote