What is the difference between rollover and mouse?

In flex, what is the difference between rollover and mouseover?

the first rollover occurs, then the mouse cursor, then shutdown, then deployment. When are these events most suitable?

+6
source share
2 answers

From the AS3 documentation :

The mouseOver event is dispatched every time the mouse enters the area of ​​any child object of the display object container, even if the mouse was already above another child object of the display object container. This is a different behavior than the purpose of the rollOver event, which simplifies the coding of deployment behavior for display object containers with children. When the mouse enters an area of ​​a display object or an area of ​​any of its children from an object that is not one of its children, the display object dispatches a rollOver event. RollOver events are dispatched sequentially along the parent chain of the object, starting with the highest parent, which is neither the root nor the ancestor of the associated object and ends with the object.

+8
source

here is a good example that shows the difference between rollover and mouseover

example2

+7
source

Source: https://habr.com/ru/post/895128/


All Articles