Adobe 38039927 - Fireworks CS3 - PC Extended User Manual page 274

Extending fireworks
Hide thumbs Also See for 38039927 - Fireworks CS3 - PC:
Table of Contents

Advertisement

ADOBE FIREWORKS CS3
270
Extending Guide
Note: On multiuser systems, Fireworks supports a Command Panels folder inside of each user's Configuration folder,
so users can save favorite panels.
At runtime, Fireworks starts Flash Player, which either plays Shockwave animations or runs commands (if the user
selects the custom command options). The Align panel (Window > Align menu option) is an example of how Flash
panels work in the Fireworks interface.
Embedding API commands
You can call any part of the Fireworks API by embedding the API commands in the following functions. These
functions communicate directly with Adobe Flash Player, which is distributed with Fireworks.
MMExecute()
Usage
MMExecute(jsToPass)
Arguments
A string of JavaScript for Fireworks to execute.
jsToPass
Returns
Nothing.
Description
Declares a set of JavaScript code to pass to the Fireworks API, allowing Flash authors to embed Fireworks API
commands in a frame of a Flash movie.
Note:
supersedes the
t command. However, the
command still works in the
MMExecute
FWJavascrip
FWJavascript
current version of Fireworks.
The commands should be embedded in the same way that you would write separate JavaScript code blocks to
perform similar operations, and you can concatenate lines of JavaScript code into one
function.
MMExecute()
Example
The following example concatenates two lines of JavaScript code into one command:
MMExecute("dom=fw.getDocumentDOM();dom.addNewRectanglePrimitive({left:47, top:26,
right:102, bottom:87}, 0");
MMEndCommand()
Usage
MMEndCommand(endStatus, notifyString)
Arguments
A Boolean value:
to commit changes;
otherwise. If it is set to
, any pending changes
endStatus
true
false
false
are discarded. To commit the changes,
must be set to
.
endStatus
true
A string to notify the user of errors. If the value of
is
, this argument holds a
notifyString
endStatus
false
string used to notify the user of the error. If
is set to
,
is an empty string.
endStatus
true
notifyString

Advertisement

Table of Contents
loading

This manual is also suitable for:

Fireworks cs3

Table of Contents