Recently, a flex propertygrid is to be created. The attribute display method does not use the traditional propertygird display method, but the main user behavior must be consistent with the traditional propertygrid.
Propertygrid is divided into two states: "floating" and "embedded ". When the status is suspended and the mouse moves to the property mini tab, The propertygrid main form is displayed to hide the mini tab. When the mouse moves out of the propertygrid main form, the window is closed and the Mini tab is displayed.
It is a habit to select a mouseout event, that is, to register a mouseout event for propertygird. When the mouse moves out, the propertygrid is disabled. However, tests show that when this event is used, the window is closed even if the mouse is not removed from the propertygrid. Finally, you have to writeProgramTest results show that if the propertygrid contains other controls, moving the mouse over these controls triggers the mouseout and Mouseover events, resulting in a previous logic error.
If rolout and rolover events are used, no logical problems will occur.
The difference is that the rolover and rolout events are triggered only when the mouse moves to and from the component listening to the event, but not when the mouse moves to and from its child components. The Mouseover and mouseout events are triggered when the mouse moves to and from the components listening for this event and the child components.
TestCodeSee Flash View Source.
For test results, see flash. Move the cursor over the Panel, and the DataGrid displays the event information.
Flash link: http://files.cnblogs.com/jingtao/OnMouseOutTest.rar
OriginalArticle, Reprinted, please indicate the source!
All copyright reserved!
Home: http://jingtao.cnblogs.com
QQ: 307073463
Email: jingtaodeemail@qq.com
MSN: sunjingtao@live.com