Object | +-Button public class Button extends Object
All button symbols in a SWF file are instances of the Button object. You can give a button an instance name in the Property inspector, and use the methods and properties of the Button class to manipulate buttons with ActionScript. Button instance names are displayed in the Movie Explorer and in the Insert Target Path dialog box in the Actions panel.
The Button class inherits from the Object class.
|
Modifiers |
Property |
Description |
|---|---|---|
|
|
The alpha transparency value of the button specified by my_btn. |
|
|
|
A Boolean value that specifies whether a button is enabled. |
|
|
|
A Boolean value that specifies whether a button has a yellow rectangle around it when it has input focus. |
|
|
|
The height of the button, in pixels. |
|
|
|
Deprecated since Flash Player 7. This property was deprecated in favor of Button._quality. Specifies the level of anti-aliasing applied to the current SWF file. |
|
|
|
Instance name of the button specified by my_btn. |
|
|
|
A reference to the movie clip or object that contains the current movie clip or object. |
|
|
|
Property (global); sets or retrieves the rendering quality used for a SWF file. |
|
|
|
The rotation of the button, in degrees, from its original orientation. |
|
|
|
Specifies the number of seconds a sound prebuffers before it starts to stream. |
|
|
|
Specifies whether my_btn is included in automatic tab ordering. |
|
|
|
Lets you customize the tab ordering of objects in a SWF file. |
|
|
|
Returns the target path of the button instance specified by my_btn. |
|
|
|
A Boolean value that indicates whether other buttons or movie clips can receive a release event from a mouse or stylus. |
|
|
|
Retrieves the URL of the SWF file that created the button. |
|
|
|
A Boolean value that indicates whether the button specified by my_btn is visible. |
|
|
|
The width of the button, in pixels. |
|
|
|
An integer that sets the x coordinate of a button relative to the local coordinates of the parent movie clip. |
|
|
|
Returns the x hasMouse is true relative to the button. |
|
|
|
The horizontal scale of the button as applied from the registration point of the button, expressed as a percentage. |
|
|
|
The y coordinate of the button relative to the local coordinates of the parent movie clip. |
|
|
|
Returns the y coordinate of the mouse position relative to the button. |
|
|
|
The vertical scale of the button as applied from the registration point of the button, expressed as a percentage. |
Properties inherited from class Object
|
constructor (Object.constructor property), __proto__ (Object.__proto__ property), prototype (Object.prototype property), __resolve (Object.__resolve property) |
|
Event |
Description |
|---|---|
|
onDragOut = function() {} |
Invoked when the user presses the mouse button over the button and then drags the pointer outside of the button. |
|
onDragOver = function() {} |
Invoked when the user presses the mouse button outside of the button and then drags the pointer over the button. |
|
onKeyDown = function() {} |
Invoked when a button has keyboard focus and a key is pressed. |
|
onKeyUp = function() {} |
Invoked when a button has input focus and a key is released. |
|
onKillFocus = function(newFocus:Object) {} |
Invoked when a button loses keyboard focus. |
|
onPress = function() {} |
Invoked when a button is pressed. |
|
onRelease = function() {} |
Invoked when a button is released. |
|
onReleaseOutside = function() {} |
Invoked when the mouse is released with the pointer outside the button after the mouse button is pressed with the pointer inside the button. |
|
onRollOut = function() {} |
Invoked when the button loses focus. |
|
onRollOver = function() {} |
Invoked when the button gains focus. |
|
onSetFocus = function(oldFocus:Object) {} |
Invoked when a button receives keyboard focus. |
|
Modifiers |
Signature |
Description |
|---|---|---|
|
|
Returns the depth of the button instance. |
Methods inherited from class Object