MACROMEDIA DIRECTOR MX 2004-DIRECTOR SCRIPTING Reference page 819

Director scripting reference
Table of Contents

Advertisement

-- Lingo syntax
on prepareMovie
keyDownScript = "checkKey"
end
on checkKey
if (_key.key = "q") then _movie.go("Main Menu")
end if
end
// JavaScript syntax
function prepareMovie() {
keyDownScript = checkKey();
}
function checkKey() {
if (_key.key == "q") {
_movie.go("Main Menu");
}
}
This
on keyDown
handler:
addNumbers
-- Lingo syntax
on keyDown
if (_key.key = "z") then addNumbers
end
// JavaScript syntax
function keyDown() {
if (_key.key == "z") {
addNumbers();
}
}
See also
commandDown,
keyboardFocusSprite
Usage
-- Lingo syntax
_movie.keyboardFocusSprite
// JavaScript syntax
_movie.keyboardFocusSprite;
Description
Movie property; lets the user set the focus for keyboard input (without controlling the cursor's
insertion point) on a particular text sprite currently on the screen. Read/write.
This is the equivalent to using the Tab key when the
is selected.
Setting
keyboardFocusSprite
0 disables keyboard entry into any editable sprite.
handler checks whether the last key pressed is the z key and if it is, calls the
Key
to -1 returns keyboard focus control to the Score, and setting it to
property of the cast member
autoTab
keyboardFocusSprite
on
819

Hide quick links:

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the DIRECTOR MX 2004-DIRECTOR SCRIPTING and is the answer not in the manual?

Questions and answers

This manual is also suitable for:

Director mx 2004

Table of Contents