Wednesday, June 26, 2013

Tip of the Day: ADF - How to show/hide af:popup on mouse hover?

Question: How to show/hide af:popup on mouse hover?

Answer: Many times in our projects there is a requirement to display a popup on mouse hover and hide it on mouse out.
To achieve this functionality we use af:showPopupBehavior with its property triggerType=”mouseOver”. The problem here is that the popup is shown when we hover the mouse on the component but it is not hidden until we perform a click action outside the pop up. This problem can simply be resolved by changing af:showPopupBehavior’s property - triggerType=”mouseHover”. The “mouseHover” value for the triggerType property is not present by default in the drop down.

thanks to Kailash Sadwani for the tip!