Backspace (Key.backspace Property); Capslock (Key.capslock Property) - MACROMEDIA FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE Reference

Actionscript 2.0 language reference
Table of Contents

Advertisement

Key.addListener(myListener);
my_btn.onPress = myOnPress;
my_btn._accProps.shortcut = "Ctrl+7";
Accessibility.updateProperties();
See also
getCode (Key.getCode method)
(Key.onKeyDown event listener)
removeListener (Key.removeListener method)

BACKSPACE (Key.BACKSPACE property)

public static BACKSPACE : Number
The key code value for the Backspace key (8).
Availability: ActionScript 1.0; Flash Player 5
Example
The following example creates a new listener object and defines a function for
The last line uses
addListener()
receive notification from the key down event.
var keyListener:Object = new Object();
keyListener.onKeyDown = function() {
if (Key.isDown(Key.BACKSPACE)) {
trace("you pressed the Backspace key.");
} else {
trace("you DIDN'T press the Backspace key.");
}
};
Key.addListener(keyListener);
When you use this example, be sure to select Control > Disable Keyboard Shortcuts in the test
environment.

CAPSLOCK (Key.CAPSLOCK property)

public static CAPSLOCK : Number
The key code value for the Caps Lock key (20).
Availability: ActionScript 1.0; Flash Player 5
,
isDown (Key.isDown method)
,
onKeyUp (Key.onKeyUp event listener)
to register the listener with the Key object so that it can
,
onKeyDown
,
onKeyDown
Key
.
673

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE and is the answer not in the manual?

Subscribe to Our Youtube Channel

This manual is also suitable for:

Flash 8

Table of Contents

Save PDF