in black and white
Main menu
Share a book About us Home
Biology Business Chemistry Computers Culture Economics Fiction Games Guide History Management Mathematical Medicine Mental Fitnes Physics Psychology Scince Sport Technics

macromedia flash mx - Reinhardt R.

Reinhardt R., Lott J macromedia flash mx - John Wiley & Sons, 2004. - 987 p.
ISBN 0-7645-4354-7
Download (direct link): macromediaflash2004.pdf
Previous << 1 .. 353 354 355 356 357 358 < 359 > 360 361 362 363 364 365 .. 419 >> Next

¶ Stand-alones are available only for Windows and the Macintosh. Although the Flash Player is available as a plug-in for Linux, you cannot run projectors on this fast-growing desktop platform. As of this writing, Flash Player 6 is the most current plug-in version available for the Linux platform.
Tip You can use the POST and GET methods with server-side scripts with Flash movies in a
Cross- The use of GET and POST methods with actions such as MovieClip.loadVariables() i s
Reference discussed in Chapter 9.
Now that youíve been able to think about the implications of stand-alone use, youíre ready to see the interactive commands that you can use specifically to control the stand-alone environment.
798 Part IX ¶ Working with Flash in Other Environments
Applying fscommand() Actions with Stand-Alones
The primary function for stand-alone interactivity is the fscommand() function, also known as the FSCommand. The fscommand() function enables you to control the viewable area and size of the Flash movie stage, prevent users from using the keyboard to access the system (such as using Ctrl+Q to quit the projector), and more. The next section provides a brief overview of the commands and arguments for the fscommand() function. You also explore some examples of their use.
The fscommand() is also used to communicate with client-side scripts (such as JavaScript and VBScript) in a Web browser. Refer to Chapter 31 for more information on this use of the function.
Overview of Commands and Arguments
The fscommand() function technically uses two arguments. The first argument is referred to as the command, whereas the second argument is the commandís argument. Both arguments of the fscommand() are string data types, as the following example illustrates:
fscommand("allowscale", "true");
In this example, "allowscale" i s the command, and "true" i s the argument for the allowscale command. From our experiments, we have found that you can also use Boolean data types for those commands that accept "true" or "false" as the commandís argument. Table 33-2 lists the commands and arguments available to the fscommand() for stand-alone use. This table has four categories into which the commands fall: those that control the viewing area (View), playback, key capture, and external application use.
Table 33-2: Summary of fscommands for Stand-Alones
Category Command Argument Description
View "allowscale" "true" This command controls whether the size of a
"false" movie's stage can be changed from that specified
in the Movie Properties (Modify Ů Document) dialog box in Flash MX 2004. If this command is used with a "true" argument, the user can resize the dimensions of the movie by expanding the projector window. The "false" argument disallows any change to the movie's size.
"fullscreen" "true" This command tells the stand-alone whether the
"false" movie should play in a window ("false") or
matted against a blank background that takes over the desktop ("true"). The color of the background matches the movie's background color, as set in the Movie Properties dialog box. Note that unless the allowscale command is used with a false argument prior to this command being executed, the movie's size will match that of the screen resolution.
Chapter 33 ¶ Scripting for the Flash Stand-Alone Player 799
Category Command Argument Description
Playback "showmenu" "true" "false" This command, when set to "true", allows the user to right-click (or Control-click on the Mac) the movie's stage to access the contextual menu for player control (see Figure 33-5). If this command is set to "false", the only options available in this menu are About Macromedia Flash Player 7 and Settings.
"quit" No arguments As the name implies, this command tells the stand-alone to exit or quit its application from running. This is equivalent to using File Ů Quit from the stand-alone application bar.
Key Capture "trapallkeys" "true" "false" This feature, when set to "true", enables you to prevent the user from using Ctrl-key combinations to exit or manipulate the standalone when the fscommand("fullscreen", "true") command is in use. Note that you must use ActionScript to capture all keypresses to enable keyboard features to the user. When set to "false", normal operation of the keyboard returns to the user.
External "exec" path to application This command enables you to execute local applications on the user's system. You can execute only applications or files that are located in a folder named fscommand, in the same location as the projector file. You can also specify BAT files (Windows) or AppleScript applets (Macintosh) as files. Note that paths use forward slashes (/) on Windows, and colon characters (:) on the Mac.
Note The fscommand() is a function, not a method of the MovieClip class. The fscommand()
controls global properties of the entire movie. Therefore, you do not need to specify an object prefix for the fscommand(), as in _root.fscommand(). This is incorrect syntax. Instead, you call the function directly, specifying the arguments, such as fscommand ("allowscale", "false");.
Previous << 1 .. 353 354 355 356 357 358 < 359 > 360 361 362 363 364 365 .. 419 >> Next