• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL
Help

Chapter 14. Events > Button Events

Button Events

Table 14.1 shows events associated with buttons, but it is important to note that both the Button and the MovieClip classes of objects support events in frames, as well as in the object actions.

Table 14.1. Button Events
Event Handler Object ActionEvent Handler Frame MethodAction Description
on (press)onPressThe event triggered when a user presses a button
on (release)onReleaseThe event triggered when a user releases a button after pressing it
on (releaseOutside)onReleaseOutsideThe event triggered when a user releases the mouse button outside the hit area of a button that has received an onPress event
on (rollOver)onRollOverThe event triggered when a user's mouse cursor moves over a button without the mouse button being pressed
on (rollOut)onRollOutThe event triggered when a user moves the mouse cursor outside a button's hit area without the mouse button being suppressed
on (dragOver)onDragOverThe event triggered when a user moves the mouse cursor over a button's hit area after the button has received an onDragOut event
on (dragOut)onDragOutThe event triggered when the mouse cursor is moved outside the button's hit area while the mouse button is depressed
on (keyPress"...")onKeyDown, OnKeyUpThe event triggered when a user presses or releases a key on the keyboard that has been specified in the event
N/AonSetFocusThe event triggered when a button receives focus from a keyboard interaction (for example, if a user uses the Tab key to gain focus on the button)
N/AonKillFocusThe event triggered when a button loses keyboard focus



PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint