Detailed instructions for use are in the User's Guide.
[. . . ] Extending Fireworks
Trademarks Afterburner, AppletAce, Attain, Attain Enterprise Learning System, Attain Essentials, Attain Objects for Dreamweaver, Authorware, Authorware Attain, Authorware Interactive Studio, Authorware Star, Authorware Synergy, Backstage, Backstage Designer, Backstage Desktop Studio, Backstage Enterprise Studio, Backstage Internet Studio, Contribute, Design in Motion, Director, Director Multimedia Studio, Doc Around the Clock, Dreamweaver, Dreamweaver Attain, Drumbeat, Drumbeat 2000, Extreme 3D, Fireworks, Flash, Fontographer, FreeHand, FreeHand Graphics Studio, Generator, Generator Developer's Studio, Generator Dynamic Graphics Server, Knowledge Objects, Knowledge Stream, Knowledge Track, LikeMinds, Lingo, Live Effects, MacRecorder Logo and Design, Macromedia, Macromedia Contribute, Macromedia Coursebuilder for Dreamweaver, Macromedia M Logo & Design, Macromedia Flash, Macromedia Xres, Macromind, Macromind Action, MAGIC, Mediamaker, Multimedia is the Message, Object Authoring, Power Applets, Priority Access, Roundtrip HTML, Scriptlets, SoundEdit, ShockRave, Shockmachine, Shockwave, shockwave. com, Shockwave Remote, Shockwave Internet Studio, Showcase, Tools to Power Your Ideas, Universal Media, Virtuoso, Web Design 101, Whirlwind and Xtra are trademarks of Macromedia, Inc. and may be registered in the United States or in other jurisdictions including internationally. Other product names, logos, designs, titles, words or phrases mentioned within this publication may be trademarks, servicemarks, or tradenames of Macromedia, Inc. or other entities and may be registered in certain jurisdictions including internationally. [. . . ] How event handlers work When a panel is launched and the Flash movie starts, Fireworks will scan the movie script for the presence of event handlers. If a handler is present, Fireworks automatically registers the function to receive the corresponding event. Fireworks only looks at the SWF file to see if it needs any of these events when the panel opens (when the SWF file runs).
92
Chapter 3: Cross-Product Extensions
Creating event handlers To create an event handler, implement a function with the corresponding event name. Currently, Fireworks supports the following events for Flash panels:
Event onFwStartMovie onFwStopMovie onFwUnitsChange onFwPICollapseOrExpand onFwDocumentNameChange onFwCurrentFrameChange onFwCurrentLayerChange onFwHistoryChange onFwApplicationDeactivate onFwApplicationActivate onFwSymbolLibraryChange onFwURLListChange onFwFavoritesChange onFwPreferencesChange onFwDocumentSizeChange onFwActiveViewChange onFwPixelSelectionChange onFwActiveSelectionChange onFwActiveDocumentChange onFwActiveToolParamsChange onFwActiveToolChange onFwZoomChange onFwObjectSettingChange Description Sent to the SWF file right after Fireworks has started (or restarted) the SWF file. Sent to the SWF file right before Fireworks stops the file (and possibly unloads it). Sent when the user changes the type of units (inches, pixels, centimeters) in the Info panel. Sent when the user switches the PI between two rows high and four rows high. Sent when the name of the current document changes (for example, when the user performs a save). Sent when the user selects a different frame. Sent when the user selects a different layer. Sent when the user creates an non-scriptable history step. Sent when the Fireworks application loses focus. Sent when the Fireworks application gains focus. Sent when the symbol library changes in some way. Sent when a new URL is added to the document. Sent when the favorite urls list is modified. This happens when the user changes focus in 2- or 4-Up view. Sent when the selection changes in a document. Sent when the user creates a new document, closes a document, opens a document, or switches between open documents. Sent when the user changes the tool stroke or fill attributes. Sent when the zoom setting for the current document changes. Sent when a stroke or fill setting is changed for the selected object.
Note: The event handler must be implemented in the global namespace. [. . . ] If it is null, the currently selected steps are used. Returns
Nothing.
Description
Copies history steps to the Clipboard. fw. historyPalette. getSelection()
Availability
Fireworks 3.
Usage fw. history. Palette. getSelection() Arguments
None.
Returns
A zero-based array that represents which History panel steps are selected.
Description
Determines which steps in the History panel are selected.
History panel functions
279
fw. historyPalette. getStepCount()
Availability
Fireworks 3.
Usage fw. historyPalette. getStepCount() Arguments
None.
Returns
The number of steps in the History panel (not a zero-based value).
Description
Gets the number of steps in the History panel. fw. historyPalette. getStepsAsJavaScript()
Availability
Fireworks 3.
Usage fw. historyPalette. getStepsAsJavaScript(rray of indexes) Arguments array of indexes A zero-based array that specifies which steps from the History panel should be returned as JavaScript. [. . . ]