c.
Browse to the flash_install_dir/Tutorials and Samples/Samples/Flash Lite/Sound/ and
select the file named hi_hat.mid.
i
d.
Click OK.
13.
Select Control > Test Movie to start the Flash Lite emulator and test your SWF file.
In the emulator, press the Down Arrow key on the keypad to give the Play button focus,
and then press the Select key to play the sound.
Triggering device sounds in Flash Lite 1.0
In Flash Lite 1.0, a device sound can only play in response to a user pressing a key on their
device. There are two ways to satisfy this constraint. One way is to attach the sound to the
Down frame in a button symbol's timeline. When the button has focus, and the user presses
the Select key on their device, Flash Lite plays the sound in the button's Down frame. For an
example of this technique, see
on page
51.
The other way to trigger a device sound in Flash Lite 1.0 is to have the user press a key that
sends the playhead to a frame in the timeline that contains a device sound. Any device sound
at that frame plays when the playhead enters the frame.
For example, suppose your application has a button on the Stage on Frame 1, and a
device sound attached to Frame 10. You attach the following
button instance:
on(press) {
gotoAndStop(10);
}
"Adding a device sound to a button (Flash Professional Only)"
Using device sound (Flash Professional Only)
handler to the
on(press)
53
Need help?
Do you have a question about the FLASH 8-DEVELOPING FLASH LITE and is the answer not in the manual?