MACROMEDIA FLASH MX 2004-USING FLASH Use Manual page 459

Hide thumbs Also See for FLASH MX 2004-USING FLASH:
Table of Contents

Advertisement

Number; an integer used to set the control's position in the tab order (available only
tabindex
on Windows).
Child tags
<menupop>
Parent tag
<dialog>, <hbox>,
Description
Control tag; creates a pop-up menu control that contains
Example
The following example uses the JavaScript API to create a new
that appears on the Commands menu. This command is a simple version of the Convert to
Symbol dialog box that is on the Modify menu. Create two files, as described in this section, and
place them in your Commands folder in your user-level configuration folder. For more
information, see "Configuration folders installed with Flash" in Getting Started with Flash.
First, create a file named Convert to Symbol.jsfl and place it in your Commands folder. Place the
following code into the file and save the file:
// Create an XML to UI dialog box using the XML definition in the
// Convert to Symbol.xml file
var convertToSymbolDlg = fl.getDocumentDOM().xmlPanel( fl.configURI +
"Commands/Convert to Symbol.xml" );
if (convertToSymbolDlg.dismiss == "accept") {
var type = new String(convertToSymbolDlg.type);
fl.getDocumentDOM().convertToSymbol(type.toLowerCase(),
convertToSymbolDlg.name, convertToSymbolDlg.registration);
}
Second, create a file named Convert to Symbol.xml and place it in your Commands folder. Place
the following code into the file and save the file:
<dialog id="convertToSymbolDlg" title="Convert to Symbol" buttons="accept,
cancel">
<grid>
<columns>
<column/>
<column/>
</columns>
<rows>
<row align="right">
<label value="Name: " control="name" align="right"/>
<textbox id="name" value="Symbol 1"/>
</row>
<row><spacer/></row>
<row align="right">
<label value="Behavior:" control="type" align="right"/>
<radiogroup id="type">
<radio label="Movie clip"/>
,
<row>
<vbox>
and
<menupop>
<menuitem>
Convert to Symbol
tags.
command
<menulist>
459

Advertisement

Table of Contents
loading
Need help?

Need help?

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

Questions and answers

This manual is also suitable for:

Flash mx 2004 - actionscript

Table of Contents