![MACROMEDIA FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE Reference Download Page 448](http://html.mh-extra.com/html/macromedia/flash-8-actionscript-2-0-language/flash-8-actionscript-2-0-language_reference_687537448.webp)
448
ActionScript classes
hideBuiltInItems (ContextMenu.hideBuiltInItems
method)
public hideBuiltInItems() : Void
Hides all built-in menu items (except Settings) in the specified ContextMenu object. If the
Flash Debug Player is running, the Debugging menu item shows, although it is dimmed for
SWF files that don't have remote debugging enabled.
This method hides only menu items that appear in the standard context menu; it does not
affect items that appear in the edit or error menus.
This method works by setting all the Boolean members of
my_cm
.builtInItems
to
false
.
You can selectively make a built-in item visible by setting its corresponding member in
my_cm
.builtInItems
to
true
(as demonstrated in the following example).
Availability:
ActionScript 1.0; Flash Player 7
Example
The following example creates a new ContextMenu object named
my_cm
whose built-in menu
items are hidden, except for Print. The menu object is attached to the current Timeline.
var my_cm:ContextMenu = new ContextMenu();
my_cm.hideBuiltInItems();
my_cm.builtInItems.print = true;
this.menu = my_cm;
onSelect (ContextMenu.onSelect handler)
onSelect = function(item:Object, item_menu:Object) {}
Called when a user invokes the Flash Player context menu, but before the menu is actually
displayed. This event handler allows customization of the contents of the context menu based
on the current application state.
It is also possible to specify the callback handler for a ContextMenu object when constructing
a new ContextMenu object. For more information, see the ContextMenuItem
onSelect
entry.
Availability:
ActionScript 1.0; Flash Player 7
Summary of Contents for FLASH 8-ACTIONSCRIPT 2.0 LANGUAGE
Page 1: ...ActionScript 2 0 Language Reference ...
Page 1352: ...1352 ActionScript classes ...