[Proto-Scripty] Re: mouseenter mouseleave: tooltip not hiding

2009-10-30 Thread david
Hi Kupido, When writting: Event.observe(element, 'mouseenter', mouseEnter.bindAsEventListener (element)); When writting bindAsEventListener, it means that your binded function will have its scope set to element. So your called fiunction should be: function mouseEnter(event) {

[Proto-Scripty] Re: mouseenter mouseleave: tooltip not hiding

2009-10-30 Thread Kupido
Hi david, thank you for your reply. The element argument in my previous post was a copy/paste error, here's a simplified working version of my code: function init() { var boxes = $('boxes'); boxes.select('.box').each( function (box) {

[Proto-Scripty] Re: mouseenter mouseleave: tooltip not hiding

2009-10-30 Thread Kupido
After some testing I noticed the problem only occurs when I use: tooltip.appear(); // scriptaculous effect insted of: tooltip.show(); Any suggestions? On Oct 30, 11:37 am, Kupido kup...@hotmail.com wrote: Hi david, thank you for your reply. The element argument in my previous post was a

[Proto-Scripty] Re: mouseenter mouseleave: tooltip not hiding

2009-10-30 Thread Kupido
After some testing I noticed the problem only occurs when I use: tooltip.appear(); // scriptaculous effect instead of: tooltip.show(); Any suggestions? On Oct 30, 11:37 am, Kupido kup...@hotmail.com wrote: Hi david, thank you for your reply. The element argument in my previous post was a

[Proto-Scripty] Re: mouseenter mouseleave: tooltip not hiding

2009-10-30 Thread david
Hi Kupido, the mouseleave event is a hide which set display property to none; And the mouseenter event is an appear, which set opacity from 0 to 1. So when the element is hide, there is no way to appear again, because they don't change the same property. This could explain why event is still

[Proto-Scripty] Re: mouseenter mouseleave: tooltip not hiding

2009-10-30 Thread Kupido
I think I solved the problem using effect queues, this is the new code: function init() { var boxes = $('boxes'); boxes.select('.box').each( function (box) { var tooltip = box.down('.tooltip');

[Proto-Scripty] Re: mouseenter mouseleave: tooltip not hiding

2009-10-30 Thread david
Hi Kupido, This is a good way to do this. Just a suggestion, if the tooltip appear, let it des-appear sloowly too. so don't just hide() it, but do an effect to do this :)) -- david On 30 oct, 12:58, Kupido kup...@hotmail.com wrote: I think I solved the problem using effect queues, this is the

[Proto-Scripty] Re: mouseenter mouseleave: tooltip not hiding

2009-10-30 Thread Kupido
Hi david, I'll consider using fade instead of hide, thank you again for your help! On Oct 30, 1:02 pm, david david.brill...@gmail.com wrote: Hi Kupido, This is a good way to do this. Just a suggestion, if the tooltip appear, let it des-appear sloowly too. so don't just hide() it, but do an