/frameworks/projects/playerglobal/bundles/en_US/docs/flash.display.xml
https://github.com/adufilie/flex-sdk · XML · 6540 lines · 5341 code · 1181 blank · 18 comment · 0 complexity · 6a674eb57b74f902e3c15f3c167b0dd9 MD5 · raw file
- <?xml version="1.0" encoding="UTF-8"?><apiPackage xmlns:ditaarch="http://dita.oasis-open.org/architecture/2005/" id="flash.display" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiPackage/apiPackage "><apiName class="- topic/title reference/title apiRef/apiName ">flash.display</apiName><apiDetail class="- topic/body reference/refbody apiRef/apiDetail "/><apiClassifier languages="" id="flash.display:FrameLabel" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">FrameLabel</apiName><shortdesc class="- topic/shortdesc ">
- <!--
- Licensed to the Apache Software Foundation (ASF) under one or more
- contributor license agreements. See the NOTICE file distributed with
- this work for additional information regarding copyright ownership.
- The ASF licenses this file to You under the Apache License, Version 2.0
- (the "License"); you may not use this file except in compliance with
- the License. You may obtain a copy of the License at
- http://www.apache.org/licenses/LICENSE-2.0
- Unless required by applicable law or agreed to in writing, software
- distributed under the License is distributed on an "AS IS" BASIS,
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- See the License for the specific language governing permissions and
- limitations under the License.
- -->
-
- The FrameLabel object contains properties that specify a frame number and the
- corresponding label name.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiFinal class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiFinal "/><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">Object</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
-
- The FrameLabel object contains properties that specify a frame number and the
- corresponding label name.
- The Scene class includes a <codeph class="+ topic/ph pr-d/codeph ">labels</codeph> property, which is an array
- of FrameLabel objects for the scene.
-
- </apiDesc></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Scene/labels" class="- topic/link "><linktext class="- topic/linktext ">Scene.labels</linktext></link><link href="flash.display.xml#MovieClip/currentLabel" class="- topic/link "><linktext class="- topic/linktext ">MovieClip.currentLabel</linktext></link><link href="flash.display.xml#MovieClip/currentScene" class="- topic/link "><linktext class="- topic/linktext ">MovieClip.currentScene</linktext></link><link href="flash.display.xml#MovieClip/scenes" class="- topic/link "><linktext class="- topic/linktext ">MovieClip.scenes</linktext></link><link href="flash.display.xml#MovieClip/gotoAndPlay()" class="- topic/link "><linktext class="- topic/linktext ">MovieClip.gotoAndPlay()</linktext></link><link href="flash.display.xml#MovieClip/gotoAndStop()" class="- topic/link "><linktext class="- topic/linktext ">MovieClip.gotoAndStop()</linktext></link></related-links><apiValue id="flash.display:FrameLabel:frame:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">frame</apiName><shortdesc class="- topic/shortdesc ">
- The frame number containing the label.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">int</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The frame number containing the label.
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:FrameLabel:name:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">name</apiName><shortdesc class="- topic/shortdesc ">
- The name of the label.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The name of the label.
- </apiDesc></apiValueDetail></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:InteractiveObject" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">InteractiveObject</apiName><shortdesc class="- topic/shortdesc ">
- The InteractiveObject class is the abstract base class for all display objects with which the user can
- interact, using the mouse, keyboard, or other user input device.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">flash.display:DisplayObject</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The InteractiveObject class is the abstract base class for all display objects with which the user can
- interact, using the mouse, keyboard, or other user input device.
-
- <p class="- topic/p ">You cannot instantiate the InteractiveObject class directly. A call to the <codeph class="+ topic/ph pr-d/codeph ">new
- InteractiveObject()</codeph> constructor throws an <codeph class="+ topic/ph pr-d/codeph ">ArgumentError</codeph> exception.</p>
-
- <p class="- topic/p ">The InteractiveObject class itself does not include any APIs for rendering content onscreen.
- To create a custom subclass of the InteractiveObject class,
- extend one of the subclasses that do have APIs for rendering content onscreen,
- such as the Sprite, SimpleButton, TextField, or MovieClip classes.</p>
-
- </apiDesc><example conref="examples\InteractiveObjectExample.as" class="- topic/example "> The following example uses the <codeph class="+ topic/ph pr-d/codeph ">InteractiveObjectExample</codeph> class, which in
- turn uses the <codeph class="+ topic/ph pr-d/codeph ">ChildSprite</codeph> class to draw a rectangle and then manipulate that rectangle
- based on various mouse events. This task is accomplished by performing the following steps:
- <ol class="- topic/ol "><li class="- topic/li ">In the <codeph class="+ topic/ph pr-d/codeph ">InteractiveObjectExample</codeph> constructor, a new ChildSprite object of type Sprite
- called <codeph class="+ topic/ph pr-d/codeph ">child</codeph> is created, which calls the ChildSprite constructor method to draw the shape
- and add mouse events for the shape (as explained in the following steps). The <codeph class="+ topic/ph pr-d/codeph ">child</codeph>
- object is added to the top of the display list at coordinates <i class="+ topic/ph hi-d/i ">x = 0, y = 0</i>. </li><li class="- topic/li ">In the <codeph class="+ topic/ph pr-d/codeph ">ChildSprite</codeph> class, declare the <codeph class="+ topic/ph pr-d/codeph ">size</codeph> and
- <codeph class="+ topic/ph pr-d/codeph ">overSize</codeph> properties that are used later in the <codeph class="+ topic/ph pr-d/codeph ">draw()</codeph> method and
- MouseEvent methods.</li><li class="- topic/li ">Declare properties that set the background color to orange, the mouse-over color to
- dark yellow, and the mouse-down color to light blue.</li><li class="- topic/li ">In the <codeph class="+ topic/ph pr-d/codeph ">ChildSprite</codeph> constructor, an orange square is drawn by using methods from
- the Graphics class and the <codeph class="+ topic/ph pr-d/codeph ">draw()</codeph> method.</li><li class="- topic/li ">The constructor adds four MouseEvent event listener methods:
-
- <ul class="- topic/ul "><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">mouseOverHandler</codeph>: redraws a larger 60 x 60 pixel square with a dark-yellow color
- at the original coordinates.</li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">mouseOutHandler</codeph>: returns the square to its original size and color.</li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">mouseDownHandler</codeph>: redraws a larger 60 x 60 pixel square with a light-blue color
- at the original coordinates.</li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">mouseUpHandler</codeph>: same as <codeph class="+ topic/ph pr-d/codeph ">mouseOverHandler</codeph>.</li></ul>
- </li></ol>
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- package {
- import flash.display.Sprite;
- public class InteractiveObjectExample extends Sprite {
- public function InteractiveObjectExample() {
- var child:Sprite = new ChildSprite();
- addChild(child);
- }
- }
- }
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- class ChildSprite extends Sprite {
- private var size:uint = 50;
- private var overSize:uint = 60;
- private var backgroundColor:uint = 0xFFCC00;
- private var overColor:uint = 0xCCFF00;
- private var downColor:uint = 0x00CCFF;
- public function ChildSprite() {
- buttonMode = true;
- draw(size, size, backgroundColor);
- addEventListener(MouseEvent.MOUSE_OVER, mouseOverHandler);
- addEventListener(MouseEvent.MOUSE_OUT, mouseOutHandler);
- addEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler);
- addEventListener(MouseEvent.MOUSE_UP, mouseUpHandler);
- }
- private function draw(w:uint, h:uint, bgColor:uint):void {
- graphics.clear();
- graphics.beginFill(bgColor);
- graphics.drawRect(0, 0, w, h);
- graphics.endFill();
- }
- public function mouseOverHandler(event:MouseEvent):void {
- trace("mouseOverHandler");
- draw(overSize, overSize, overColor);
- }
- public function mouseOutHandler(event:MouseEvent):void {
- trace("mouseOutHandler");
- draw(size, size, backgroundColor);
- }
- public function mouseDownHandler(event:MouseEvent):void {
- trace("mouseDownHandler");
- draw(overSize, overSize, downColor);
- }
- public function mouseUpHandler(event:MouseEvent):void {
- trace("mouseUpHandler");
- draw(overSize, overSize, overColor);
- }
- }
- </codeblock></example></apiClassifierDetail><adobeApiEvent id="flash.display:InteractiveObject_flash.events.SoftKeyboardEvent.SOFT_KEYBOARD_DEACTIVATE_softKeyboardDeactivate" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">softKeyboardDeactivate</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched immediately after the soft keyboard is lowered.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2.6" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.SoftKeyboardEvent.SOFT_KEYBOARD_DEACTIVATE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.SoftKeyboardEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Dispatched immediately after the soft keyboard is lowered.
- </apiTipText></apiTipTexts></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched immediately after the soft keyboard is lowered.
- </apiDesc></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.events.xml#SoftKeyboardEvent" class="- topic/link "><linktext class="- topic/linktext ">flash.events.SoftKeyboardEvent</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.SoftKeyboardEvent.SOFT_KEYBOARD_ACTIVATE_softKeyboardActivate" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">softKeyboardActivate</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched immediately after the soft keyboard is raised.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2.6" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.SoftKeyboardEvent.SOFT_KEYBOARD_ACTIVATE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.SoftKeyboardEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Dispatched immediately after the soft keyboard is raised.
- </apiTipText></apiTipTexts></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched immediately after the soft keyboard is raised.
- </apiDesc></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.events.xml#SoftKeyboardEvent" class="- topic/link "><linktext class="- topic/linktext ">flash.events.SoftKeyboardEvent</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.SoftKeyboardEvent.SOFT_KEYBOARD_ACTIVATING_softKeyboardActivating" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">softKeyboardActivating</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched immediately before the soft keyboard is raised.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2.6" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.SoftKeyboardEvent.SOFT_KEYBOARD_ACTIVATING</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.SoftKeyboardEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Dispatched immediately before the soft keyboard is raised.
- </apiTipText></apiTipTexts></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched immediately before the soft keyboard is raised.
- </apiDesc></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.events.xml#SoftKeyboardEvent" class="- topic/link "><linktext class="- topic/linktext ">flash.events.SoftKeyboardEvent</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.TextEvent.TEXT_INPUT_textInput" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">textInput</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a user enters one or more
- characters of text.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.TextEvent.TEXT_INPUT</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.TextEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a user enters one or more
- characters of text. Various
- text input methods can generate this event, including standard keyboards,
- input method editors (IMEs), voice or speech recognition systems, and even the act
- of pasting plain text with no formatting or style information.
- </apiDesc><example conref="examples\TextField_textInput.as" class="- topic/example "/></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.IMEEvent_imeStartComposition" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">imeStartComposition</apiName><shortdesc class="- topic/shortdesc ">
- This event is dispatched to any client app that supports inline input with an IME
-
- </shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.IMEEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- This event is dispatched to any client app that supports inline input with an IME
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.CONTEXT_MENU_contextMenu" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">contextMenu</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a user gesture triggers the context menu associated with this interactive
- object in an AIR application.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.CONTEXT_MENU</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a user gesture triggers the context menu associated with this interactive
- object in an AIR application.
-
- </apiDesc></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/contextMenu" class="- topic/link "><linktext class="- topic/linktext ">contextMenu</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.NativeDragEvent.NATIVE_DRAG_COMPLETE_nativeDragComplete" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">nativeDragComplete</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched by the drag initiator InteractiveObject when the user releases the drag gesture.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.NativeDragEvent.NATIVE_DRAG_COMPLETE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.NativeDragEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched by the drag initiator InteractiveObject when the user releases the drag gesture.
-
- <p class="- topic/p ">The event's dropAction property indicates the action set
- by the drag target object; a value of "none" (<codeph class="+ topic/ph pr-d/codeph ">DragActions.NONE</codeph>)
- indicates that the drop was canceled or was not accepted.</p>
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">nativeDragComplete</codeph> event handler is a convenient place
- to update the state of the initiating display object, for example, by removing
- an item from a list (on a drag action of "move"), or by changing the visual
- properties.</p>
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.NativeDragEvent.NATIVE_DRAG_UPDATE_nativeDragUpdate" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">nativeDragUpdate</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched during a drag operation by the InteractiveObject that is
- specified as the drag initiator in the DragManager.doDrag() call.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.NativeDragEvent.NATIVE_DRAG_UPDATE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.NativeDragEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched during a drag operation by the InteractiveObject that is
- specified as the drag initiator in the DragManager.doDrag() call.
-
- <p class="- topic/p "><codeph class="+ topic/ph pr-d/codeph ">nativeDragUpdate</codeph> events are not dispatched on Linux.</p>
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.NativeDragEvent.NATIVE_DRAG_START_nativeDragStart" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">nativeDragStart</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched at the beginning of a drag operation by the InteractiveObject that is
- specified as the drag initiator in the DragManager.doDrag() call.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.NativeDragEvent.NATIVE_DRAG_START</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.NativeDragEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched at the beginning of a drag operation by the InteractiveObject that is
- specified as the drag initiator in the DragManager.doDrag() call.
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.NativeDragEvent.NATIVE_DRAG_EXIT_nativeDragExit" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">nativeDragExit</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched by an InteractiveObject when a drag gesture leaves its boundary.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.NativeDragEvent.NATIVE_DRAG_EXIT</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.NativeDragEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched by an InteractiveObject when a drag gesture leaves its boundary.
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.NativeDragEvent.NATIVE_DRAG_DROP_nativeDragDrop" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">nativeDragDrop</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched by the target InteractiveObject when a dragged object is
- dropped on it and the drop has been accepted with a call to
- DragManager.acceptDragDrop().</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.NativeDragEvent.NATIVE_DRAG_DROP</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.NativeDragEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched by the target InteractiveObject when a dragged object is
- dropped on it and the drop has been accepted with a call to
- DragManager.acceptDragDrop().
-
- <p class="- topic/p ">Access the dropped data using the event object <codeph class="+ topic/ph pr-d/codeph ">clipboard</codeph>
- property.</p>
-
- <p class="- topic/p ">The handler for this event should set the <codeph class="+ topic/ph pr-d/codeph ">DragManager.dropAction</codeph>
- property to provide feedback to the initiator object about which drag action
- was taken. If no value is set, the DragManager will select a default value
- from the list of allowed actions.</p>
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.NativeDragEvent.NATIVE_DRAG_OVER_nativeDragOver" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">nativeDragOver</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched by an InteractiveObject continually while a drag gesture remains within its
- boundary.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.NativeDragEvent.NATIVE_DRAG_OVER</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.NativeDragEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched by an InteractiveObject continually while a drag gesture remains within its
- boundary.
-
- <p class="- topic/p "><codeph class="+ topic/ph pr-d/codeph ">nativeDragOver</codeph> events are dispatched whenever the mouse is moved. On Windows and
- Mac, they are also dispatched on a short timer interval even when the mouse has not moved.</p>
-
- <p class="- topic/p ">Handle either the <codeph class="+ topic/ph pr-d/codeph ">nativeDragOver</codeph> or <codeph class="+ topic/ph pr-d/codeph ">nativeDragEnter</codeph>
- events to allow the display object to become the drop target.</p>
-
- <p class="- topic/p ">To determine whether the dispatching display object can accept the drop,
- check the suitability of the data in <codeph class="+ topic/ph pr-d/codeph ">clipboard</codeph> property of
- the event object, and the allowed drag actions in the <codeph class="+ topic/ph pr-d/codeph ">allowedActions</codeph>
- property.</p>
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.NativeDragEvent.NATIVE_DRAG_ENTER_nativeDragEnter" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">nativeDragEnter</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched by an InteractiveObject when a drag gesture enters its boundary.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.NativeDragEvent.NATIVE_DRAG_ENTER</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.NativeDragEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched by an InteractiveObject when a drag gesture enters its boundary.
-
- <p class="- topic/p ">Handle either the <codeph class="+ topic/ph pr-d/codeph ">nativeDragEnter</codeph> or <codeph class="+ topic/ph pr-d/codeph ">nativeDragOver</codeph>
- events to allow the display object to become the drop target.</p>
-
- <p class="- topic/p ">To determine whether the dispatching display object can accept the drop,
- check the suitability of the data in <codeph class="+ topic/ph pr-d/codeph ">clipboard</codeph> property of
- the event object, and the allowed drag actions in the <codeph class="+ topic/ph pr-d/codeph ">allowedActions</codeph>
- property.</p>
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.Event.TAB_INDEX_CHANGE_tabIndexChange" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">tabIndexChange</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the value of the object's tabIndex property changes.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.TAB_INDEX_CHANGE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the value of the object's <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph> property changes.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.Event.TAB_ENABLED_CHANGE_tabEnabledChange" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">tabEnabledChange</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the object's tabEnabled flag changes.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.TAB_ENABLED_CHANGE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the object's <codeph class="+ topic/ph pr-d/codeph ">tabEnabled</codeph> flag changes.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.Event.TAB_CHILDREN_CHANGE_tabChildrenChange" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">tabChildrenChange</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the value of the object's tabChildren flag changes.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.TAB_CHILDREN_CHANGE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the value of the object's <codeph class="+ topic/ph pr-d/codeph ">tabChildren</codeph> flag changes.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.KeyboardEvent.KEY_UP_keyUp" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">keyUp</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user releases a key.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.KeyboardEvent.KEY_UP</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.KeyboardEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user releases a key. Mappings between keys and specific characters vary
- by device and operating system. This event type is generated after such a mapping occurs
- but before the processing of an input method editor (IME). IMEs are used to enter
- characters, such as Chinese ideographs, that the standard QWERTY keyboard is
- ill-equipped to produce. This event occurs after a <codeph class="+ topic/ph pr-d/codeph ">keyDown</codeph> event and has
- the following characteristics:
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.KeyboardEvent.KEY_DOWN_keyDown" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">keyDown</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user presses a key.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.KeyboardEvent.KEY_DOWN</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.KeyboardEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user presses a key. Mappings between keys and specific characters
- vary by device and operating system. This event type is generated after such a mapping
- occurs but before the processing of an input method
- editor (IME). IMEs are used to enter characters, such as Chinese ideographs, that the standard QWERTY keyboard is ill-equipped
- to produce. This event occurs before the <codeph class="+ topic/ph pr-d/codeph ">keyUp</codeph> event.
-
- <p class="- topic/p ">In AIR, canceling this event prevents the character from being entered into a text field.</p>
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.RIGHT_MOUSE_UP_rightMouseUp" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">rightMouseUp</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a user releases the pointing device button over an
- InteractiveObject instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.RIGHT_MOUSE_UP</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a user releases the pointing device button over an
- InteractiveObject instance.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.RIGHT_MOUSE_DOWN_rightMouseDown" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">rightMouseDown</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a user presses the pointing device button over an InteractiveObject instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.RIGHT_MOUSE_DOWN</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a user presses the pointing device button over an InteractiveObject instance.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.RIGHT_CLICK_rightClick" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">rightClick</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a user presses and releases the right button of the user's
- pointing device over the same InteractiveObject.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.RIGHT_CLICK</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a user presses and releases the right button of the user's
- pointing device over the same InteractiveObject. For a <codeph class="+ topic/ph pr-d/codeph ">rightClick</codeph> event to occur, it must always follow this series of
- events in the order of occurrence: <codeph class="+ topic/ph pr-d/codeph ">rightMouseDown</codeph> event, then <codeph class="+ topic/ph pr-d/codeph ">rightMouseUp</codeph>. The target object
- must be identical for both of these events; otherwise the <codeph class="+ topic/ph pr-d/codeph ">rightClick</codeph> event does not
- occur. Any number of other mouse events can occur at any time between the
- <codeph class="+ topic/ph pr-d/codeph ">rightMouseDown</codeph> or <codeph class="+ topic/ph pr-d/codeph ">rightMouseUp</codeph> events; the <codeph class="+ topic/ph pr-d/codeph ">rightClick</codeph> event
- still occurs.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.MIDDLE_MOUSE_UP_middleMouseUp" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">middleMouseUp</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a user releases the pointing device button over an
- InteractiveObject instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.MIDDLE_MOUSE_UP</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a user releases the pointing device button over an
- InteractiveObject instance.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.MIDDLE_MOUSE_DOWN_middleMouseDown" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">middleMouseDown</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a user presses the middle pointing device button over an InteractiveObject instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.MIDDLE_MOUSE_DOWN</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a user presses the middle pointing device button over an InteractiveObject instance.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.MIDDLE_CLICK_middleClick" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">middleClick</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a user presses and releases the middle button of the user's
- pointing device over the same InteractiveObject.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.MIDDLE_CLICK</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a user presses and releases the middle button of the user's
- pointing device over the same InteractiveObject. For a <codeph class="+ topic/ph pr-d/codeph ">middleClick</codeph> event to occur, it must always follow this series of
- events in the order of occurrence: <codeph class="+ topic/ph pr-d/codeph ">middleMouseDown</codeph> event, then <codeph class="+ topic/ph pr-d/codeph ">middleMouseUp</codeph>. The target object
- must be identical for both of these events; otherwise the <codeph class="+ topic/ph pr-d/codeph ">middleClick</codeph> event does not
- occur. Any number of other mouse events can occur at any time between the
- <codeph class="+ topic/ph pr-d/codeph ">middleMouseDown</codeph> or <codeph class="+ topic/ph pr-d/codeph ">middleMouseUp</codeph> events; the <codeph class="+ topic/ph pr-d/codeph ">middleClick</codeph> event
- still occurs.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.TransformGestureEvent.GESTURE_SWIPE_gestureSwipe" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">gestureSwipe</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user performs a swipe gesture at a point of contact with an InteractiveObject instance (such as touching three
- fingers to a screen and then moving them in parallel over a display object on a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.TransformGestureEvent.GESTURE_SWIPE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.TransformGestureEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user performs a swipe gesture at a point of contact with an InteractiveObject instance (such as touching three
- fingers to a screen and then moving them in parallel over a display object on a mobile phone or tablet with a touch screen).
- Moving several fingers in parallel is a common swipe gesture,
- but each device and operating system can have its own requirements for a swipe.
- Some devices might also interpret this contact as a combination of several mouse events, as well.
- <p class="- topic/p ">Specifically, if a user moves a finger over an InteractiveObject, and then moves the fingers together, the InteractiveObject instance can
- dispatch a <codeph class="+ topic/ph pr-d/codeph ">rollOver</codeph>
- event and a <codeph class="+ topic/ph pr-d/codeph ">rollOut</codeph> event (among others), in addition to the <codeph class="+ topic/ph pr-d/codeph ">gestureSwipe</codeph> event, or all if the current environment supports it.
- Choose how you want to handle the user interaction.
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">rollOver</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">gestureSwipe</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p ">When handling the properties of the event object, note that the <codeph class="+ topic/ph pr-d/codeph ">localX</codeph> and <codeph class="+ topic/ph pr-d/codeph ">localY</codeph> properties are set to the
- primary point of contact. The <codeph class="+ topic/ph pr-d/codeph ">offsetX</codeph> and <codeph class="+ topic/ph pr-d/codeph ">offsetY</codeph> properties are the distance to the point of contact where the swipe gesture
- is complete.</p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> While some devices using the Mac OS operating system can
- interpret a four-finger swipe, this API only supports a three-finger swipe.</p>
- </apiDesc><example conref="..\events\examples\TransformGesture_swipe.as" class="- topic/example "> The following example shows event handling for the <codeph class="+ topic/ph pr-d/codeph ">GESTURE_SWIPE</codeph> events.
- While the user performs a swipe gesture on the touch-enabled device, myTextField populates with the phase <codeph class="+ topic/ph pr-d/codeph ">all</codeph>,
- which is the only phase for swipe events.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- Multitouch.inputMode = MultitouchInputMode.GESTURE;
- var mySprite = new Sprite();
- mySprite.addEventListener(TransformGestureEvent.GESTURE_SWIPE , onSwipe);
- mySprite.graphics.beginFill(0x336699);
- mySprite.graphics.drawRect(0, 0, 100, 80);
- var myTextField = new TextField();
- myTextField.y = 200;
- addChild(mySprite);
- addChild(myTextField);
- function onSwipe(evt:TransformGestureEvent):void {
- if (evt.offsetX == 1 ) {
- myTextField.text = "right";
- }
- if (evt.offsetY == -1) {
- myTextField.text = "up";
- }
- myTextField.text = evt.phase;
- }
- </codeblock></example></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:rollOver" class="- topic/link "><linktext class="- topic/linktext ">rollOver event</linktext></link><link href="flash.display.xml#InteractiveObject/event:touchOver" class="- topic/link "><linktext class="- topic/linktext ">touchOver event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.TransformGestureEvent.GESTURE_ZOOM_gestureZoom" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">gestureZoom</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user performs a zoom gesture at a point of contact with an InteractiveObject instance (such as touching two
- fingers to a screen and then quickly spreading the fingers apart over a display object on a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.TransformGestureEvent.GESTURE_ZOOM</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.TransformGestureEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user performs a zoom gesture at a point of contact with an InteractiveObject instance (such as touching two
- fingers to a screen and then quickly spreading the fingers apart over a display object on a mobile phone or tablet with a touch screen).
- Moving fingers apart is a common zoom gesture,
- but each device and operating system can have its own requirements to indicate zoom.
- Some devices might also interpret this contact as a combination of several mouse events, as well.
- <p class="- topic/p ">Specifically, if a user moves a finger over an InteractiveObject, and then moves the fingers apart, the InteractiveObject instance can
- dispatch a <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph>
- event and a <codeph class="+ topic/ph pr-d/codeph ">click</codeph> event (among others), in addition to the <codeph class="+ topic/ph pr-d/codeph ">gestureZoom</codeph> event, or all if the current environment supports it.
- Choose how you want to handle the user interaction. Use the flash.ui.Multitouch class to manage touch event handling (enable touch gesture event handling,
- simple touch point event handling, or disable touch events so only mouse events are dispatched).
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">gestureZoom</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p ">When handling the properties of the event object, note that the <codeph class="+ topic/ph pr-d/codeph ">localX</codeph> and <codeph class="+ topic/ph pr-d/codeph ">localY</codeph> properties are set to the
- primary point of contact. The <codeph class="+ topic/ph pr-d/codeph ">offsetX</codeph> and <codeph class="+ topic/ph pr-d/codeph ">offsetY</codeph> properties are the distance to the point of contact where the zoom gesture
- is complete.</p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> See the Multitouch class for environment compatibility information.</p>
- </apiDesc><example conref="..\events\examples\TransformGesture_zoom.as" class="- topic/example "> The following example shows event handling for the <codeph class="+ topic/ph pr-d/codeph ">GESTURE_ZOOM</codeph> events.
- While the user performs a zoom gesture on the touch-enabled device, myTextField populates with the current phase.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- Multitouch.inputMode = MultitouchInputMode.GESTURE;
- var mySprite = new Sprite();
- mySprite.addEventListener(TransformGestureEvent.GESTURE_ZOOM , onZoom);
- mySprite.graphics.beginFill(0x336699);
- mySprite.graphics.drawRect(0, 0, 100, 80);
- var myTextField = new TextField();
- myTextField.y = 200;
- addChild(mySprite);
- addChild(myTextField);
- function onZoom(evt:TransformGestureEvent):void {
- evt.target.scaleX++;
- if (evt.phase==GesturePhase.BEGIN) {
- myTextField.text = "Begin";
- }
- if (evt.phase==GesturePhase.UPDATE) {
- myTextField.text = "Update";
- }
- if (evt.phase==GesturePhase.END) {
- myTextField.text = "End";
- }
- }
- </codeblock></example></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:mouseOver" class="- topic/link "><linktext class="- topic/linktext ">mouseOver event</linktext></link><link href="flash.display.xml#InteractiveObject/event:touchOver" class="- topic/link "><linktext class="- topic/linktext ">touchOver event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.TransformGestureEvent.GESTURE_ROTATE_gestureRotate" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">gestureRotate</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user performs a rotation gesture at a point of contact with an InteractiveObject instance (such as touching two fingers
- and rotating them over a display object on a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.TransformGestureEvent.GESTURE_ROTATE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.TransformGestureEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user performs a rotation gesture at a point of contact with an InteractiveObject instance (such as touching two fingers
- and rotating them over a display object on a mobile phone or tablet with a touch screen). Two-finger rotation is a common rotation gesture,
- but each device and operating system can have its own requirements to indicate rotation.
- Some devices might also interpret this contact as a combination of several mouse events, as well.
- <p class="- topic/p ">Specifically, if a user moves a finger over an InteractiveObject, the InteractiveObject instance can
- dispatch a <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph>
- event and a <codeph class="+ topic/ph pr-d/codeph ">click</codeph> event (among others), in addition to the <codeph class="+ topic/ph pr-d/codeph ">gestureRotate</codeph> event, or all if the current environment supports it.
- Choose how you want to handle the user interaction. Use the flash.ui.Multitouch class to manage touch event handling (enable touch gesture event handling,
- simple touch point event handling, or disable touch events so only mouse events are dispatched).
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">gestureRotate</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p ">When handling the properties of the event object, note that the <codeph class="+ topic/ph pr-d/codeph ">localX</codeph> and <codeph class="+ topic/ph pr-d/codeph ">localY</codeph> properties are set to the
- primary point of contact. The <codeph class="+ topic/ph pr-d/codeph ">offsetX</codeph> and <codeph class="+ topic/ph pr-d/codeph ">offsetY</codeph> properties are the distance to the point of contact where the rotation gesture
- is complete.</p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> See the Multitouch class for environment compatibility information.</p>
- </apiDesc><example conref="..\events\examples\TransformGestureEventExample.as" class="- topic/example "> The following example shows event handling for the <codeph class="+ topic/ph pr-d/codeph ">GESTURE_ROTATE</codeph> events.
- While the user performs a rotation gesture on the touch-enabled device, mySprite rotates and myTextField populates with the current phase.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- Multitouch.inputMode = MultitouchInputMode.GESTURE;
- var mySprite = new Sprite();
- mySprite.addEventListener(TransformGestureEvent.GESTURE_ROTATE , onRotate );
- mySprite.graphics.beginFill(0x336699);
- mySprite.graphics.drawRect(0, 0, 100, 80);
- var myTextField = new TextField();
- myTextField.y = 200;
- addChild(mySprite);
- addChild(myTextField);
- function onRotate(evt:TransformGestureEvent):void {
- evt.target.rotation -= 45;
- if (evt.phase==GesturePhase.BEGIN) {
- myTextField.text = "Begin";
- }
- if (evt.phase==GesturePhase.UPDATE) {
- myTextField.text = "Update";
- }
- if (evt.phase==GesturePhase.END) {
- myTextField.text = "End";
- }
- }
- </codeblock></example></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:mouseOver" class="- topic/link "><linktext class="- topic/linktext ">mouseOver event</linktext></link><link href="flash.display.xml#InteractiveObject/event:touchOver" class="- topic/link "><linktext class="- topic/linktext ">touchOver event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.PressAndTapGestureEvent.GESTURE_PRESS_AND_TAP_gesturePressAndTap" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">gesturePressAndTap</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user creates a point of contact with an InteractiveObject instance, then taps
- on a touch-enabled device (such as placing several fingers over a display object to open a menu and then taps one finger to select a menu item
- on a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.PressAndTapGestureEvent.GESTURE_PRESS_AND_TAP</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.PressAndTapGestureEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user creates a point of contact with an InteractiveObject instance, then taps
- on a touch-enabled device (such as placing several fingers over a display object to open a menu and then taps one finger to select a menu item
- on a mobile phone or tablet with a touch screen).
- Some devices might also interpret this contact as a combination of several mouse events, as well.
- <p class="- topic/p ">Specifically, if a user moves a finger over an InteractiveObject, and then provides a secondary tap, the InteractiveObject instance can
- dispatch a <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph>
- event and a <codeph class="+ topic/ph pr-d/codeph ">click</codeph> event (among others) as well as the <codeph class="+ topic/ph pr-d/codeph ">gesturePressAndTap</codeph> event, or all if the current environment supports it.
- Choose how you want to handle the user interaction. Use the flash.ui.Multitouch class to manage touch event handling (enable touch gesture event handling,
- simple touch point event handling, or disable touch events so only mouse events are dispatched).
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">gesturePressAndTap</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p ">When handling the properties of the event object, note that the <codeph class="+ topic/ph pr-d/codeph ">localX</codeph> and <codeph class="+ topic/ph pr-d/codeph ">localY</codeph> properties are set to the
- primary point of contact (the "push"). The <codeph class="+ topic/ph pr-d/codeph ">offsetX</codeph> and <codeph class="+ topic/ph pr-d/codeph ">offsetY</codeph> properties are the distance to the secondary point of
- contact (the "tap").</p>
- </apiDesc></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:mouseOver" class="- topic/link "><linktext class="- topic/linktext ">mouseOver event</linktext></link><link href="flash.display.xml#InteractiveObject/event:touchOver" class="- topic/link "><linktext class="- topic/linktext ">touchOver event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.TransformGestureEvent.GESTURE_PAN_gesturePan" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">gesturePan</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user moves a point of contact over the InteractiveObject instance
- on a touch-enabled device (such as moving a finger from left to right over a display object
- on a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.TransformGestureEvent.GESTURE_PAN</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.TransformGestureEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user moves a point of contact over the InteractiveObject instance
- on a touch-enabled device (such as moving a finger from left to right over a display object
- on a mobile phone or tablet with a touch screen).
- Some devices might also interpret this contact as a <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph> event and as a <codeph class="+ topic/ph pr-d/codeph ">touchOver</codeph> event.
- <p class="- topic/p ">Specifically, if a user moves a finger over an InteractiveObject, the InteractiveObject instance can dispatch a <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph>
- event or a <codeph class="+ topic/ph pr-d/codeph ">touchOver</codeph> event or a <codeph class="+ topic/ph pr-d/codeph ">gesturePan</codeph> event, or all if the current environment supports it.
- Choose how you want to handle the user interaction. Use the flash.ui.Multitouch class to manage touch event handling (enable touch gesture event handling,
- simple touch point event handling, or disable touch events so only mouse events are dispatched).
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">gesturePan</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> See the Multitouch class for environment compatibility information.</p>
- </apiDesc><example conref="..\events\examples\TransformGesture_pan.as" class="- topic/example "> The following example shows event handling for the <codeph class="+ topic/ph pr-d/codeph ">GESTURE_PAN</codeph> events.
- While the user performs a pan gesture on the touch-enabled device, myTextField populates with the current phase.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- Multitouch.inputMode = MultitouchInputMode.GESTURE;
- var mySprite = new Sprite();
- mySprite.addEventListener(TransformGestureEvent.GESTURE_PAN , onPan);
- mySprite.graphics.beginFill(0x336699);
- mySprite.graphics.drawRect(0, 0, 100, 80);
- var myTextField = new TextField();
- myTextField.y = 200;
- addChild(mySprite);
- addChild(myTextField);
- function onPan(evt:TransformGestureEvent):void {
- evt.target.localX++;
- if (evt.phase==GesturePhase.BEGIN) {
- myTextField.text = "Begin";
- }
- if (evt.phase==GesturePhase.UPDATE) {
- myTextField.text = "Update";
- }
- if (evt.phase==GesturePhase.END) {
- myTextField.text = "End";
- }
- }
- </codeblock></example></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:mouseOver" class="- topic/link "><linktext class="- topic/linktext ">mouseOver event</linktext></link><link href="flash.display.xml#InteractiveObject/event:touchOver" class="- topic/link "><linktext class="- topic/linktext ">touchOver event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.GestureEvent.GESTURE_TWO_FINGER_TAP_gestureTwoFingerTap" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">gestureTwoFingerTap</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user presses two points of contact over the same InteractiveObject instance
- on a touch-enabled device (such as presses and releases two fingers over a display object
- on a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.GestureEvent.GESTURE_TWO_FINGER_TAP</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.GestureEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user presses two points of contact over the same InteractiveObject instance
- on a touch-enabled device (such as presses and releases two fingers over a display object
- on a mobile phone or tablet with a touch screen).
- Some devices might also interpret this contact as a <codeph class="+ topic/ph pr-d/codeph ">doubleClick</codeph> event.
- <p class="- topic/p ">Specifically, if a user taps two fingers over an InteractiveObject, the InteractiveObject instance can dispatch a <codeph class="+ topic/ph pr-d/codeph ">doubleClick</codeph>
- event or a <codeph class="+ topic/ph pr-d/codeph ">gestureTwoFingerTap</codeph> event, or both if the current environment supports it. Choose how you want to handle the user interaction.
- Use the flash.ui.Multitouch class to manage touch event handling (enable touch gesture event handling,
- simple touch point event handling, or disable touch events so only mouse events are dispatched).
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">doubleClick</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">gestureTwoFingerTap</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> See the Multitouch class for environment compatibility information.</p>
- </apiDesc></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:doubleClick" class="- topic/link "><linktext class="- topic/linktext ">doubleClick event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.TouchEvent.TOUCH_TAP_touchTap" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">touchTap</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user lifts the point of contact over the same InteractiveObject instance on which the contact was initiated
- on a touch-enabled device (such as presses and releases a finger from a single point over a display object
- on a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.TouchEvent.TOUCH_TAP</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.TouchEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user lifts the point of contact over the same InteractiveObject instance on which the contact was initiated
- on a touch-enabled device (such as presses and releases a finger from a single point over a display object
- on a mobile phone or tablet with a touch screen).
- Some devices might also interpret this contact as a <codeph class="+ topic/ph pr-d/codeph ">click</codeph> event.
- <p class="- topic/p ">Specifically, if a user taps a finger over an InteractiveObject, the InteractiveObject instance can dispatch a <codeph class="+ topic/ph pr-d/codeph ">click</codeph>
- event or a <codeph class="+ topic/ph pr-d/codeph ">touchTap</codeph> event, or both if the current environment supports it. Choose how you want to handle the user interaction.
- Use the flash.ui.Multitouch class to manage touch event handling (enable touch gesture event handling,
- simple touch point event handling, or disable touch events so only mouse events are dispatched).
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">click</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">touchTap</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> See the Multitouch class for environment compatibility information.</p>
- </apiDesc><example conref="..\ui\examples\Multitouch_inputMode.as" class="- topic/example "> The following example displays a message when the
- square drawn on mySprite is tapped on a touch-enabled screen:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- Multitouch.inputMode=MultitouchInputMode.TOUCH_POINT;
- var mySprite:Sprite = new Sprite();
- var myTextField:TextField = new TextField();
- mySprite.graphics.beginFill(0x336699);
- mySprite.graphics.drawRect(0,0,40,40);
- addChild(mySprite);
- mySprite.addEventListener(TouchEvent.TOUCH_TAP, taphandler);
- function taphandler(e:TouchEvent): void {
- myTextField.text = "I've been tapped";
- myTextField.y = 50;
- addChild(myTextField);
- }
- </codeblock></example></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:click" class="- topic/link "><linktext class="- topic/linktext ">click event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.TouchEvent.TOUCH_ROLL_OVER_touchRollOver" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">touchRollOver</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user moves the point of contact over an InteractiveObject instance on a touch-enabled device
- (such as drags a finger from a point outside a display object to a point over a display object on a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.TouchEvent.TOUCH_ROLL_OVER</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.TouchEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user moves the point of contact over an InteractiveObject instance on a touch-enabled device
- (such as drags a finger from a point outside a display object to a point over a display object on a mobile phone or tablet with a touch screen).
- Some devices might also interpret this contact as a <codeph class="+ topic/ph pr-d/codeph ">rollOver</codeph> event.
- <p class="- topic/p ">Specifically, if a user moves a finger over an InteractiveObject, the InteractiveObject instance can dispatch a <codeph class="+ topic/ph pr-d/codeph ">rollOver</codeph>
- event or a <codeph class="+ topic/ph pr-d/codeph ">touchRollOver</codeph> event, or both if the current environment supports it. Choose how you want to handle the user interaction.
- Use the flash.ui.Multitouch class to manage touch event handling (enable touch gesture event handling,
- simple touch point event handling, or disable touch events so only mouse events are dispatched).
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">rollOver</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">touchRollOver</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> See the Multitouch class for environment compatibility information.</p>
- </apiDesc></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:rollOver" class="- topic/link "><linktext class="- topic/linktext ">rollOver event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.TouchEvent.TOUCH_ROLL_OUT_touchRollOut" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">touchRollOut</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user moves the point of contact away from an InteractiveObject instance on a touch-enabled device
- (such as drags a finger from over a display object to a point outside the display object on a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.TouchEvent.TOUCH_ROLL_OUT</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.TouchEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user moves the point of contact away from an InteractiveObject instance on a touch-enabled device
- (such as drags a finger from over a display object to a point outside the display object on a mobile phone or tablet with a touch screen).
- Some devices might also interpret this contact as a <codeph class="+ topic/ph pr-d/codeph ">rollOut</codeph> event.
- <p class="- topic/p ">Specifically, if a user moves a finger over an InteractiveObject, the InteractiveObject instance can dispatch a <codeph class="+ topic/ph pr-d/codeph ">rollOut</codeph>
- event or a <codeph class="+ topic/ph pr-d/codeph ">touchRollOut</codeph> event, or both if the current environment supports it. Choose how you want to handle the user interaction.
- Use the flash.ui.Multitouch class to manage touch event handling (enable touch gesture event handling,
- simple touch point event handling, or disable touch events so only mouse events are dispatched).
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">rollOut</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">touchRollOut</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> See the Multitouch class for environment compatibility information.</p>
- </apiDesc></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:rollOut" class="- topic/link "><linktext class="- topic/linktext ">rollOut event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.TouchEvent.TOUCH_OVER_touchOver" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">touchOver</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user moves the point of contact over an InteractiveObject instance on a touch-enabled device
- (such as drags a finger from a point outside a display object to a point over a display object on a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.TouchEvent.TOUCH_OVER</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.TouchEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user moves the point of contact over an InteractiveObject instance on a touch-enabled device
- (such as drags a finger from a point outside a display object to a point over a display object on a mobile phone or tablet with a touch screen).
- Some devices might also interpret this contact as a <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph> event.
- <p class="- topic/p ">Specifically, if a user moves a finger over an InteractiveObject, the InteractiveObject instance can dispatch a <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph>
- event or a <codeph class="+ topic/ph pr-d/codeph ">touchOver</codeph> event, or both if the current environment supports it. Choose how you want to handle the user interaction.
- Use the flash.ui.Multitouch class to manage touch event handling (enable touch gesture event handling,
- simple touch point event handling, or disable touch events so only mouse events are dispatched).
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">touchOver</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> See the Multitouch class for environment compatibility information.</p>
- </apiDesc></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:mouseOver" class="- topic/link "><linktext class="- topic/linktext ">mouseOver event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.TouchEvent.TOUCH_OUT_touchOut" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">touchOut</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user moves the point of contact away from InteractiveObject instance on a touch-enabled device
- (such as drags a finger from one display object to another on a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.TouchEvent.TOUCH_OUT</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.TouchEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user moves the point of contact away from InteractiveObject instance on a touch-enabled device
- (such as drags a finger from one display object to another on a mobile phone or tablet with a touch screen).
- Some devices might also interpret this contact as a <codeph class="+ topic/ph pr-d/codeph ">mouseOut</codeph> event.
- <p class="- topic/p ">Specifically, if a user moves a finger across a touch screen, the InteractiveObject instance can dispatch a <codeph class="+ topic/ph pr-d/codeph ">mouseOut</codeph>
- event or a <codeph class="+ topic/ph pr-d/codeph ">touchOut</codeph> event, or both if the current environment supports it. Choose how you want to handle the user interaction.
- Use the flash.ui.Multitouch class to manage touch event handling (enable touch gesture event handling,
- simple touch point event handling, or disable touch events so only mouse events are dispatched).
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">mouseOut</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">touchOut</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> See the Multitouch class for environment compatibility information.</p>
- </apiDesc></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:mouseOut" class="- topic/link "><linktext class="- topic/linktext ">mouseOut event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.TouchEvent.TOUCH_MOVE_touchMove" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">touchMove</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user moves the point of contact with a touch-enabled device (such as drags a finger across a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.TouchEvent.TOUCH_MOVE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.TouchEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user moves the point of contact with a touch-enabled device (such as drags a finger across a mobile phone or tablet with a touch screen).
- Some devices might also interpret this contact as a <codeph class="+ topic/ph pr-d/codeph ">mouseMove</codeph> event.
- <p class="- topic/p ">Specifically, if a user moves a finger across a touch screen, the InteractiveObject instance can dispatch a <codeph class="+ topic/ph pr-d/codeph ">mouseMove</codeph>
- event or a <codeph class="+ topic/ph pr-d/codeph ">touchMove</codeph> event, or both if the current environment supports it. Choose how you want to handle the user interaction.
- Use the flash.ui.Multitouch class to manage touch event handling (enable touch gesture event handling,
- simple touch point event handling, or disable touch events so only mouse events are dispatched).
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">mouseMove</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">touchMove</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> See the Multitouch class for environment compatibility information.</p>
- </apiDesc><example conref="..\events\examples\TouchEventExample.as" class="- topic/example "> The following example shows event handling for the <codeph class="+ topic/ph pr-d/codeph ">TOUCH_BEGIN</codeph>, <codeph class="+ topic/ph pr-d/codeph ">TOUCH_MOVE</codeph>, and <codeph class="+ topic/ph pr-d/codeph ">TOUCH_END</codeph> events.
- While the point of contact moves across the screen (<codeph class="+ topic/ph pr-d/codeph ">onTouchMove</codeph>), the x-coordinate relative to the stage is traced to output.
- For the <codeph class="+ topic/ph pr-d/codeph ">Sprite.startTouchDrag</codeph> parameters in the <codeph class="+ topic/ph pr-d/codeph ">onTouchBegin</codeph> function, the value for touchPointID is the value assigned to the event object.
- The bounds parameter is the rectangle defining the boundaries of
- the parent display object (bg is a display object containing MySprite).
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- Multitouch.inputMode = MultitouchInputMode.TOUCH_POINT;
- MySprite.addEventListener(TouchEvent.TOUCH_BEGIN, onTouchBegin);
- MySprite.addEventListener(TouchEvent.TOUCH_MOVE, onTouchMove);
- MySprite.addEventListener(TouchEvent.TOUCH_END, onTouchEnd);
- function onTouchBegin(eBegin:TouchEvent) {
- eBegin.target.startTouchDrag(eBegin.touchPointID, false, bg.getRect(this));
- trace("touch begin");
-
- }
- function onTouchMove(eMove:TouchEvent) {
- trace(eMove.stageX);
- }
-
- function onTouchEnd(eEnd:TouchEvent) {
- eEnd.target.stopTouchDrag(eEnd.touchPointID);
- trace("touch end");
- }
- </codeblock></example></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:mouseMove" class="- topic/link "><linktext class="- topic/linktext ">mouseMove event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.TouchEvent.TOUCH_END_touchEnd" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">touchEnd</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user removes contact with a touch-enabled device (such as lifts a finger off a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.TouchEvent.TOUCH_END</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.TouchEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user removes contact with a touch-enabled device (such as lifts a finger off a mobile phone or tablet with a touch screen).
- Some devices might also interpret this contact as a <codeph class="+ topic/ph pr-d/codeph ">mouseUp</codeph> event.
- <p class="- topic/p ">Specifically, if a user lifts a finger from a touch screen, the InteractiveObject instance can dispatch a <codeph class="+ topic/ph pr-d/codeph ">mouseUp</codeph>
- event or a <codeph class="+ topic/ph pr-d/codeph ">touchEnd</codeph> event, or both if the current environment supports it. Choose how you want to handle the user interaction.
- Use the flash.ui.Multitouch class to manage touch event handling (enable touch gesture event handling,
- simple touch point event handling, or disable touch events so only mouse events are dispatched).
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">mouseUp</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">touchEnd</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> See the Multitouch class for environment compatibility information.</p>
- </apiDesc><example conref="..\events\examples\TouchEventExample.as" class="- topic/example "> The following example shows event handling for the <codeph class="+ topic/ph pr-d/codeph ">TOUCH_BEGIN</codeph>, <codeph class="+ topic/ph pr-d/codeph ">TOUCH_MOVE</codeph>, and <codeph class="+ topic/ph pr-d/codeph ">TOUCH_END</codeph> events.
- While the point of contact moves across the screen (<codeph class="+ topic/ph pr-d/codeph ">onTouchMove</codeph>), the x-coordinate relative to the stage is traced to output.
- For the <codeph class="+ topic/ph pr-d/codeph ">Sprite.startTouchDrag</codeph> parameters in the <codeph class="+ topic/ph pr-d/codeph ">onTouchBegin</codeph> function, the value for touchPointID is the value assigned to the event object.
- The bounds parameter is the rectangle defining the boundaries of
- the parent display object (bg is a display object containing MySprite).
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- Multitouch.inputMode = MultitouchInputMode.TOUCH_POINT;
- MySprite.addEventListener(TouchEvent.TOUCH_BEGIN, onTouchBegin);
- MySprite.addEventListener(TouchEvent.TOUCH_MOVE, onTouchMove);
- MySprite.addEventListener(TouchEvent.TOUCH_END, onTouchEnd);
- function onTouchBegin(eBegin:TouchEvent) {
- eBegin.target.startTouchDrag(eBegin.touchPointID, false, bg.getRect(this));
- trace("touch begin");
-
- }
- function onTouchMove(eMove:TouchEvent) {
- trace(eMove.stageX);
- }
-
- function onTouchEnd(eEnd:TouchEvent) {
- eEnd.target.stopTouchDrag(eEnd.touchPointID);
- trace("touch end");
- }
- </codeblock></example></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:mouseUp" class="- topic/link "><linktext class="- topic/linktext ">mouseUp event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.TouchEvent.TOUCH_BEGIN_touchBegin" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">touchBegin</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user first contacts a touch-enabled device (such as touches a finger to a mobile phone or tablet with a touch screen).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.TouchEvent.TOUCH_BEGIN</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.TouchEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user first contacts a touch-enabled device (such as touches a finger to a mobile phone or tablet with a touch screen).
- Some devices might also interpret this contact as a <codeph class="+ topic/ph pr-d/codeph ">mouseDown</codeph> event.
- <p class="- topic/p ">Specifically, if a user touches a finger to a touch screen, the InteractiveObject instance can dispatch a <codeph class="+ topic/ph pr-d/codeph ">mouseDown</codeph>
- event or a <codeph class="+ topic/ph pr-d/codeph ">touchBegin</codeph> event, or both if the current environment supports it. Choose how you want to handle the user interaction.
- Use the flash.ui.Multitouch class to manage touch event handling (enable touch gesture event handling,
- simple touch point event handling, or disable touch events so only mouse events are dispatched).
- If you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">mouseDown</codeph> event, then the same event handler will run on a touch-enabled device and
- a mouse enabled device. However, if you choose to handle the <codeph class="+ topic/ph pr-d/codeph ">touchBegin</codeph> event, you can design your event handler
- to respond to the specific needs of a touch-enabled environment and provide users with a richer touch-enabled
- experience. You can also handle both events, separately, to provide a different response for a touch event than a mouse event.</p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> See the Multitouch class for environment compatibility information.</p>
- </apiDesc><example conref="..\events\examples\TouchEventExample.as" class="- topic/example "> The following example shows event handling for the <codeph class="+ topic/ph pr-d/codeph ">TOUCH_BEGIN</codeph>, <codeph class="+ topic/ph pr-d/codeph ">TOUCH_MOVE</codeph>, and <codeph class="+ topic/ph pr-d/codeph ">TOUCH_END</codeph> events.
- While the point of contact moves across the screen (<codeph class="+ topic/ph pr-d/codeph ">onTouchMove</codeph>), the x-coordinate relative to the stage is traced to output.
- For the <codeph class="+ topic/ph pr-d/codeph ">Sprite.startTouchDrag</codeph> parameters in the <codeph class="+ topic/ph pr-d/codeph ">onTouchBegin</codeph> function, the value for touchPointID is the value assigned to the event object.
- The bounds parameter is the rectangle defining the boundaries of
- the parent display object (bg is a display object containing MySprite).
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- Multitouch.inputMode = MultitouchInputMode.TOUCH_POINT;
- MySprite.addEventListener(TouchEvent.TOUCH_BEGIN, onTouchBegin);
- MySprite.addEventListener(TouchEvent.TOUCH_MOVE, onTouchMove);
- MySprite.addEventListener(TouchEvent.TOUCH_END, onTouchEnd);
- function onTouchBegin(eBegin:TouchEvent) {
- eBegin.target.startTouchDrag(eBegin.touchPointID, false, bg.getRect(this));
- trace("touch begin");
-
- }
- function onTouchMove(eMove:TouchEvent) {
- trace(eMove.stageX);
- }
-
- function onTouchEnd(eEnd:TouchEvent) {
- eEnd.target.stopTouchDrag(eEnd.touchPointID);
- trace("touch end");
- }
- </codeblock></example></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:mouseDown" class="- topic/link "><linktext class="- topic/linktext ">mouseDown event</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.ROLL_OVER_rollOver" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">rollOver</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user moves a pointing device over an InteractiveObject instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.ROLL_OVER</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user moves a pointing device over an InteractiveObject instance.
- The event target is the object under the pointing device or a parent of that object.
- The <codeph class="+ topic/ph pr-d/codeph ">relatedObject</codeph> is the object that was previously under the pointing
- device. The <codeph class="+ topic/ph pr-d/codeph ">rollOver</codeph> events are dispatched consecutively down the parent
- chain of the object, starting with the highest parent that is neither the root
- nor an ancestor of the <codeph class="+ topic/ph pr-d/codeph ">relatedObject</codeph> and ending with the object.
- <p class="- topic/p ">The purpose of the <codeph class="+ topic/ph pr-d/codeph ">rollOver</codeph> event is to simplify the coding of rollout behaviors for
- display object containers with children. When the mouse enters the area of a display
- object or the area of any of its children from an object that is not one of its
- children, the display object dispatches the <codeph class="+ topic/ph pr-d/codeph ">rollOver</codeph> event. This is different behavior
- than that of the <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph> event, which is dispatched each time the mouse
- enters the area of any child object of the display object container, even if the mouse
- was already over another child object of the display object container. </p>
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.ROLL_OUT_rollOut" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">rollOut</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user moves a pointing device away from an InteractiveObject
- instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.ROLL_OUT</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user moves a pointing device away from an InteractiveObject
- instance. The event target is the object previously under the pointing device or a parent of
- that object. The <codeph class="+ topic/ph pr-d/codeph ">relatedObject</codeph> is the object that the pointing device has moved to.
- The <codeph class="+ topic/ph pr-d/codeph ">rollOut</codeph> events are dispatched consecutively up the parent chain of the object,
- starting with the object and ending with the highest parent that is neither the root nor an
- ancestor of the <codeph class="+ topic/ph pr-d/codeph ">relatedObject</codeph>.
- <p class="- topic/p ">The purpose of the <codeph class="+ topic/ph pr-d/codeph ">rollOut</codeph> event is to simplify the
- coding of rollover behaviors for display object containers with children. When the mouse leaves
- the area of a display object or the area of any of its children to go to an object that is not
- one of its children, the display object dispatches the <codeph class="+ topic/ph pr-d/codeph ">rollOut</codeph> event. This is different behavior
- than that of the <codeph class="+ topic/ph pr-d/codeph ">mouseOut</codeph> event, which is dispatched each time the mouse leaves the
- area of any child object of the display object container, even if the mouse remains over another
- child object of the display object container.</p>
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.MOUSE_WHEEL_mouseWheel" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">mouseWheel</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a mouse wheel is spun over an InteractiveObject instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.MOUSE_WHEEL</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a mouse wheel is spun over an InteractiveObject instance.
- If the target is a text field, the text scrolls as the default behavior.
- Only available on Microsoft Windows operating systems.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.MOUSE_UP_mouseUp" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">mouseUp</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a user releases the pointing device button over an
- InteractiveObject instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.MOUSE_UP</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a user releases the pointing device button over an
- InteractiveObject instance.
- If the target is a SimpleButton instance, the object displays the <codeph class="+ topic/ph pr-d/codeph ">upState</codeph>
- display object.
- If the target is a selectable text field, the text field ends selection as the default
- behavior.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.MOUSE_OVER_mouseOver" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">mouseOver</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user moves a pointing device over an InteractiveObject instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.MOUSE_OVER</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user moves a pointing device over an InteractiveObject instance.
- The <codeph class="+ topic/ph pr-d/codeph ">relatedObject</codeph> is the object that was previously under
- the pointing device.
- If the target is a SimpleButton instance, the object displays the <codeph class="+ topic/ph pr-d/codeph ">overState</codeph>
- or <codeph class="+ topic/ph pr-d/codeph ">upState</codeph> display object, depending on whether the mouse button is down, as the default behavior.
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">mouseOver</codeph> event is dispatched each time the mouse enters the area of any child object of the display object container,
- even if the mouse was already over another child object of the display object container.
- This is different behavior than the purpose of the <codeph class="+ topic/ph pr-d/codeph ">rollOver</codeph> event, which is to simplify the coding of rollout behaviors for
- display object containers with children. When the mouse enters the area of a display object or the area of any of its children from an object
- that is not one of its children, the display object dispatches the <codeph class="+ topic/ph pr-d/codeph ">rollOver</codeph> event.
- The <codeph class="+ topic/ph pr-d/codeph ">rollOver</codeph> events are dispatched consecutively down the parent chain of the object,
- starting with the highest parent that is neither the root nor an ancestor of the <codeph class="+ topic/ph pr-d/codeph ">relatedObject</codeph> and ending with the object.</p>
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.MOUSE_OUT_mouseOut" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">mouseOut</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user moves a pointing device away from an InteractiveObject instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.MOUSE_OUT</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user moves a pointing device away from an InteractiveObject instance.
- The event target is the object previously under the pointing device. The <codeph class="+ topic/ph pr-d/codeph ">relatedObject</codeph>
- is the object the pointing device has moved to.
- If the target is a SimpleButton instance, the button displays the <codeph class="+ topic/ph pr-d/codeph ">upState</codeph>
- display object as the default behavior.
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">mouseOut</codeph> event is dispatched each time the mouse leaves the
- area of any child object of the display object container, even if the mouse remains over another
- child object of the display object container. This is different behavior than the purpose of the <codeph class="+ topic/ph pr-d/codeph ">rollOut</codeph> event, which is to simplify the
- coding of rollover behaviors for display object containers with children. When the mouse leaves
- the area of a display object or the area of any of its children to go to an object that is not
- one of its children, the display object dispatches the <codeph class="+ topic/ph pr-d/codeph ">rollOut</codeph> event.The <codeph class="+ topic/ph pr-d/codeph ">rollOut</codeph> events are dispatched consecutively
- up the parent chain of the object, starting with the object and ending with the highest parent that is neither the root nor an
- ancestor of the <codeph class="+ topic/ph pr-d/codeph ">relatedObject</codeph>.</p>
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.MOUSE_MOVE_mouseMove" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">mouseMove</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a user moves the pointing device while it is over an InteractiveObject.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.MOUSE_MOVE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a user moves the pointing device while it is over an InteractiveObject.
- If the target is a text field that the user is selecting, the selection is updated as the default behavior.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.MOUSE_DOWN_mouseDown" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">mouseDown</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a user presses the pointing device button over an InteractiveObject instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.MOUSE_DOWN</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a user presses the pointing device button over an InteractiveObject instance.
- If the target is a SimpleButton instance, the SimpleButton instance displays the
- <codeph class="+ topic/ph pr-d/codeph ">downState</codeph> display object as the default behavior. If the target is a
- selectable text field, the text field begins selection as the default behavior.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.DOUBLE_CLICK_doubleClick" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">doubleClick</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a user presses and releases the main button of a pointing device twice in
- rapid succession over the same InteractiveObject when that object's
- doubleClickEnabled flag is set to true.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.DOUBLE_CLICK</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a user presses and releases the main button of a pointing device twice in
- rapid succession over the same InteractiveObject when that object's
- <codeph class="+ topic/ph pr-d/codeph ">doubleClickEnabled</codeph> flag is set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.
- For a <codeph class="+ topic/ph pr-d/codeph ">doubleClick</codeph> event to occur, it must immediately follow the following
- series of events: <codeph class="+ topic/ph pr-d/codeph ">mouseDown</codeph>, <codeph class="+ topic/ph pr-d/codeph ">mouseUp</codeph>, <codeph class="+ topic/ph pr-d/codeph ">click</codeph>,
- <codeph class="+ topic/ph pr-d/codeph ">mouseDown</codeph>, <codeph class="+ topic/ph pr-d/codeph ">mouseUp</codeph>. All of these events must share the same
- target as the <codeph class="+ topic/ph pr-d/codeph ">doubleClick</codeph> event. The second click, represented by
- the second <codeph class="+ topic/ph pr-d/codeph ">mouseDown</codeph> and <codeph class="+ topic/ph pr-d/codeph ">mouseUp</codeph> events, must occur within
- a specific period of time after the <codeph class="+ topic/ph pr-d/codeph ">click</codeph> event. The allowable length of
- this period varies by operating system and can often be configured by the user.
- If the target is a selectable text field, the word under the pointer is selected as the
- default behavior. If the target InteractiveObject does not have its
- <codeph class="+ topic/ph pr-d/codeph ">doubleClickEnabled</codeph> flag set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph> it receives two
- <codeph class="+ topic/ph pr-d/codeph ">click</codeph> events.
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">doubleClickEnabled</codeph> property defaults
- to <codeph class="+ topic/ph pr-d/codeph ">false</codeph>. </p>
-
- <p class="- topic/p ">The double-click text selection behavior of a TextField object
- is not related to the <codeph class="+ topic/ph pr-d/codeph ">doubleClick</codeph> event. Use
- <codeph class="+ topic/ph pr-d/codeph ">TextField.doubleClickEnabled</codeph> to control TextField selections.</p>
- </apiDesc></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/doubleClickEnabled" class="- topic/link "><linktext class="- topic/linktext ">doubleClickEnabled</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.MouseEvent.CLICK_click" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">click</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a user presses and releases the main button of the user's
- pointing device over the same InteractiveObject.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.MouseEvent.CLICK</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.MouseEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a user presses and releases the main button of the user's
- pointing device over the same InteractiveObject. For a click event to occur, it must always follow this series of
- events in the order of occurrence: mouseDown event, then mouseUp. The target object
- must be identical for both of these events; otherwise the <codeph class="+ topic/ph pr-d/codeph ">click</codeph> event does not
- occur. Any number of other mouse events can occur at any time between the
- <codeph class="+ topic/ph pr-d/codeph ">mouseDown</codeph> or <codeph class="+ topic/ph pr-d/codeph ">mouseUp</codeph> events; the <codeph class="+ topic/ph pr-d/codeph ">click</codeph> event
- still occurs.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.FocusEvent.MOUSE_FOCUS_CHANGE_mouseFocusChange" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">mouseFocusChange</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user attempts to change focus by using a pointer device.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.FocusEvent.MOUSE_FOCUS_CHANGE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.FocusEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user attempts to change focus by using a pointer device.
- The default behavior of this event is to change the focus and dispatch the corresponding
- <codeph class="+ topic/ph pr-d/codeph ">focusIn</codeph> and <codeph class="+ topic/ph pr-d/codeph ">focusOut</codeph> events.
-
- <p class="- topic/p ">This event is dispatched to the object that currently has focus. The related object for this event is the
- InteractiveObject instance that receives focus if you do not prevent the default behavior. You can prevent the change in
- focus by calling <codeph class="+ topic/ph pr-d/codeph ">preventDefault()</codeph> in an event listener that is properly registered with the target object.
- The <codeph class="+ topic/ph pr-d/codeph ">shiftKey</codeph> property is not used. Focus changes and
- <codeph class="+ topic/ph pr-d/codeph ">focusIn</codeph> and <codeph class="+ topic/ph pr-d/codeph ">focusOut</codeph> events are dispatched by default.</p>
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.FocusEvent.KEY_FOCUS_CHANGE_keyFocusChange" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">keyFocusChange</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user attempts to change focus by using keyboard navigation.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.FocusEvent.KEY_FOCUS_CHANGE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.FocusEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user attempts to change focus by using keyboard navigation.
- The default behavior of this event is to change the focus and dispatch the
- corresponding <codeph class="+ topic/ph pr-d/codeph ">focusIn</codeph> and <codeph class="+ topic/ph pr-d/codeph ">focusOut</codeph> events.
-
- <p class="- topic/p ">This event is dispatched to the object that currently has focus.
- The related object for this event is the InteractiveObject instance that receives focus
- if you do not prevent the default behavior.
- You can prevent the change in focus by calling the <codeph class="+ topic/ph pr-d/codeph ">preventDefault()</codeph> method
- in an event listener that is properly registered with the target object.
- Focus changes and <codeph class="+ topic/ph pr-d/codeph ">focusIn</codeph> and <codeph class="+ topic/ph pr-d/codeph ">focusOut</codeph>
- events are dispatched by default.</p>
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.FocusEvent.FOCUS_OUT_focusOut" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">focusOut</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched after a display object loses focus.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.FocusEvent.FOCUS_OUT</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.FocusEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched <i class="+ topic/ph hi-d/i ">after</i> a display object loses focus.
- This happens when a user highlights a different object with a pointing device or keyboard navigation.
- The object that loses focus is called the target object of this event, while the corresponding InteractiveObject
- instance that receives focus is called the related object. A reference to the related object is stored in the target object's
- <codeph class="+ topic/ph pr-d/codeph ">relatedObject</codeph> property. The <codeph class="+ topic/ph pr-d/codeph ">shiftKey</codeph> property is not used. This event precedes the dispatch
- of the <codeph class="+ topic/ph pr-d/codeph ">focusIn</codeph> event by the related object.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.FocusEvent.FOCUS_IN_focusIn" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">focusIn</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched after a display object gains focus.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.FocusEvent.FOCUS_IN</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.FocusEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched <i class="+ topic/ph hi-d/i ">after</i> a display object gains focus.
- This situation happens when a user highlights the object with a pointing device or keyboard navigation.
- The recipient of such focus is called the target object of this event,
- while the corresponding InteractiveObject instance that lost focus because of this change is called the related object.
- A reference to the related object is stored in the receiving object's <codeph class="+ topic/ph pr-d/codeph ">relatedObject</codeph> property.
- The <codeph class="+ topic/ph pr-d/codeph ">shiftKey</codeph> property is not used.
- This event follows the dispatch of the previous object's <codeph class="+ topic/ph pr-d/codeph ">focusOut</codeph> event.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.Event.SELECT_ALL_selectAll" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">selectAll</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user activates the platform-specific accelerator key combination for a select all operation
- or selects 'Select All' from the text context menu.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.SELECT_ALL</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user activates the platform-specific accelerator key combination for a select all operation
- or selects 'Select All' from the text context menu.
- This event is dispatched to the object that currently has focus.
- If the object that currently has focus is a TextField, the default behavior of this event is to cause
- all the contents of the text field to be selected.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.Event.PASTE_paste" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">paste</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user activates the platform-specific accelerator key combination for a paste operation
- or selects 'Paste' from the text context menu.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.PASTE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user activates the platform-specific accelerator key combination for a paste operation
- or selects 'Paste' from the text context menu.
- This event is dispatched to the object that currently has focus.
- If the object that currently has focus is a TextField, the default behavior of this event is to cause
- the contents of the clipboard to be pasted into the text field at the current insertion point
- replacing any currently selected text in the text field.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.Event.CUT_cut" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">cut</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user activates the platform-specific accelerator key combination for a cut operation
- or selects 'Cut' from the text context menu.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.CUT</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user activates the platform-specific accelerator key combination for a cut operation
- or selects 'Cut' from the text context menu.
- This event is dispatched to the object that currently has focus.
- If the object that currently has focus is a TextField, the default behavior of this event is to cause
- any currently selected text in the text field to be cut to the clipboard.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.Event.COPY_copy" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">copy</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user activates the platform-specific accelerator key combination for a copy operation
- or selects 'Copy' from the text context menu.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.COPY</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user activates the platform-specific accelerator key combination for a copy operation
- or selects 'Copy' from the text context menu.
- This event is dispatched to the object that currently has focus.
- If the object that currently has focus is a TextField, the default behavior of this event is to cause
- any currently selected text in the text field to be copied to the clipboard.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:InteractiveObject_flash.events.Event.CLEAR_clear" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">clear</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when the user selects 'Clear' (or 'Delete') from the text context menu.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.CLEAR</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when the user selects 'Clear' (or 'Delete') from the text context menu.
- This event is dispatched to the object that currently has focus.
- If the object that currently has focus is a TextField, the default behavior of this event is to cause
- any currently selected text in the text field to be deleted.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><apiConstructor id="flash.display:InteractiveObject:InteractiveObject" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation apiOperation/apiConstructor"><apiName class="- topic/title reference/title apiRef/apiName ">InteractiveObject</apiName><shortdesc class="- topic/shortdesc ">
- Calling the new InteractiveObject() constructor
- throws an ArgumentError exception.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiConstructorDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail apiOperation/apiConstructorDetail"><apiConstructorDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiConstructorDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/></apiConstructorDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Calling the <codeph class="+ topic/ph pr-d/codeph ">new InteractiveObject()</codeph> constructor
- throws an <codeph class="+ topic/ph pr-d/codeph ">ArgumentError</codeph> exception.
- You can, however, call constructors for the following subclasses of InteractiveObject:
-
- <ul class="- topic/ul "><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">new SimpleButton()</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">new TextField()</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">new Loader()</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">new Sprite()</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">new MovieClip()</codeph></li></ul>
-
-
- </apiDesc></apiConstructorDetail></apiConstructor><apiOperation id="flash.display:InteractiveObject:requestSoftKeyboard" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">requestSoftKeyboard</apiName><shortdesc class="- topic/shortdesc ">
- Raises a virtual keyboard.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2.6" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A value of <codeph class="+ topic/ph pr-d/codeph ">true</codeph> means that the soft keyboard request was granted; <codeph class="+ topic/ph pr-d/codeph ">false</codeph> means that the soft keyboard was not raised.
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier></apiReturn><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">If the current context supports it, show the keyboard.
- </apiTipText></apiTipTexts></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Raises a virtual keyboard.
-
- <p class="- topic/p ">Calling this method focuses the InteractiveObject instance and raises the soft keyboard, if necessary.
- The <codeph class="+ topic/ph pr-d/codeph ">needsSoftKeyboard</codeph> must also be <codeph class="+ topic/ph pr-d/codeph ">true</codeph>. A keyboard is not raised
- if a hardware keyboard is available, or if the client system does not support virtual keyboards.</p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> This method is not supported in AIR applications on iOS.</p>
-
- </apiDesc></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/needsSoftKeyboard" class="- topic/link "><linktext class="- topic/linktext ">needsSoftKeyboard</linktext></link></related-links></apiOperation><apiValue id="flash.display:InteractiveObject:accessibilityImplementation:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">accessibilityImplementation</apiName><shortdesc class="- topic/shortdesc ">
- The current accessibility implementation (AccessibilityImplementation)
- for this InteractiveObject instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.accessibility:AccessibilityImplementation</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The current accessibility implementation (AccessibilityImplementation)
- for this InteractiveObject instance.
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.accessibility.xml#AccessibilityImplementation" class="- topic/link "><linktext class="- topic/linktext ">flash.accessibility.AccessibilityImplementation</linktext></link></related-links></apiValue><apiValue id="flash.display:InteractiveObject:contextMenu:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">contextMenu</apiName><shortdesc class="- topic/shortdesc ">
- Specifies the context menu associated with this object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:NativeMenu</apiValueClassifier><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">The context menu associated with this object
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies the context menu associated with this object.
-
- <p class="- topic/p ">For content running in Flash Player, this property is a ContextMenu object. In the AIR runtime,
- the ContextMenu class extends the NativeMenu class, however Flash Player only supports the
- ContextMenu class, not the NativeMenu class.
- </p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> TextField objects always include a clipboard menu in the context menu. The clipboard menu contains
- Cut, Copy, Paste, Clear, and Select All commands. You cannot remove these commands from the context menu for TextField objects.
- For TextField objects, selecting these commands (or their keyboard equivalents) does not generate <codeph class="+ topic/ph pr-d/codeph ">clear</codeph>,
- <codeph class="+ topic/ph pr-d/codeph ">copy</codeph>, <codeph class="+ topic/ph pr-d/codeph ">cut</codeph>, <codeph class="+ topic/ph pr-d/codeph ">paste</codeph>, or <codeph class="+ topic/ph pr-d/codeph ">selectAll</codeph> events.</p>
-
- </apiDesc><example conref="examples\ContextMenu_custom.as" class="- topic/example "> The following example shows how you can add a custom context menu item to a Sprite object by setting the Sprite's contextMenu property to a ContextMenu object.
- Example provided by
- <xref href="http://actionscriptexamples.com/2009/03/05/creating-a-custom-context-menu-item-in-flash-using-actionscript-30/" scope="_mmexternal" class="- topic/xref "> ActionScriptExamples.com</xref>.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- var red_cmi:ContextMenuItem = new ContextMenuItem("red");
- red_cmi.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, cmi_menuItemSelect);
-
- var cm:ContextMenu = new ContextMenu();
- cm.customItems.push(red_cmi);
- cm.hideBuiltInItems();
-
- var spr:Sprite = new Sprite();
- spr.contextMenu = cm;
- spr.graphics.beginFill(0x000000);
- spr.graphics.drawRect(0, 0, 120, 90);
- spr.graphics.endFill();
- spr.x = 10;
- spr.y = 10;
- addChild(spr);
-
- function cmi_menuItemSelect(evt:ContextMenuEvent):void {
- spr.graphics.clear();
- spr.graphics.beginFill(0xFF0000);
- spr.graphics.drawRect(0, 0, 120, 90);
- spr.graphics.endFill();
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:InteractiveObject:doubleClickEnabled:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">doubleClickEnabled</apiName><shortdesc class="- topic/shortdesc ">
- Specifies whether the object receives doubleClick events.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Whether this object receives double click messages.
-
-
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies whether the object receives <codeph class="+ topic/ph pr-d/codeph ">doubleClick</codeph> events. The default value
- is <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, which means that by default an InteractiveObject instance does not receive
- <codeph class="+ topic/ph pr-d/codeph ">doubleClick</codeph> events. If the <codeph class="+ topic/ph pr-d/codeph ">doubleClickEnabled</codeph> property is set to
- <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, the instance receives <codeph class="+ topic/ph pr-d/codeph ">doubleClick</codeph> events within its bounds.
- The <codeph class="+ topic/ph pr-d/codeph ">mouseEnabled</codeph> property of the InteractiveObject instance must also be
- set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph> for the object to receive <codeph class="+ topic/ph pr-d/codeph ">doubleClick</codeph> events.
-
- <p class="- topic/p ">No event is dispatched by setting this property. You must use the
- <codeph class="+ topic/ph pr-d/codeph ">addEventListener()</codeph> method to add an event listener
- for the <codeph class="+ topic/ph pr-d/codeph ">doubleClick</codeph> event.</p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:doubleClick" class="- topic/link "><linktext class="- topic/linktext ">doubleClick</linktext></link><link href="flash.display.xml#InteractiveObject/mouseEnabled" class="- topic/link "><linktext class="- topic/linktext ">mouseEnabled</linktext></link><link href="flash.display.xml#DisplayObjectContainer/mouseChildren" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObjectContainer.mouseChildren</linktext></link></related-links></apiValue><apiValue id="flash.display:InteractiveObject:focusRect:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">focusRect</apiName><shortdesc class="- topic/shortdesc ">
- Specifies whether this object displays a focus rectangle.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata><asCustoms class="+ topic/metadata adobe-api-d/asCustoms "><internal>FP IMD: See the AS2 MovieClip._focusRect, Button._focusRect, and
- _focusRect (global property) topics for information to migrate to the ASDoc description of this
- AS3 property.
-
-
- </internal></asCustoms></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Object</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies whether this object displays a focus rectangle. It can take one of three
- values: <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, or <codeph class="+ topic/ph pr-d/codeph ">null</codeph>. Values of <codeph class="+ topic/ph pr-d/codeph ">true</codeph>
- and <codeph class="+ topic/ph pr-d/codeph ">false</codeph> work as expected, specifying whether or not the focus rectangle
- appears. A value of <codeph class="+ topic/ph pr-d/codeph ">null</codeph> indicates that this object obeys the
- <codeph class="+ topic/ph pr-d/codeph ">stageFocusRect</codeph> property of the Stage.
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:InteractiveObject:mouseEnabled:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">mouseEnabled</apiName><shortdesc class="- topic/shortdesc ">
- Specifies whether this object receives mouse, or other user input, messages.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies whether this object receives mouse, or other user input, messages. The default value is <codeph class="+ topic/ph pr-d/codeph ">true</codeph>,
- which means that by default any InteractiveObject instance that is on the display list
- receives mouse events or other user input events.
- If <codeph class="+ topic/ph pr-d/codeph ">mouseEnabled</codeph> is set to <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, the instance does not receive any
- mouse events (or other user input events like keyboard events). Any children of this instance on the display list are not affected. To change
- the <codeph class="+ topic/ph pr-d/codeph ">mouseEnabled</codeph> behavior for all children of an object on the display list, use
- <codeph class="+ topic/ph pr-d/codeph ">flash.display.DisplayObjectContainer.mouseChildren</codeph>.
- <p class="- topic/p "> No event is dispatched by setting this property. You must use the
- <codeph class="+ topic/ph pr-d/codeph ">addEventListener()</codeph> method to create interactive functionality.</p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObjectContainer/mouseChildren" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObjectContainer.mouseChildren</linktext></link></related-links></apiValue><apiValue id="flash.display:InteractiveObject:needsSoftKeyboard:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">needsSoftKeyboard</apiName><shortdesc class="- topic/shortdesc ">
- Specifies whether a virtual keyboard (an on-screen, software keyboard) should display
- when this InteractiveObject instance receives focus.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2.6" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies whether a virtual keyboard (an on-screen, software keyboard) should display
- when this InteractiveObject instance receives focus.
-
- <p class="- topic/p ">By default, the value is <codeph class="+ topic/ph pr-d/codeph ">false</codeph> and focusing an InteractiveObject instance does
- not raise a soft keyboard. If the <codeph class="+ topic/ph pr-d/codeph ">needsSoftKeyboard</codeph> property is set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>,
- the runtime raises a soft keyboard when the InteractiveObject instance is ready to accept user input.
- An InteractiveObject instance is ready to accept user input after a programmatic call to set the Stage
- <codeph class="+ topic/ph pr-d/codeph ">focus</codeph> property or a user interaction, such as a "tap." If the client system has a
- hardware keyboard available or does not support virtual keyboards, then the soft keyboard is not raised.</p>
-
- <p class="- topic/p ">The InteractiveObject instance dispatches <codeph class="+ topic/ph pr-d/codeph ">softKeyboardActivating</codeph>,
- <codeph class="+ topic/ph pr-d/codeph ">softKeyboardActivate</codeph>, and <codeph class="+ topic/ph pr-d/codeph ">softKeyboardDeactivate</codeph> events
- when the soft keyboard raises and lowers.</p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> This property is not supported in AIR applications on iOS.</p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/event:softKeyboardActivating" class="- topic/link "><linktext class="- topic/linktext ">softKeyboardActivating</linktext></link><link href="flash.display.xml#InteractiveObject/event:softKeyboardActivate" class="- topic/link "><linktext class="- topic/linktext ">softKeyboardActivate</linktext></link><link href="flash.display.xml#InteractiveObject/event:softKeyboardDeactivate" class="- topic/link "><linktext class="- topic/linktext ">softKeyboardDeactivate</linktext></link></related-links></apiValue><apiValue id="flash.display:InteractiveObject:softKeyboardInputAreaOfInterest:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">softKeyboardInputAreaOfInterest</apiName><shortdesc class="- topic/shortdesc ">
- Defines the area that should remain on-screen when a soft keyboard is displayed.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2.6" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.geom:Rectangle</apiValueClassifier><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Sets the area to be displayed on-screen when the soft keyboard opens.
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Defines the area that should remain on-screen when a soft keyboard is displayed.
-
- <p class="- topic/p ">If the <codeph class="+ topic/ph pr-d/codeph ">needsSoftKeyboard</codeph> property of this InteractiveObject is
- <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, then the runtime adjusts the display as needed to keep the
- object in view while the user types. Ordinarily, the runtime uses the object
- bounds obtained from the <codeph class="+ topic/ph pr-d/codeph ">DisplayObject.getBounds()</codeph> method. You can
- specify a different area using this <codeph class="+ topic/ph pr-d/codeph ">softKeyboardInputAreaOfInterest</codeph>
- property.</p>
-
- <p class="- topic/p ">Specify the <codeph class="+ topic/ph pr-d/codeph ">softKeyboardInputAreaOfInterest</codeph> in stage coordinates.</p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> On Android, the <codeph class="+ topic/ph pr-d/codeph ">softKeyboardInputAreaOfInterest</codeph> is not
- respected in landscape orientations.</p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject/getBounds()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObject.getBounds()</linktext></link></related-links></apiValue><apiValue id="flash.display:InteractiveObject:tabEnabled:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">tabEnabled</apiName><shortdesc class="- topic/shortdesc ">
- Specifies whether this object is in the tab order.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata><asCustoms class="+ topic/metadata adobe-api-d/asCustoms "><internal>FP IMD: See the AS2 MovieClip.tabEnabled, Button.tabEnabled, and
- TextField.tabEnabled topics for information to migrate to the ASDoc description of this
- AS3 property.
-
-
- </internal></asCustoms></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Whether this object is in the tab order.
-
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies whether this object is in the tab order. If this object is in the tab order,
- the value is <codeph class="+ topic/ph pr-d/codeph ">true</codeph>; otherwise, the value is <codeph class="+ topic/ph pr-d/codeph ">false</codeph>. By default,
- the value is <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, except for the following:
- <ul class="- topic/ul "><li class="- topic/li ">For a SimpleButton object, the value is <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.</li><li class="- topic/li ">For a TextField object with <codeph class="+ topic/ph pr-d/codeph ">type = "input"</codeph>, the value is <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.</li><li class="- topic/li ">For a Sprite object or MovieClip object with <codeph class="+ topic/ph pr-d/codeph ">buttonMode = true</codeph>, the value is <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.</li></ul>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:InteractiveObject:tabIndex:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">tabIndex</apiName><shortdesc class="- topic/shortdesc ">
- Specifies the tab ordering of objects in a SWF file.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">int</apiValueClassifier><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">The tab index for this object.
-
-
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies the tab ordering of objects in a SWF file. The <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph>
- property is -1 by default, meaning no tab index is set for the object.
-
- <p class="- topic/p ">If any currently displayed object in the SWF file contains a <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph> property, automatic
- tab ordering is disabled, and the tab ordering is calculated from the <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph> properties of
- objects in the SWF file. The custom tab ordering includes only objects that have <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph>
- properties.</p>
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph> property can be a non-negative integer. The objects are ordered according to
- their <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph> properties, in ascending order. An object with a <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph>
- value of 1 precedes an object with a <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph> value of 2. Do not use the same <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph>
- value for multiple objects.</p>
-
- <p class="- topic/p ">The custom tab ordering that the <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph> property defines is <i class="+ topic/ph hi-d/i ">flat</i>.
- This means that no attention is paid to the hierarchical relationships of objects in the SWF file.
- All objects in the SWF file with <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph> properties are placed in the tab order, and the
- tab order is determined by the order of the <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph> values. </p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> To set the tab order for TLFTextField instances, cast the display object child
- of the TLFTextField as an InteractiveObject, then set the <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph> property. For example:
- <pre xml:space="preserve" class="- topic/pre ">
- InteractiveObject(tlfInstance.getChildAt(1)).tabIndex = 3;
- </pre>
- To reverse the tab order from the default setting for three instances of a TLFTextField object
- (<codeph class="+ topic/ph pr-d/codeph ">tlfInstance1</codeph>, <codeph class="+ topic/ph pr-d/codeph ">tlfInstance2</codeph> and <codeph class="+ topic/ph pr-d/codeph ">tlfInstance3</codeph>), use:
- <pre xml:space="preserve" class="- topic/pre ">
- InteractiveObject(tlfInstance1.getChildAt(1)).tabIndex = 3;
- InteractiveObject(tlfInstance2.getChildAt(1)).tabIndex = 2;
- InteractiveObject(tlfInstance3.getChildAt(1)).tabIndex = 1;
- </pre>
- </p>
-
- </apiDesc></apiValueDetail></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:GraphicsTrianglePath" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">GraphicsTrianglePath</apiName><shortdesc class="- topic/shortdesc ">
- Defines an ordered set of triangles that can be rendered using
- either (u,v) fill coordinates or a normal fill.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiFinal class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiFinal "/><apiBaseInterface>flash.display:IGraphicsPath</apiBaseInterface><apiBaseInterface>flash.display:IGraphicsData</apiBaseInterface><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">Object</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Defines an ordered set of triangles that can be rendered using
- either (u,v) fill coordinates or a normal fill.
-
- Each triangle in the path is represented by three sets of (x, y)
- coordinates, each of which is one point of the triangle.
-
- <p class="- topic/p ">
- The triangle vertices do not contain z coordinates and do not necessarily
- represent 3D faces. However a triangle path can be used to support the rendering
- of 3D geometry in a 2D space.
- </p>
-
- </apiDesc></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Graphics/drawTriangles()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.drawTriangles()</linktext></link></related-links><apiConstructor id="flash.display:GraphicsTrianglePath:GraphicsTrianglePath" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation apiOperation/apiConstructor"><apiName class="- topic/title reference/title apiRef/apiName ">GraphicsTrianglePath</apiName><shortdesc class="- topic/shortdesc ">
- Creates a new GraphicsTrianglePath object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiConstructorDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail apiOperation/apiConstructorDetail"><apiConstructorDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiConstructorDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">vertices</apiItemName><apiType value="Vector$Number" name="type" class="- topic/state reference/state apiRef/apiType "/><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A Vector of Numbers where each pair of numbers is treated as a point (an x, y pair). Required.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">indices</apiItemName><apiType value="Vector$int" name="type" class="- topic/state reference/state apiRef/apiType "/><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A Vector of integers or indexes, where every three indexes define a triangle.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">uvtData</apiItemName><apiType value="Vector$Number" name="type" class="- topic/state reference/state apiRef/apiType "/><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A Vector of normalized coordinates used to apply texture mapping.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">culling</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">String</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">none</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Specifies whether to render triangles that face in a given direction. Used to
- prevent the rendering of triangles that cannot be seen in the current view.
- Can be set to any value defined by the TriangleCulling class.
-
- </apiDesc></apiParam></apiConstructorDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Creates a new GraphicsTrianglePath object.
-
- </apiDesc></apiConstructorDetail><related-links class="- topic/related-links "><link href="flash.display.xml#GraphicsTrianglePath/culling" class="- topic/link "><linktext class="- topic/linktext ">culling</linktext></link><link href="flash.display.xml#TriangleCulling" class="- topic/link "><linktext class="- topic/linktext ">flash.display.TriangleCulling</linktext></link></related-links></apiConstructor><apiValue id="flash.display:GraphicsTrianglePath:indices" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">indices</apiName><shortdesc class="- topic/shortdesc ">
- A Vector of integers or indexes, where every three indexes define a triangle.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiType value="Vector$int" name="type" class="- topic/state reference/state apiRef/apiType "/></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- A Vector of integers or indexes, where every three indexes define a triangle. If the indexes parameter
- is null then every three vertices (six x,y pairs in the vertices Vector) defines a triangle.
- Otherwise each index refers to a vertex, which is a pair of numbers in the vertices Vector.
- For example <codeph class="+ topic/ph pr-d/codeph ">indexes[1]</codeph> refers to (<codeph class="+ topic/ph pr-d/codeph ">vertices[2]</codeph>, <codeph class="+ topic/ph pr-d/codeph ">vertices[3]</codeph>).
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:GraphicsTrianglePath:uvtData" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">uvtData</apiName><shortdesc class="- topic/shortdesc ">
- A Vector of normalized coordinates used to apply texture mapping.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiType value="Vector$Number" name="type" class="- topic/state reference/state apiRef/apiType "/></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- A Vector of normalized coordinates used to apply texture mapping.
- Each coordinate refers to a point on the bitmap used for the fill.
- There must be one UV or one UVT coordinate per vertex.
-
- <p class="- topic/p ">
- In UV coordinates, (0,0) is the upper left of the bitmap, and (1,1) is the lower right of the bitmap.
- </p>
-
- <p class="- topic/p ">
- If the length of this vector is twice the length of the <codeph class="+ topic/ph pr-d/codeph ">vertices</codeph> vector then normalized
- coordinates are used without perspective correction.
- </p>
-
- <p class="- topic/p ">
- If the length of this vector is three times the length of the <codeph class="+ topic/ph pr-d/codeph ">vertices</codeph> vector then the
- third coordinate is interpreted as 't', the distance from the eye to the texture in eye space.
- This helps the rendering engine correctly apply perspective when mapping textures in 3D.
- </p>
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:GraphicsTrianglePath:vertices" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">vertices</apiName><shortdesc class="- topic/shortdesc ">
- A Vector of Numbers where each pair of numbers is treated as a point (an x, y pair).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiType value="Vector$Number" name="type" class="- topic/state reference/state apiRef/apiType "/></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- A Vector of Numbers where each pair of numbers is treated as a point (an x, y pair).
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:GraphicsTrianglePath:culling:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">culling</apiName><shortdesc class="- topic/shortdesc ">
- Specifies whether to render triangles that face in a given direction.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies whether to render triangles that face in a given direction. Used to
- prevent the rendering of triangles that cannot be seen in the current view.
- <p class="- topic/p ">
- Can be set to any value defined by the TriangleCulling class.
- </p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#TriangleCulling" class="- topic/link "><linktext class="- topic/linktext ">flash.display.TriangleCulling</linktext></link></related-links></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:DisplayObject" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">DisplayObject</apiName><shortdesc class="- topic/shortdesc ">
- The DisplayObject class is the base class for all objects that can be placed on
- the display list.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiBaseInterface>flash.display:IBitmapDrawable</apiBaseInterface><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">flash.events:EventDispatcher</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The DisplayObject class is the base class for all objects that can be placed on
- the display list. The display list manages all objects displayed in the Flash runtimes.
- Use the DisplayObjectContainer class to arrange the display objects in the display list.
- DisplayObjectContainer objects can have child display objects, while other display objects, such as
- Shape and TextField objects, are "leaf" nodes that have only parents and siblings, no children.
-
- <p class="- topic/p ">The DisplayObject class supports basic functionality like the <i class="+ topic/ph hi-d/i ">x</i> and <i class="+ topic/ph hi-d/i ">y</i> position of
- an object, as well as more advanced properties of the object such as its transformation matrix.
- </p>
-
- <p class="- topic/p ">DisplayObject is an abstract base class; therefore, you cannot call DisplayObject directly. Invoking
- <codeph class="+ topic/ph pr-d/codeph ">new DisplayObject()</codeph> throws an <codeph class="+ topic/ph pr-d/codeph ">ArgumentError</codeph> exception. </p>
-
- <p class="- topic/p ">All display objects inherit from the DisplayObject class.</p>
-
- <p class="- topic/p ">The DisplayObject class itself does not include any APIs for rendering content onscreen.
- For that reason, if you want create a custom subclass of the DisplayObject class, you will want
- to extend one of its subclasses that do have APIs for rendering content onscreen,
- such as the Shape, Sprite, Bitmap, SimpleButton, TextField, or MovieClip class.</p>
-
- <p class="- topic/p ">The DisplayObject class contains several broadcast events. Normally, the target
- of any particular event is a specific DisplayObject instance. For example,
- the target of an <codeph class="+ topic/ph pr-d/codeph ">added</codeph> event is the specific DisplayObject instance
- that was added to the display list. Having a single target restricts the placement of
- event listeners to that target and in some cases the target's ancestors on the display list.
- With broadcast events, however, the target is not a specific DisplayObject instance,
- but rather all DisplayObject instances, including those that are not on the display list.
- This means that you can add a listener to any DisplayObject instance to listen for broadcast events.
- In addition to the broadcast events listed in the DisplayObject class's Events table,
- the DisplayObject class also inherits two broadcast events from the EventDispatcher
- class: <codeph class="+ topic/ph pr-d/codeph ">activate</codeph> and <codeph class="+ topic/ph pr-d/codeph ">deactivate</codeph>.</p>
-
- <p class="- topic/p ">Some properties previously used in the ActionScript 1.0 and 2.0 MovieClip, TextField, and Button
- classes (such as <codeph class="+ topic/ph pr-d/codeph ">_alpha</codeph>, <codeph class="+ topic/ph pr-d/codeph ">_height</codeph>, <codeph class="+ topic/ph pr-d/codeph ">_name</codeph>, <codeph class="+ topic/ph pr-d/codeph ">_width</codeph>,
- <codeph class="+ topic/ph pr-d/codeph ">_x</codeph>, <codeph class="+ topic/ph pr-d/codeph ">_y</codeph>, and others) have equivalents in the ActionScript 3.0
- DisplayObject class that are renamed so that they no longer begin with the underscore (_) character.</p>
-
- <p class="- topic/p ">For more information, see the "Display Programming" chapter of the <i class="+ topic/ph hi-d/i ">ActionScript 3.0 Developer's Guide</i>.</p>
-
- </apiDesc><example conref="examples\DisplayObjectExample.as" class="- topic/example "> The following example uses the <codeph class="+ topic/ph pr-d/codeph ">DisplayObjectExample</codeph> class to
- draw an orange square in the corner of the Stage and then respond to events by displaying text
- information for each event. This task is accomplished by performing the following steps:
- <ol class="- topic/ol "><li class="- topic/li ">Class properties are declared for the color and size of the square.</li><li class="- topic/li ">The constructor calls the <codeph class="+ topic/ph pr-d/codeph ">draw()</codeph> method, which draws an orange square on
- the Stage at the default coordinates of <i class="+ topic/ph hi-d/i ">x = 0, y = 0</i>.</li><li class="- topic/li ">The following event listener methods are attached to the square:
- <ul class="- topic/ul "><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">addedHandler()</codeph> listens for <codeph class="+ topic/ph pr-d/codeph ">added</codeph> events, dispatched when the
- square is added to the display list.</li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">enterFrameHandler()</codeph> listens for <codeph class="+ topic/ph pr-d/codeph ">enterFrame</codeph> events, which have no
- real meaning in this example.</li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">removedHandler()</codeph> listens for <codeph class="+ topic/ph pr-d/codeph ">removed</codeph> events, dispatched when
- the square is removed from the display list, which happens when the square is clicked.</li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">clickHandler()</codeph> listens for <codeph class="+ topic/ph pr-d/codeph ">click</codeph> events, dispatched when the
- orange square is clicked.</li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">renderHandler()</codeph> listens for <codeph class="+ topic/ph pr-d/codeph ">render</codeph> events after the display
- list is updated.</li></ul></li></ol>
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- package {
- import flash.display.Sprite;
- public class DisplayObjectExample extends Sprite {
- public function DisplayObjectExample() {
- var child:CustomDisplayObject = new CustomDisplayObject();
- addChild(child);
- }
- }
- }
- import flash.display.DisplayObject;
- import flash.display.Sprite;
- import flash.display.Stage;
- import flash.display.StageAlign;
- import flash.display.StageScaleMode;
- import flash.events.*;
- class CustomDisplayObject extends Sprite {
- private var bgColor:uint = 0xFFCC00;
- private var size:uint = 80;
- public function CustomDisplayObject() {
- draw();
- addEventListener(Event.ADDED, addedHandler);
- addEventListener(Event.ENTER_FRAME, enterFrameHandler);
- addEventListener(Event.REMOVED, removedHandler);
- addEventListener(MouseEvent.CLICK, clickHandler);
- addEventListener(Event.RENDER, renderHandler);
- }
- private function draw():void {
- graphics.beginFill(bgColor);
- graphics.drawRect(0, 0, size, size);
- graphics.endFill();
- }
- private function clickHandler(event:MouseEvent):void {
- trace("clickHandler: " + event);
- parent.removeChild(this);
- }
- private function addedHandler(event:Event):void {
- trace("addedHandler: " + event);
- stage.scaleMode = StageScaleMode.NO_SCALE;
- stage.align = StageAlign.TOP_LEFT;
- stage.addEventListener("resize", resizeHandler);
- }
- private function enterFrameHandler(event:Event):void {
- trace("enterFrameHandler: " + event);
- removeEventListener("enterFrame", enterFrameHandler);
- }
- private function removedHandler(event:Event):void {
- trace("removedHandler: " + event);
- stage.removeEventListener("resize", resizeHandler);
- }
- private function renderHandler(event:Event):void {
- trace("renderHandler: " + event);
- }
- private function resizeHandler(event:Event):void {
- trace("resizeHandler: " + event);
- }
- }
- </codeblock></example></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObjectContainer" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObjectContainer</linktext></link></related-links><adobeApiEvent id="flash.display:DisplayObject_flash.events.Event.RENDER_render" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">render</apiName><shortdesc class="- topic/shortdesc ">
- [broadcast event] Dispatched when the display list is about to be updated and rendered.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.RENDER</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- [broadcast event] Dispatched when the display list is about to be updated and rendered. This event provides the last opportunity
- for objects listening for this event to make changes before the display list is rendered.
- You must call the <codeph class="+ topic/ph pr-d/codeph ">invalidate()</codeph> method
- of the Stage object
- each time you want a <codeph class="+ topic/ph pr-d/codeph ">render</codeph> event to be dispatched. <codeph class="+ topic/ph pr-d/codeph ">Render</codeph> events
- are dispatched to an object only if there is mutual trust between it and the object that called
- <codeph class="+ topic/ph pr-d/codeph ">Stage.invalidate()</codeph>.
- This event is a broadcast event, which means that it is dispatched
- by all display objects with a listener registered for this event.
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note: </b>This event is not dispatched if the display is
- not rendering. This is the case when the content is either minimized or obscured. </p>
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:DisplayObject_flash.events.Event.REMOVED_FROM_STAGE_removedFromStage" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">removedFromStage</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a display object is about to be removed from the display list,
- either directly or through the removal of a sub tree in which the display object is contained.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9.0.28.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.REMOVED_FROM_STAGE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a display object is about to be removed from the display list,
- either directly or through the removal of a sub tree in which the display object is contained.
- Two methods of the DisplayObjectContainer class generate this event:
- <codeph class="+ topic/ph pr-d/codeph ">removeChild()</codeph> and <codeph class="+ topic/ph pr-d/codeph ">removeChildAt()</codeph>.
-
- <p class="- topic/p ">The following methods of a DisplayObjectContainer object also generate this event if an object must be removed
- to make room for the new object: <codeph class="+ topic/ph pr-d/codeph ">addChild()</codeph>, <codeph class="+ topic/ph pr-d/codeph ">addChildAt()</codeph>, and
- <codeph class="+ topic/ph pr-d/codeph ">setChildIndex()</codeph>. </p>
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:DisplayObject_flash.events.Event.REMOVED_removed" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">removed</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a display object is about to be removed from the display list.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.REMOVED</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a display object is about to be removed from the display list.
- Two methods of the DisplayObjectContainer class generate this event:
- <codeph class="+ topic/ph pr-d/codeph ">removeChild()</codeph> and <codeph class="+ topic/ph pr-d/codeph ">removeChildAt()</codeph>.
-
- <p class="- topic/p ">The following methods of a DisplayObjectContainer object also generate this event if an object must be removed
- to make room for the new object: <codeph class="+ topic/ph pr-d/codeph ">addChild()</codeph>, <codeph class="+ topic/ph pr-d/codeph ">addChildAt()</codeph>, and
- <codeph class="+ topic/ph pr-d/codeph ">setChildIndex()</codeph>. </p>
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:DisplayObject_flash.events.Event.EXIT_FRAME_exitFrame" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">exitFrame</apiName><shortdesc class="- topic/shortdesc ">
- [broadcast event] Dispatched when the playhead is exiting the current frame.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.EXIT_FRAME</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- [broadcast event] Dispatched when the playhead is exiting the current frame.
- All frame scripts have been run. If the playhead is not moving, or if there is only one frame, this event
- is dispatched continuously in conjunction with the frame rate.
- This event is a broadcast event, which means that it is dispatched
- by all display objects with a listener registered for this event.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:DisplayObject_flash.events.Event.FRAME_CONSTRUCTED_frameConstructed" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">frameConstructed</apiName><shortdesc class="- topic/shortdesc ">
- [broadcast event] Dispatched after the constructors of frame display objects have run but before frame scripts have run.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.FRAME_CONSTRUCTED</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- [broadcast event] Dispatched after the constructors of frame display objects have run but before frame scripts have run.
- If the playhead is not moving, or if there is only one frame, this event
- is dispatched continuously in conjunction with the frame rate.
- This event is a broadcast event, which means that it is dispatched
- by all display objects with a listener registered for this event.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:DisplayObject_flash.events.Event.ENTER_FRAME_enterFrame" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">enterFrame</apiName><shortdesc class="- topic/shortdesc ">
- [broadcast event] Dispatched when the playhead is entering a new
- frame.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.ENTER_FRAME</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- [broadcast event] Dispatched when the playhead is entering a new
- frame. If the playhead is not moving, or if there is only one frame, this event
- is dispatched continuously in conjunction with the frame rate.
- This event is a broadcast event, which means that it is dispatched
- by all display objects with a listener registered for this event.
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:DisplayObject_flash.events.Event.ADDED_TO_STAGE_addedToStage" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">addedToStage</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a display object is added to the on stage display list,
- either directly or through the addition of a sub tree in which the display object is contained.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9.0.28.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.ADDED_TO_STAGE</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a display object is added to the on stage display list,
- either directly or through the addition of a sub tree in which the display object is contained. The
- following methods trigger this event: <codeph class="+ topic/ph pr-d/codeph ">DisplayObjectContainer.addChild()</codeph>,
- <codeph class="+ topic/ph pr-d/codeph ">DisplayObjectContainer.addChildAt()</codeph>.
- </apiDesc></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObjectContainer/addChild()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObjectContainer.addChild()</linktext></link><link href="flash.display.xml#DisplayObjectContainer/addChildAt()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObjectContainer.addChildAt()</linktext></link></related-links></adobeApiEvent><adobeApiEvent id="flash.display:DisplayObject_flash.events.Event.ADDED_added" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">added</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched when a display object is added to the display list.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.ADDED</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched when a display object is added to the display list. The
- following methods trigger this event: <codeph class="+ topic/ph pr-d/codeph ">DisplayObjectContainer.addChild()</codeph>,
- <codeph class="+ topic/ph pr-d/codeph ">DisplayObjectContainer.addChildAt()</codeph>.
- </apiDesc></adobeApiEventDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObjectContainer/addChild()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObjectContainer.addChild()</linktext></link><link href="flash.display.xml#DisplayObjectContainer/addChildAt()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObjectContainer.addChildAt()</linktext></link></related-links></adobeApiEvent><apiOperation id="flash.display:DisplayObject:getBounds" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">getBounds</apiName><shortdesc class="- topic/shortdesc ">
- Returns a rectangle that defines the area of the display object relative to the coordinate system
- of the targetCoordinateSpace object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The rectangle that defines the area of the display object relative to
- the <codeph class="+ topic/ph pr-d/codeph ">targetCoordinateSpace</codeph> object's coordinate system.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Rectangle</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">targetCoordinateSpace</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The display object that defines the coordinate system to use.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Returns a rectangle that defines the area of the display object relative to the coordinate system
- of the <codeph class="+ topic/ph pr-d/codeph ">targetCoordinateSpace</codeph> object.
- Consider the following code, which shows how the rectangle returned can vary depending on the
- <codeph class="+ topic/ph pr-d/codeph ">targetCoordinateSpace</codeph> parameter that you pass to the method:
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- var container:Sprite = new Sprite();
- container.x = 100;
- container.y = 100;
- this.addChild(container);
- var contents:Shape = new Shape();
- contents.graphics.drawCircle(0,0,100);
- container.addChild(contents);
- trace(contents.getBounds(container));
- // (x=-100, y=-100, w=200, h=200)
- trace(contents.getBounds(this));
- // (x=0, y=0, w=200, h=200)
- </codeblock>
-
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> Use the <codeph class="+ topic/ph pr-d/codeph ">localToGlobal()</codeph> and
- <codeph class="+ topic/ph pr-d/codeph ">globalToLocal()</codeph> methods to convert the display object's local coordinates
- to display coordinates, or display coordinates to local coordinates, respectively.</p>
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">getBounds()</codeph> method is similar to the <codeph class="+ topic/ph pr-d/codeph ">getRect()</codeph> method;
- however, the Rectangle returned by the <codeph class="+ topic/ph pr-d/codeph ">getBounds()</codeph> method includes any strokes
- on shapes, whereas the Rectangle returned by the <codeph class="+ topic/ph pr-d/codeph ">getRect()</codeph> method does not.
- For an example, see the description of the <codeph class="+ topic/ph pr-d/codeph ">getRect()</codeph> method.</p>
-
- </apiDesc></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject/getRect()" class="- topic/link "><linktext class="- topic/linktext ">getRect()</linktext></link><link href="flash.display.xml#DisplayObject/globalToLocal()" class="- topic/link "><linktext class="- topic/linktext ">globalToLocal()</linktext></link><link href="flash.display.xml#DisplayObject/localToGlobal()" class="- topic/link "><linktext class="- topic/linktext ">localToGlobal()</linktext></link></related-links></apiOperation><apiOperation id="flash.display:DisplayObject:getRect" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">getRect</apiName><shortdesc class="- topic/shortdesc ">
- Returns a rectangle that defines the boundary of the display object,
- based on the coordinate system defined by the targetCoordinateSpace
- parameter, excluding any strokes on shapes.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The rectangle that defines the area of the display object relative to
- the <codeph class="+ topic/ph pr-d/codeph ">targetCoordinateSpace</codeph> object's coordinate system.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Rectangle</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">targetCoordinateSpace</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The display object that defines the coordinate system to use.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Returns a rectangle that defines the boundary of the display object,
- based on the coordinate system defined by the <codeph class="+ topic/ph pr-d/codeph ">targetCoordinateSpace</codeph>
- parameter, excluding any strokes on shapes. The values that the <codeph class="+ topic/ph pr-d/codeph ">getRect()</codeph> method
- returns are the same or smaller than those returned by the <codeph class="+ topic/ph pr-d/codeph ">getBounds()</codeph> method.
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> Use <codeph class="+ topic/ph pr-d/codeph ">localToGlobal()</codeph> and <codeph class="+ topic/ph pr-d/codeph ">globalToLocal()</codeph> methods
- to convert the display object's local coordinates to Stage coordinates, or Stage coordinates to
- local coordinates, respectively.</p>
-
- </apiDesc><example conref="examples\DisplayObject.getRect.1.as" class="- topic/example "> The following example shows how the <codeph class="+ topic/ph pr-d/codeph ">getBounds()</codeph> method can return a larger
- rectangle than the <codeph class="+ topic/ph pr-d/codeph ">getRect()</codeph> method does, because of the additional area taken up by
- strokes. In this case, the <codeph class="+ topic/ph pr-d/codeph ">triangle</codeph> sprite includes extra strokes because of the
- <codeph class="+ topic/ph pr-d/codeph ">width</codeph> and <codeph class="+ topic/ph pr-d/codeph ">jointStyle</codeph> parameters of the <codeph class="+ topic/ph pr-d/codeph ">lineStyle()</codeph>
- method. The <codeph class="+ topic/ph pr-d/codeph ">trace()</codeph> output (in the last two lines) shows the differences between
- the <codeph class="+ topic/ph pr-d/codeph ">getRect()</codeph> and <codeph class="+ topic/ph pr-d/codeph ">getBounds()</codeph> rectangles:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.CapsStyle;
- import flash.display.JointStyle;
- import flash.display.LineScaleMode;
- import flash.display.Sprite;
- import flash.geom.Rectangle;
- var triangle:Sprite = new Sprite();
- var color:uint = 0xFF0044;
- var width:Number = 20;
- var alpha:Number = 1.0;
- var pixelHinting:Boolean = true;
- var scaleMode:String = LineScaleMode.NORMAL;
- var caps:String = CapsStyle.SQUARE;
- var joints:String = JointStyle.MITER;
- triangle.graphics.lineStyle(width, color, alpha, pixelHinting, scaleMode, caps, joints);
- var triangleSide:Number = 100;
- triangle.graphics.moveTo(0, 0);
- triangle.graphics.lineTo(0, triangleSide);
- triangle.graphics.lineTo(triangleSide, triangleSide);
- triangle.graphics.lineTo(0, 0);
- addChild(triangle);
- trace(triangle.getBounds(this)); // (x=-10, y=-24.1, w=134.10000000000002, h=134.1)
- trace(triangle.getRect(this)); // (x=0, y=0, w=100, h=100)
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject/getBounds()" class="- topic/link "><linktext class="- topic/linktext ">getBounds()</linktext></link></related-links></apiOperation><apiOperation id="flash.display:DisplayObject:globalToLocal3D" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">globalToLocal3D</apiName><shortdesc class="- topic/shortdesc ">
- Converts a two-dimensional point from the Stage (global) coordinates to a
- three-dimensional display object's (local) coordinates.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A Vector3D object with coordinates relative to the three-dimensional
- display object.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Vector3D</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">point</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Point</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A two dimensional Point object representing global x and y coordinates.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Converts a two-dimensional point from the Stage (global) coordinates to a
- three-dimensional display object's (local) coordinates.
-
- <p class="- topic/p ">To use this method, first create an instance of the Point class.
- The x and y values that you assign to the Point object represent global
- coordinates because they are relative to the origin (0,0) of the main display area.
- Then pass the Point object to the <codeph class="+ topic/ph pr-d/codeph ">globalToLocal3D()</codeph>
- method as the <codeph class="+ topic/ph pr-d/codeph ">point</codeph> parameter. The method returns three-dimensional
- coordinates as a Vector3D object containing <codeph class="+ topic/ph pr-d/codeph ">x</codeph>, <codeph class="+ topic/ph pr-d/codeph ">y</codeph>, and
- <codeph class="+ topic/ph pr-d/codeph ">z</codeph> values that are relative to the origin
- of the three-dimensional display object.</p>
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:DisplayObject:globalToLocal" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">globalToLocal</apiName><shortdesc class="- topic/shortdesc ">
- Converts the point object from the Stage (global) coordinates
- to the display object's (local) coordinates.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A Point object with coordinates relative to the display object.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Point</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">point</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Point</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">An object created with the Point class. The Point object
- specifies the <i class="+ topic/ph hi-d/i ">x</i> and <i class="+ topic/ph hi-d/i ">y</i> coordinates as properties.
-
- </apiDesc></apiParam><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Converts the <codeph class="+ topic/ph pr-d/codeph ">point</codeph> object from Stage (global) coordinates to the display
- object's (local) coordinates.
-
- </apiTipText></apiTipTexts></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Converts the <codeph class="+ topic/ph pr-d/codeph ">point</codeph> object from the Stage (global) coordinates
- to the display object's (local) coordinates.
-
- <p class="- topic/p ">To use this method, first create an instance of the Point class. The
- <i class="+ topic/ph hi-d/i ">x</i> and <i class="+ topic/ph hi-d/i ">y</i> values that you assign represent global coordinates because they
- relate to the origin (0,0) of the main display area. Then pass the Point instance
- as the parameter to the <codeph class="+ topic/ph pr-d/codeph ">globalToLocal()</codeph> method. The method returns a new Point object with
- <i class="+ topic/ph hi-d/i ">x</i> and <i class="+ topic/ph hi-d/i ">y</i> values that relate to the origin of the display object
- instead of the origin of the Stage.</p>
-
- </apiDesc><example conref="examples\DisplayObject.hitTestPoint.1.as" class="- topic/example "> The following code creates a Shape object and shows the
- result of calling the <codeph class="+ topic/ph pr-d/codeph ">hitTestPoint()</codeph> method, using different
- points as parameters. The <codeph class="+ topic/ph pr-d/codeph ">globalToLocal()</codeph> method converts the
- point from Stage coordinates to the coordinate space of the shape:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Shape;
- import flash.geom.Point;
- var circle:Shape = new Shape();
- circle.graphics.beginFill(0x0000FF);
- circle.graphics.drawCircle(40, 40, 40);
- circle.x = 10;
- addChild(circle);
- var point1:Point = new Point(0, 0);
- trace(circle.hitTestPoint(point1.x, point1.y, true)); // false
- trace(circle.hitTestPoint(point1.x, point1.y, false)); // false
- trace(circle.globalToLocal(point1)); // [x=-10, y=0]
- var point2:Point = new Point(10, 1);
- trace(circle.hitTestPoint(point2.x, point2.y, true)); // false
- trace(circle.hitTestPoint(point2.x, point2.y, false)); // true
- trace(circle.globalToLocal(point2)); // [x=0, y=1]
- var point3:Point = new Point(30, 20);
- trace(circle.hitTestPoint(point3.x, point3.y, true)); // true
- trace(circle.hitTestPoint(point3.x, point3.y, false)); // true
- trace(circle.globalToLocal(point3)); // [x=20, y=20]
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject/localToGlobal()" class="- topic/link "><linktext class="- topic/linktext ">localToGlobal()</linktext></link><link href="flash.geom.xml#Point" class="- topic/link "><linktext class="- topic/linktext ">flash.geom.Point class</linktext></link></related-links></apiOperation><apiOperation id="flash.display:DisplayObject:hitTestObject" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">hitTestObject</apiName><shortdesc class="- topic/shortdesc ">
- Evaluates the bounding box of the display object to see if it overlaps or intersects with the
- bounding box of the obj display object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc "><codeph class="+ topic/ph pr-d/codeph ">true</codeph> if the bounding boxes of the display objects intersect; <codeph class="+ topic/ph pr-d/codeph ">false</codeph> if not.
-
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">obj</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The display object to test against.
-
- </apiDesc></apiParam><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Evaluates the bounding box of the display object to see if it overlaps or intersects with the
- bounding box of the display object passed as a parameter.
-
- </apiTipText></apiTipTexts></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Evaluates the bounding box of the display object to see if it overlaps or intersects with the
- bounding box of the <codeph class="+ topic/ph pr-d/codeph ">obj</codeph> display object.
-
- </apiDesc><example conref="examples\DisplayObject.hitTestObject.1.as" class="- topic/example "> The following code creates three Shape objects and shows the
- result of calling the <codeph class="+ topic/ph pr-d/codeph ">hitTestObject()</codeph> method. Note that although
- circle2 and circle3 do not overlap, their bounding boxes do. Thus, the hit test
- of circle2 and circle3 returns <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Shape;
- var circle1:Shape = new Shape();
- circle1.graphics.beginFill(0x0000FF);
- circle1.graphics.drawCircle(40, 40, 40);
- addChild(circle1);
- var circle2:Shape = new Shape();
- circle2.graphics.beginFill(0x00FF00);
- circle2.graphics.drawCircle(40, 40, 40);
- circle2.x = 50;
- addChild(circle2);
- var circle3:Shape = new Shape();
- circle3.graphics.beginFill(0xFF0000);
- circle3.graphics.drawCircle(40, 40, 40);
- circle3.x = 100;
- circle3.y = 67;
- addChild(circle3);
- trace(circle1.hitTestObject(circle2)); // true
- trace(circle1.hitTestObject(circle3)); // false
- trace(circle2.hitTestObject(circle3)); // true
- </codeblock></example></apiOperationDetail></apiOperation><apiOperation id="flash.display:DisplayObject:hitTestPoint" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">hitTestPoint</apiName><shortdesc class="- topic/shortdesc ">
- Evaluates the display object to see if it overlaps or intersects with the
- point specified by the x and y parameters.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc "><codeph class="+ topic/ph pr-d/codeph ">true</codeph> if the display object overlaps or intersects with the specified point;
- <codeph class="+ topic/ph pr-d/codeph ">false</codeph> otherwise.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">x</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Number</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The <i class="+ topic/ph hi-d/i ">x</i> coordinate to test against this object.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">y</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Number</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The <i class="+ topic/ph hi-d/i ">y</i> coordinate to test against this object.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">shapeFlag</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">false</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Whether to check against the actual pixels of the object (<codeph class="+ topic/ph pr-d/codeph ">true</codeph>)
- or the bounding box (<codeph class="+ topic/ph pr-d/codeph ">false</codeph>).
-
- </apiDesc></apiParam><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Evaluates the display object to see if it overlaps or intersects with a point specified
- by x and y.
-
- </apiTipText></apiTipTexts></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Evaluates the display object to see if it overlaps or intersects with the
- point specified by the <codeph class="+ topic/ph pr-d/codeph ">x</codeph> and <codeph class="+ topic/ph pr-d/codeph ">y</codeph> parameters.
- The <codeph class="+ topic/ph pr-d/codeph ">x</codeph> and <codeph class="+ topic/ph pr-d/codeph ">y</codeph> parameters specify a point in the
- coordinate space of the Stage, not the display object container that contains the
- display object (unless that display object container is the Stage).
-
- </apiDesc><example conref="examples\DisplayObject.hitTestPoint.1.as" class="- topic/example "> The following code creates a Shape object and shows the
- result of calling the <codeph class="+ topic/ph pr-d/codeph ">hitTestPoint()</codeph> method, using different
- points as parameters. The <codeph class="+ topic/ph pr-d/codeph ">globalToLocal()</codeph> method converts the
- point from Stage coordinates to the coordinate space of the shape:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Shape;
- import flash.geom.Point;
- var circle:Shape = new Shape();
- circle.graphics.beginFill(0x0000FF);
- circle.graphics.drawCircle(40, 40, 40);
- circle.x = 10;
- addChild(circle);
- var point1:Point = new Point(0, 0);
- trace(circle.hitTestPoint(point1.x, point1.y, true)); // false
- trace(circle.hitTestPoint(point1.x, point1.y, false)); // false
- trace(circle.globalToLocal(point1)); // [x=-10, y=0]
- var point2:Point = new Point(10, 1);
- trace(circle.hitTestPoint(point2.x, point2.y, true)); // false
- trace(circle.hitTestPoint(point2.x, point2.y, false)); // true
- trace(circle.globalToLocal(point2)); // [x=0, y=1]
- var point3:Point = new Point(30, 20);
- trace(circle.hitTestPoint(point3.x, point3.y, true)); // true
- trace(circle.hitTestPoint(point3.x, point3.y, false)); // true
- trace(circle.globalToLocal(point3)); // [x=20, y=20]
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject/opaqueBackground" class="- topic/link "><linktext class="- topic/linktext ">opaqueBackground</linktext></link></related-links></apiOperation><apiOperation id="flash.display:DisplayObject:local3DToGlobal" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">local3DToGlobal</apiName><shortdesc class="- topic/shortdesc ">
- Converts a three-dimensional point of the three-dimensional display
- object's (local) coordinates to a two-dimensional point in the Stage (global) coordinates.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A two-dimensional point representing a three-dimensional point
- in two-dimensional space.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Point</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">point3d</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Vector3D</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A Vector3D object containing either a three-dimensional point or
- the coordinates of the three-dimensional display object.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Converts a three-dimensional point of the three-dimensional display
- object's (local) coordinates to a two-dimensional point in the Stage (global) coordinates.
-
- <p class="- topic/p ">For example, you can only use two-dimensional coordinates (x,y) to
- draw with the <codeph class="+ topic/ph pr-d/codeph ">display.Graphics</codeph> methods. To draw a three-dimensional
- object, you need to map the three-dimensional coordinates of a
- display object to two-dimensional coordinates. First, create an instance of
- the Vector3D class that holds the x-, y-, and z- coordinates of the three-dimensional
- display object. Then pass the Vector3D object to the <codeph class="+ topic/ph pr-d/codeph ">local3DToGlobal()</codeph>
- method as the <codeph class="+ topic/ph pr-d/codeph ">point3d</codeph> parameter. The method returns a two-dimensional Point
- object that can be used
- with the Graphics API to draw the three-dimensional object.</p>
-
-
- </apiDesc><example conref="examples\Local3DToGlobalExample.as" class="- topic/example "> This example draws a simple three-dimensional cube in a two dimensional space
- using <codeph class="+ topic/ph pr-d/codeph ">display.Graphics</codeph> methods. The location of <codeph class="+ topic/ph pr-d/codeph ">this</codeph> display
- object is offset, so the cube's registration point is in its center. A vector
- of Vector3D objects holds the cube's three dimensional coordinates. The top
- of the cube is draw first, the bottom is drawn second, and then the top and bottom
- four corners are connected. You need to add the cube to the display object
- container before drawing the cube in order to use the <codeph class="+ topic/ph pr-d/codeph ">local3DToGlobal()</codeph> method.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- package {
- import flash.display.MovieClip;
- import flash.display.Sprite;
- import flash.display.Graphics;
- import flash.geom.*;
- public class Local3DToGlobalExample extends MovieClip {
- private var myCube:Sprite = new Sprite();
- private var v8:Vector.<Vector3D> = new Vector.<Vector3D>(8);
- public function Local3DToGlobalExample():void {
- this.x = -(this.stage.stageWidth / 2);
- this.y = -(this.stage.stageWidth / 2);
- v8[0] = new Vector3D(-40,-40,-40);
- v8[1] = new Vector3D(40,-40,-40);
- v8[2] = new Vector3D(40,-40,40);
- v8[3] = new Vector3D(-40,-40,40);
- v8[4] = new Vector3D(-40,100,-40);
- v8[5] = new Vector3D(40,100,-40);
- v8[6] = new Vector3D(40,100,40);
- v8[7] = new Vector3D(-40,100,40);
- myCube.x = (this.stage.stageWidth / 2);
- myCube.y = (this.stage.stageWidth / 2);
- myCube.z = 1;
- addChild(myCube);
- Cube();
- }
- private function Cube():void {
- var ps:Point = new Point(0,0);
- myCube.graphics.lineStyle(2,0xFF0000);
- ps = myCube.local3DToGlobal(v8[0]);
- myCube.graphics.moveTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[1]);
- myCube.graphics.lineTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[2]);
- myCube.graphics.lineTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[3]);
- myCube.graphics.lineTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[0]);
- myCube.graphics.lineTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[4]);
- myCube.graphics.moveTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[5]);
- myCube.graphics.lineTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[6]);
- myCube.graphics.lineTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[7]);
- myCube.graphics.lineTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[4]);
- myCube.graphics.lineTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[0]);
- myCube.graphics.moveTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[4]);
- myCube.graphics.lineTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[1]);
- myCube.graphics.moveTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[5]);
- myCube.graphics.lineTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[2]);
- myCube.graphics.moveTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[6]);
- myCube.graphics.lineTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[3]);
- myCube.graphics.moveTo(ps.x, ps.y);
- ps = myCube.local3DToGlobal(v8[7]);
- myCube.graphics.lineTo(ps.x, ps.y);
- }
- }
- }
- </codeblock></example></apiOperationDetail></apiOperation><apiOperation id="flash.display:DisplayObject:localToGlobal" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">localToGlobal</apiName><shortdesc class="- topic/shortdesc ">
- Converts the point object from the display object's (local) coordinates to the
- Stage (global) coordinates.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A Point object with coordinates relative to the Stage.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Point</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">point</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Point</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The name or identifier of a point created with the Point class, specifying the
- <i class="+ topic/ph hi-d/i ">x</i> and <i class="+ topic/ph hi-d/i ">y</i> coordinates as properties.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Converts the <codeph class="+ topic/ph pr-d/codeph ">point</codeph> object from the display object's (local) coordinates to the
- Stage (global) coordinates.
-
- <p class="- topic/p ">This method allows you to convert any given <i class="+ topic/ph hi-d/i ">x</i> and <i class="+ topic/ph hi-d/i ">y</i> coordinates from
- values that are relative to the origin (0,0) of a specific display object (local coordinates)
- to values that are relative to the origin of the Stage (global coordinates).</p>
-
- <p class="- topic/p ">To use this method, first create an instance of the Point class. The
- <i class="+ topic/ph hi-d/i ">x</i> and <i class="+ topic/ph hi-d/i ">y</i> values that you assign represent local coordinates because they
- relate to the origin of the display object.</p>
-
- <p class="- topic/p ">You then pass the Point instance that you created as the parameter to
- the <codeph class="+ topic/ph pr-d/codeph ">localToGlobal()</codeph> method. The method returns a new Point object with
- <i class="+ topic/ph hi-d/i ">x</i> and <i class="+ topic/ph hi-d/i ">y</i> values that relate to the origin of the Stage
- instead of the origin of the display object.</p>
-
- </apiDesc><example conref="examples\DisplayObject.localToGlobal.1.as" class="- topic/example "> The following code creates a Sprite object. The <codeph class="+ topic/ph pr-d/codeph ">mouseX</codeph> and
- <codeph class="+ topic/ph pr-d/codeph ">mouseY</codeph> properties of the sprite are in the coordinate space of the display
- object. This code uses the <codeph class="+ topic/ph pr-d/codeph ">localToGlobal()</codeph> method to translate these
- properties to the global (Stage) coordinates:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- import flash.geom.Point;
- var square:Sprite = new Sprite();
- square.graphics.beginFill(0xFFCC00);
- square.graphics.drawRect(0, 0, 100, 100);
- square.x = 100;
- square.y = 200;
- addChild(square);
- square.addEventListener(MouseEvent.CLICK, traceCoordinates)
- function traceCoordinates(event:MouseEvent):void {
- var clickPoint:Point = new Point(square.mouseX, square.mouseY);
- trace("display object coordinates:", clickPoint);
- trace("stage coordinates:", square.localToGlobal(clickPoint));
- }
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject/globalToLocal()" class="- topic/link "><linktext class="- topic/linktext ">globalToLocal()</linktext></link><link href="flash.geom.xml#Point" class="- topic/link "><linktext class="- topic/linktext ">flash.geom.Point class</linktext></link></related-links></apiOperation><apiValue id="flash.display:DisplayObject:accessibilityProperties:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">accessibilityProperties</apiName><shortdesc class="- topic/shortdesc ">
- The current accessibility options for this display object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.accessibility:AccessibilityProperties</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The current accessibility options for this display object. If you modify the <codeph class="+ topic/ph pr-d/codeph ">accessibilityProperties</codeph>
- property or any of the fields within <codeph class="+ topic/ph pr-d/codeph ">accessibilityProperties</codeph>, you must call
- the <codeph class="+ topic/ph pr-d/codeph ">Accessibility.updateProperties()</codeph> method to make your changes take effect.
-
- <p class="flashonly"><b class="+ topic/ph hi-d/b ">Note</b>: For an object created in the Flash authoring environment, the value of <codeph class="+ topic/ph pr-d/codeph ">accessibilityProperties</codeph>
- is prepopulated with any information you entered in the Accessibility panel for
- that object.</p>
-
- </apiDesc><example conref="examples\DisplayObject.accessibilityProperties.1.as" class="- topic/example "> The following example shows how the to attach a simple AccessibilityProperties
- object to a TextField instance:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.text.TextField;
- import flash.accessibility.AccessibilityProperties;
- import flash.accessibility.Accessibility;
- import flash.system.Capabilities;
- var tf:TextField = new TextField();
- tf.text = "hello";
- var accessProps:AccessibilityProperties = new AccessibilityProperties();
- accessProps.name = "Greeting";
- tf.accessibilityProperties = accessProps;
- if (Capabilities.hasAccessibility) {
- Accessibility.updateProperties();
- }
- trace(tf.accessibilityProperties.name); // Greeting
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.accessibility.xml#Accessibility/updateProperties()" class="- topic/link "><linktext class="- topic/linktext ">flash.accessibility.Accessibility.updateProperties()</linktext></link><link href="flash.accessibility.xml#AccessibilityProperties" class="- topic/link "><linktext class="- topic/linktext ">flash.accessibility.AccessibilityProperties</linktext></link></related-links></apiValue><apiValue id="flash.display:DisplayObject:alpha:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">alpha</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the alpha transparency value of the object specified.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the alpha transparency value of the object specified.
- Valid values are 0 (fully transparent) to 1 (fully opaque).
- The default value is 1. Display objects with <codeph class="+ topic/ph pr-d/codeph ">alpha</codeph>
- set to 0 <i class="+ topic/ph hi-d/i ">are</i> active, even though they are invisible.
-
- </apiDesc><example conref="examples\DisplayObject.alpha.1.as" class="- topic/example "> The following code sets the <codeph class="+ topic/ph pr-d/codeph ">alpha</codeph> property of a sprite
- to 50% when the mouse rolls over the sprite:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var circle:Sprite = new Sprite();
- circle.graphics.beginFill(0xFF0000);
- circle.graphics.drawCircle(40, 40, 40);
- addChild(circle);
- circle.addEventListener(MouseEvent.MOUSE_OVER, dimObject);
- circle.addEventListener(MouseEvent.MOUSE_OUT, restoreObject);
- function dimObject(event:MouseEvent):void {
- event.target.alpha = 0.5;
- }
- function restoreObject(event:MouseEvent):void {
- event.target.alpha = 1.0;
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:blendMode:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">blendMode</apiName><shortdesc class="- topic/shortdesc ">
- A value from the BlendMode class that specifies which blend mode to use.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- A value from the BlendMode class that specifies which blend mode to use.
- A bitmap can be drawn internally in two ways. If you have a blend mode enabled or an
- external clipping mask, the bitmap is drawn by adding a bitmap-filled square shape to the vector
- render. If you attempt to set this property to an invalid value, Flash runtimes set the value
- to <codeph class="+ topic/ph pr-d/codeph ">BlendMode.NORMAL</codeph>.
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property affects each pixel of the display object.
- Each pixel is composed of three constituent
- colors (red, green, and blue), and each constituent color has a value between 0x00 and 0xFF.
- Flash Player or Adobe AIR compares each constituent color of one pixel in the movie clip with
- the corresponding color of the pixel in the background. For example, if <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph>
- is set to <codeph class="+ topic/ph pr-d/codeph ">BlendMode.LIGHTEN</codeph>, Flash Player or Adobe AIR compares the red value of the display object with
- the red value of the background, and uses the lighter of the two as the
- value for the red component of the displayed color.</p>
-
- <p class="- topic/p ">The following table describes the <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> settings.
- The BlendMode class defines string values you can use.
- The illustrations in the table show <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> values applied to a circular
- display object (2) superimposed on another display object (1).</p>
-
-
- <p class="- topic/p ">
- <adobeimage alt="Square Number 1" href="../../images/blendMode-0a.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/>
-
- <adobeimage alt="Circle Number 2" href="../../images/blendMode-0b.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/>
-
- </p>
-
-
- <adobetable class="innertable"><tgroup cols="3" class="- topic/tgroup "><thead class="- topic/thead "><row class="- topic/row "><entry class="- topic/entry ">BlendMode Constant</entry><entry class="- topic/entry ">Illustration</entry><entry class="- topic/entry ">Description</entry></row></thead><tbody class="- topic/tbody "><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.NORMAL</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode NORMAL" href="../../images/blendMode-1.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">The display object appears in front of the background. Pixel values of the display object
- override those of the background. Where the display object is transparent, the background is
- visible.</entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.LAYER</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode LAYER" href="../../images/blendMode-2.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">Forces the creation of a transparency group for the display object. This means that the display
- object is pre-composed in a temporary buffer before it is processed further. This is done
- automatically if the display object is pre-cached using bitmap caching or if the display object is
- a display object container with at least one child object with a <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph>
- setting other than <codeph class="+ topic/ph pr-d/codeph ">BlendMode.NORMAL</codeph>. Not supported under GPU rendering.
- </entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.MULTIPLY</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode MULTIPLY" href="../../images/blendMode-3.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">Multiplies the values of the display object constituent colors by the colors of the background color,
- and then normalizes by dividing by 0xFF,
- resulting in darker colors. This setting is commonly used for shadows and depth effects.
-
- <p class="- topic/p ">For example, if a constituent color (such as red) of one pixel in the display object and the
- corresponding color of the pixel in the background both have the value 0x88, the multiplied
- result is 0x4840. Dividing by 0xFF yields a value of 0x48 for that constituent color,
- which is a darker shade than the color of the display object or the color of the background.</p></entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.SCREEN</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode SCREEN" href="../../images/blendMode-4.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">Multiplies the complement (inverse) of the display object color by the complement of the background
- color, resulting in a bleaching effect. This setting is commonly used for highlights or to remove black
- areas of the display object.</entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.LIGHTEN</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode LIGHTEN" href="../../images/blendMode-5.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">Selects the lighter of the constituent colors of the display object and the color of the background (the
- colors with the larger values). This setting is commonly used for superimposing type.
-
- <p class="- topic/p ">For example, if the display object has a pixel with an RGB value of 0xFFCC33, and the background
- pixel has an RGB value of 0xDDF800, the resulting RGB value for the displayed pixel is
- 0xFFF833 (because 0xFF > 0xDD, 0xCC < 0xF8, and 0x33 > 0x00 = 33). Not supported under GPU rendering.</p></entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.DARKEN</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode DARKEN" href="../../images/blendMode-6.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">Selects the darker of the constituent colors of the display object and the colors of the
- background (the colors with the smaller values). This setting is commonly used for superimposing type.
-
- <p class="- topic/p ">For example, if the display object has a pixel with an RGB value of 0xFFCC33, and the background
- pixel has an RGB value of 0xDDF800, the resulting RGB value for the displayed pixel is
- 0xDDCC00 (because 0xFF > 0xDD, 0xCC < 0xF8, and 0x33 > 0x00 = 33). Not supported under GPU rendering.</p></entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.DIFFERENCE</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode DIFFERENCE" href="../../images/blendMode-7.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">Compares the constituent colors of the display object with the colors of its background, and subtracts
- the darker of the values of the two constituent colors from the lighter value. This setting is commonly
- used for more vibrant colors.
-
- <p class="- topic/p ">For example, if the display object has a pixel with an RGB value of 0xFFCC33, and the background
- pixel has an RGB value of 0xDDF800, the resulting RGB value for the displayed pixel is
- 0x222C33 (because 0xFF - 0xDD = 0x22, 0xF8 - 0xCC = 0x2C, and 0x33 - 0x00 = 0x33).</p></entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.ADD</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode ADD" href="../../images/blendMode-8.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">Adds the values of the constituent colors of the display object to the colors of its background, applying a
- ceiling of 0xFF. This setting is commonly used for animating a lightening dissolve between
- two objects.
-
- <p class="- topic/p ">For example, if the display object has a pixel with an RGB value of 0xAAA633, and the background
- pixel has an RGB value of 0xDD2200, the resulting RGB value for the displayed pixel is
- 0xFFC833 (because 0xAA + 0xDD > 0xFF, 0xA6 + 0x22 = 0xC8, and 0x33 + 0x00 = 0x33).</p></entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.SUBTRACT</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode SUBTRACT" href="../../images/blendMode-9.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">Subtracts the values of the constituent colors in the display object from the values of the
- background color, applying a floor of 0. This setting is commonly used for animating a
- darkening dissolve between two objects.
-
- <p class="- topic/p ">For example, if the display object has a pixel with an RGB value of 0xAA2233, and the background
- pixel has an RGB value of 0xDDA600, the resulting RGB value for the displayed pixel is
- 0x338400 (because 0xDD - 0xAA = 0x33, 0xA6 - 0x22 = 0x84, and 0x00 - 0x33 < 0x00).</p></entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.INVERT</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode INVERT" href="../../images/blendMode-10.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">Inverts the background.</entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.ALPHA</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode ALPHA" href="../../images/blendMode-11.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">Applies the alpha value of each pixel of the display object to the background.
- This requires the <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> setting of the parent display object to be set to
- <codeph class="+ topic/ph pr-d/codeph ">BlendMode.LAYER</codeph>.
- For example, in the illustration, the parent display object, which is a white background,
- has <codeph class="+ topic/ph pr-d/codeph ">blendMode = BlendMode.LAYER</codeph>. Not supported under GPU rendering.</entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.ERASE</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode ERASE" href="../../images/blendMode-12.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">Erases the background based on the alpha value of the display object. This requires the
- <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> of the parent display object to be set to
- <codeph class="+ topic/ph pr-d/codeph ">BlendMode.LAYER</codeph>. For example, in the
- illustration, the parent display object, which is a white background, has
- <codeph class="+ topic/ph pr-d/codeph ">blendMode = BlendMode.LAYER</codeph>. Not supported under GPU rendering.</entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.OVERLAY</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode OVERLAY" href="../../images/blendMode-13.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">Adjusts the color of each pixel based on the darkness of the background.
- If the background is lighter than 50% gray, the display object and background colors are
- screened, which results in a lighter color. If the background is darker than 50% gray,
- the colors are multiplied, which results in a darker color.
- This setting is commonly used for shading effects. Not supported under GPU rendering.</entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.HARDLIGHT</codeph></entry><entry class="- topic/entry "><adobeimage alt="blend mode HARDLIGHT" href="../../images/blendMode-14.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry><entry class="- topic/entry ">Adjusts the color of each pixel based on the darkness of the display object.
- If the display object is lighter than 50% gray, the display object and background colors are
- screened, which results in a lighter color. If the display object is darker than 50% gray,
- the colors are multiplied, which results in a darker color.
- This setting is commonly used for shading effects. Not supported under GPU rendering.</entry></row><row valign="top" class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">BlendMode.SHADER</codeph></entry><entry align="center" valign="middle" class="- topic/entry ">N/A</entry><entry class="- topic/entry ">Adjusts the color using a custom shader routine. The shader that is used is specified
- as the Shader instance assigned to the <codeph class="+ topic/ph pr-d/codeph ">blendShader</codeph> property. Setting the
- <codeph class="+ topic/ph pr-d/codeph ">blendShader</codeph> property of a display object to a Shader instance
- automatically sets the display object's <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property to
- <codeph class="+ topic/ph pr-d/codeph ">BlendMode.SHADER</codeph>. If the <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property is set to
- <codeph class="+ topic/ph pr-d/codeph ">BlendMode.SHADER</codeph> without first setting the <codeph class="+ topic/ph pr-d/codeph ">blendShader</codeph> property,
- the <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property is set to <codeph class="+ topic/ph pr-d/codeph ">BlendMode.NORMAL</codeph>. Not supported under GPU rendering.</entry></row></tbody></tgroup></adobetable>
-
- </apiDesc><example conref="examples\DisplayObject.blendMode.1.as" class="- topic/example "> The following code creates two sprite objects, a square and a circle,
- and sets the blend mode of the circle (in the foreground) to <codeph class="+ topic/ph pr-d/codeph ">BlendMode.SUBTRACT</codeph>
- when the pointer rolls over the circle:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.display.BlendMode;
- import flash.events.MouseEvent;
- var square:Sprite = new Sprite();
- square.graphics.beginFill(0xFF88CC);
- square.graphics.drawRect(0, 0, 80, 80);
- addChild(square);
- var circle:Sprite = new Sprite();
- circle.graphics.beginFill(0xAA0022);
- circle.graphics.drawCircle(40, 40, 40);
- addChild(circle);
- circle.addEventListener(MouseEvent.MOUSE_OVER, dimObject);
- circle.addEventListener(MouseEvent.MOUSE_OUT, restoreObject);
- function dimObject(event:MouseEvent):void {
- event.target.blendMode = BlendMode.SUBTRACT;
- }
- function restoreObject(event:MouseEvent):void {
- event.target.blendMode = BlendMode.NORMAL;
- }
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#BlendMode" class="- topic/link "><linktext class="- topic/linktext ">flash.display.BlendMode</linktext></link><link href="flash.display.xml#DisplayObject/blendShader" class="- topic/link "><linktext class="- topic/linktext ">blendShader</linktext></link></related-links></apiValue><apiValue id="flash.display:DisplayObject:cacheAsBitmapMatrix:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">cacheAsBitmapMatrix</apiName><shortdesc class="- topic/shortdesc ">
- If non-null, this Matrix object defines how a display object is rendered when
- cacheAsBitmap is set to true.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="2.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.geom:Matrix</apiValueClassifier><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">The transformation matrix used when rendering a cached version of
- this display object's bitmap.
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- If non-null, this Matrix object defines how a display object is rendered when
- <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmap</codeph> is set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>. The application uses
- this matrix as a transformation matrix that is applied when rendering the bitmap version of
- the display object.
-
- <p class="- topic/p "><i class="+ topic/ph hi-d/i ">AIR profile support:</i> This feature is supported
- on mobile devices, but it is not supported on desktop operating systems. It also has
- limited support on AIR for TV devices.
- Specifically, on AIR for TV devices, supported transformations include scaling and translation,
- but not rotation and skewing. See
- <xref href="http://help.adobe.com/en_US/air/build/WS144092a96ffef7cc16ddeea2126bb46b82f-8000.html" class="- topic/xref ">
- AIR Profile Support</xref> for more information regarding API support across multiple profiles.</p>
-
- <p class="- topic/p ">With <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmapMatrix</codeph> set, the application retains a cached
- bitmap image across various 2D transformations, including translation, rotation,
- and scaling. If the application uses hardware acceleration, the object will
- be stored in video memory as a texture. This allows the GPU to apply
- the supported transformations to the object. The GPU
- can perform these transformations faster than the CPU.</p>
-
-
- <p class="- topic/p ">To use the hardware acceleration, set Rendering to GPU in
- the General tab of the iPhone Settings dialog box in Flash Professional CS5.
- Or set the <codeph class="+ topic/ph pr-d/codeph ">renderMode</codeph> property to <codeph class="+ topic/ph pr-d/codeph ">gpu</codeph> in the
- application descriptor file. Note that AIR for TV devices automatically
- use hardware acceleration if it is available.</p>
-
- <p class="- topic/p ">For example, the following code sends an untransformed bitmap representation
- of the display object to the GPU:</p>
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">matrix:Matrix = new Matrix(); // creates an identity matrix
- mySprite.cacheAsBitmapMatrix = matrix;
- mySprite.cacheAsBitmap = true;</codeblock>
-
- <p class="- topic/p ">Usually, the identity matrix (<codeph class="+ topic/ph pr-d/codeph ">new Matrix()</codeph>) suffices. However,
- you can use another matrix, such as a scaled-down matrix, to upload
- a different bitmap to the GPU. For example, the following example applies
- a <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmapMatrix</codeph> matrix that is scaled by 0.5 on the x and y axes.
- The bitmap object that the GPU uses is smaller, however the GPU adjusts
- its size to match the transform.matrix property of the display object:</p>
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">matrix:Matrix = new Matrix(); // creates an identity matrix
- matrix.scale(0.5, 0.5); // scales the matrix
- mySprite.cacheAsBitmapMatrix = matrix;
- mySprite.cacheAsBitmap = true;</codeblock>
-
- <p class="- topic/p ">Generally, you should choose to use a matrix that transforms the display object
- to the size that it will appear in the application. For example, if
- your application displays the bitmap version of the sprite scaled down by a half,
- use a matrix that scales down by a half. If you application will display
- the sprite larger than its current dimensions, use a matrix that
- scales up by that factor.</p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> The <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmapMatrix</codeph> property
- is suitable for 2D transformations. If you need to apply transformations in 3D,
- you may do so by setting a 3D property of the object and manipulating its
- <codeph class="+ topic/ph pr-d/codeph ">transform.matrix3D</codeph> property. If the application is packaged
- using GPU mode, this allows the 3D transforms to be applied to
- the object by the GPU. The <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmapMatrix</codeph> is ignored
- for 3D objects.</p>
-
- </apiDesc><example conref="examples\DisplayObject.cacheAsBitmapMatrix.as" class="- topic/example "> The following example applies uses the <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmapMatrix</codeph> property to apply transformations
- to a bitmap version of the movie clip <codeph class="+ topic/ph pr-d/codeph ">my_shape</codeph>.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.geom.Matrix;
- import flash.display.*;
- import flash.utils.Timer;
- var my_shape:MovieClip = new MovieClip();
- my_shape.graphics.beginFill(0xCCFF00);
- my_shape.graphics.drawRect(200, 0, 100, 100);
- addChild(my_shape);
- var my_timer:Timer = new Timer(250);
- my_timer.start();
- my_timer.addEventListener(TimerEvent.TIMER, timerHandler);
- // make sure this Display Object remains cached for all 2D transforms
- my_shape.cacheAsBitmap = true;
- my_shape.cacheAsBitmapMatrix = new Matrix();
- // rotation variables
- const initAngle:Number = 0;
- const pi:Number = 3.142;
- const incrAngle:Number = pi/10;
- // scaling variables
- const initScale:Number = 0.25;
- const incrScale: Number = 1.1;
- var initHeight : Number = my_shape.height;
- var initWidth : Number = my_shape.width;
- // translation variables
- var incrX : Number = root.width / 20;
- var incrY : Number = root.height / 10;
- // do some initial transforms
- var tempMat : Matrix = my_shape.transform.matrix;
- tempMat.rotate(initAngle);
- tempMat.scale(initScale, initScale);
- my_shape.transform.matrix = tempMat;
- function timerHandler(evt:TimerEvent):void {
- tempMat = my_shape.transform.matrix;
-
- tempMat.rotate(incrAngle);
- tempMat.translate(incrX, incrY);
- tempMat.scale(incrScale, incrScale);
-
- my_shape.transform.matrix = tempMat;
-
- // ensure we are still in a reasonable state or reset
- if(my_shape.height > stage.stageHeight/2)
- {
- my_shape.height = initHeight;
- }
-
- if(my_shape.width > stage.stageWidth/2)
- {
- my_shape.width = initWidth;
- }
-
- if(my_shape.x > stage.stageWidth)
- {
- my_shape.x = 0;
- }
- else if (my_shape.x < 0)
- {
- my_shape.x = stage.stageWidth;
- }
-
- if(my_shape.y > stage.stageHeight)
- {
- my_shape.y = 0;
- }
- else if (my_shape.y < 0)
- {
- my_shape.y = stage.stageHeight;
- }
-
- }
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject/cacheAsBitmap" class="- topic/link "><linktext class="- topic/linktext ">cacheAsBitmap</linktext></link><link href="flash.geom.xml#Matrix3D" class="- topic/link "><linktext class="- topic/linktext ">flash.geom.Matrix3D</linktext></link></related-links></apiValue><apiValue id="flash.display:DisplayObject:cacheAsBitmap:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">cacheAsBitmap</apiName><shortdesc class="- topic/shortdesc ">
- If set to true, Flash runtimes cache an internal bitmap representation of the
- display object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Whether to cache this DisplayObject as a bitmap.
-
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- If set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, Flash runtimes cache an internal bitmap representation of the
- display object. This caching can increase performance for display objects that contain complex
- vector content.
-
- <p class="- topic/p ">All vector data for a display object that has a cached bitmap is drawn to the bitmap
- instead of the main display. If <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmapMatrix</codeph> is null or unsupported,
- the bitmap is then copied to the main display as unstretched, unrotated pixels snapped to
- the nearest pixel boundaries. Pixels are mapped 1 to 1 with
- the parent object. If the bounds of the bitmap change, the bitmap is recreated instead
- of being stretched.</p>
-
- <p class="- topic/p ">If <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmapMatrix</codeph> is non-null and supported, the object is drawn to the off-screen bitmap
- using that matrix and the stretched and/or rotated results of that rendering are used
- to draw the object to the main display.</p>
-
- <p class="- topic/p ">No internal bitmap is created unless the <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmap</codeph> property is set to
- <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.</p>
-
- <p class="- topic/p ">After you set the <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmap</codeph> property to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>,
- the rendering does not change, however the display object performs pixel snapping
- automatically. The animation speed can be significantly faster depending
- on the complexity of the vector content.
- </p>
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmap</codeph> property is automatically set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>
- whenever you apply a filter to a display object (when its <codeph class="+ topic/ph pr-d/codeph ">filter</codeph> array is not empty),
- and if a display object has a filter applied to it, <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmap</codeph> is reported as
- <codeph class="+ topic/ph pr-d/codeph ">true</codeph> for that display object, even if you set the property to <codeph class="+ topic/ph pr-d/codeph ">false</codeph>.
- If you clear all filters for a display object, the <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmap</codeph> setting changes to
- what it was last set to.</p>
-
- <p class="- topic/p ">A display object does not use a bitmap even if the <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmap</codeph>
- property is set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph> and instead renders from vector data in the following cases:</p>
-
- <ul class="- topic/ul "><li class="- topic/li ">The bitmap is too large.
- In AIR 1.5 and Flash Player 10, the maximum size for a bitmap image is 8,191 pixels in width or height,
- and the total number of pixels cannot exceed 16,777,215 pixels. (So, if a bitmap image is 8,191 pixels
- wide, it can only be 2,048 pixels high.) In Flash Player 9 and earlier, the limitation is
- is 2880 pixels in height and 2,880 pixels in width.</li><li class="- topic/li ">The bitmap fails to allocate (out of memory error). </li></ul>
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmap</codeph> property is best used with movie clips that have
- mostly static content and that do not scale and rotate frequently. With such movie
- clips, <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmap</codeph> can lead to performance increases when the
- movie clip is translated (when its <i class="+ topic/ph hi-d/i ">x</i> and <i class="+ topic/ph hi-d/i ">y</i> position is changed).</p>
-
- </apiDesc><example conref="examples\DisplayObject.cacheAsBitmap.1.as" class="- topic/example "> The following example applies a drop shadow to a Shape instance.
- It then traces the value of the <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmap</codeph> property, which is set to
- <codeph class="+ topic/ph pr-d/codeph ">true</codeph> when the filter is applied:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.filters.DropShadowFilter
- var circle:Sprite = new Sprite();
- circle.graphics.beginFill(0xAA0022);
- circle.graphics.drawCircle(40, 40, 40);
- addChild(circle);
- trace(circle.cacheAsBitmap); // false
- var filter:DropShadowFilter = new DropShadowFilter();
- circle.filters = [filter];
- trace(circle.cacheAsBitmap); // true
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject/cacheAsBitmapMatrix" class="- topic/link "><linktext class="- topic/linktext ">cacheAsBitmapMatrix</linktext></link><link href="flash.display.xml#DisplayObject/opaqueBackground" class="- topic/link "><linktext class="- topic/linktext ">opaqueBackground</linktext></link></related-links></apiValue><apiValue id="flash.display:DisplayObject:filters:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">filters</apiName><shortdesc class="- topic/shortdesc ">
- An indexed array that contains each filter object currently associated with the display object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Array</apiValueClassifier><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">When <codeph class="+ topic/ph pr-d/codeph ">filters</codeph> includes a ShaderFilter and the shader
- output type is not compatible with this operation
- (the shader must specify a <codeph class="+ topic/ph pr-d/codeph ">pixel4</codeph>
- output).
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">When <codeph class="+ topic/ph pr-d/codeph ">filters</codeph> includes a ShaderFilter and the shader
- doesn't specify any image input or the first
- input is not an <codeph class="+ topic/ph pr-d/codeph ">image4</codeph> input.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">When <codeph class="+ topic/ph pr-d/codeph ">filters</codeph> includes a ShaderFilter and the shader
- specifies an image input that isn't provided.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">When <codeph class="+ topic/ph pr-d/codeph ">filters</codeph> includes a ShaderFilter, a
- ByteArray or Vector.<Number> instance as
- a shader input, and the <codeph class="+ topic/ph pr-d/codeph ">width</codeph>
- and <codeph class="+ topic/ph pr-d/codeph ">height</codeph> properties aren't specified for the
- ShaderInput object, or the specified values don't match the amount of
- data in the input data. See the <codeph class="+ topic/ph pr-d/codeph ">ShaderInput.input</codeph>
- property for more information.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- An indexed array that contains each filter object currently associated with the display object.
- The flash.filters package contains several classes that define specific filters you can
- use.
-
- <p class="- topic/p ">Filters can be applied in Flash Professional at design time, or at run time by using
- ActionScript code. To apply a filter by using ActionScript, you must make a temporary copy of the
- entire <codeph class="+ topic/ph pr-d/codeph ">filters</codeph> array, modify the temporary array, then assign the value
- of the temporary array back to the <codeph class="+ topic/ph pr-d/codeph ">filters</codeph> array. You cannot directly
- add a new filter object to the <codeph class="+ topic/ph pr-d/codeph ">filters</codeph> array.</p>
-
- <p class="- topic/p ">To add a filter by using ActionScript, perform the following steps (assume that the
- target display object is named <codeph class="+ topic/ph pr-d/codeph ">myDisplayObject</codeph>):</p>
-
- <ol class="- topic/ol "><li class="- topic/li ">Create a new filter object by using the constructor method of your chosen filter
- class.</li><li class="- topic/li ">Assign the value of the <codeph class="+ topic/ph pr-d/codeph ">myDisplayObject.filters</codeph> array to a temporary array, such
- as one named <codeph class="+ topic/ph pr-d/codeph ">myFilters</codeph>.</li><li class="- topic/li ">Add the new filter object to the <codeph class="+ topic/ph pr-d/codeph ">myFilters</codeph> temporary array.</li><li class="- topic/li ">Assign the value of the temporary array to the <codeph class="+ topic/ph pr-d/codeph ">myDisplayObject.filters</codeph> array.</li></ol>
-
- <p class="- topic/p ">If the <codeph class="+ topic/ph pr-d/codeph ">filters</codeph> array is undefined, you do not need to use a temporary array.
- Instead, you can directly assign an array literal that contains one or more filter objects that
- you create. The first example in the Examples section adds a drop shadow filter by using
- code that handles both defined and undefined <codeph class="+ topic/ph pr-d/codeph ">filters</codeph> arrays.</p>
-
- <p class="- topic/p ">To modify an existing filter object,
- you must use the technique of modifying a copy of the <codeph class="+ topic/ph pr-d/codeph ">filters</codeph> array:</p>
-
- <ol class="- topic/ol "><li class="- topic/li ">Assign the value of the <codeph class="+ topic/ph pr-d/codeph ">filters</codeph> array to a temporary array, such as one
- named <codeph class="+ topic/ph pr-d/codeph ">myFilters</codeph>.</li><li class="- topic/li ">Modify the property by using the temporary array, <codeph class="+ topic/ph pr-d/codeph ">myFilters</codeph>. For example,
- to set the quality property of the first filter in the array, you could use the
- following code: <codeph class="+ topic/ph pr-d/codeph ">myFilters[0].quality = 1;</codeph></li><li class="- topic/li ">Assign the value of the temporary array to the <codeph class="+ topic/ph pr-d/codeph ">filters</codeph> array.</li></ol>
-
- <p class="- topic/p ">At load time, if a display object has an associated filter, it is marked to cache itself as a
- transparent bitmap. From this point forward, as long as the display object has a valid filter list,
- the player caches the display object as a bitmap. This source bitmap is used as a source
- image for the filter effects. Each display object usually has two bitmaps: one with the
- original unfiltered source display object and another for the final image after filtering.
- The final image is used when rendering. As long as the display object does not
- change, the final image does not need updating.</p>
-
- <p class="- topic/p ">The flash.filters package includes classes for filters. For example, to create a DropShadow
- filter, you would write:</p>
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.filters.DropShadowFilter
- var myFilter:DropShadowFilter = new DropShadowFilter (distance, angle, color, alpha, blurX, blurY, quality, inner, knockout)
- </codeblock>
-
- <p class="- topic/p ">You can use the <codeph class="+ topic/ph pr-d/codeph ">is</codeph> operator to determine the type of filter assigned to
- each index position in the <codeph class="+ topic/ph pr-d/codeph ">filter</codeph> array. For example, the following code shows
- how to determine the position of the first filter in the <codeph class="+ topic/ph pr-d/codeph ">filters</codeph> array that
- is a DropShadowFilter:
- </p>
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.text.TextField;
- import flash.filters.~~;
- var tf:TextField = new TextField();
- var filter1:DropShadowFilter = new DropShadowFilter();
- var filter2:GradientGlowFilter = new GradientGlowFilter();
- tf.filters = [filter1, filter2];
-
- tf.text = "DropShadow index: " + filterPosition(tf, DropShadowFilter).toString(); // 0
- addChild(tf)
-
- function filterPosition(displayObject:DisplayObject, filterClass:Class):int {
- for (var i:uint = 0; i < displayObject.filters.length; i++) {
- if (displayObject.filters[i] is filterClass) {
- return i;
- }
- }
- return -1;
- }
- </codeblock>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> Since you cannot directly add a new filter object to the
- <codeph class="+ topic/ph pr-d/codeph ">DisplayObject.filters</codeph> array, the following code has no
- effect on the target display object, named <codeph class="+ topic/ph pr-d/codeph ">myDisplayObject</codeph>:</p>
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- myDisplayObject.filters.push(myDropShadow);
- </codeblock>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="../../flash/filters/package-detail.html" class="- topic/link "><linktext class="- topic/linktext ">flash.filters package</linktext></link><link href="flash.display.xml#ShaderInput/input" class="- topic/link "><linktext class="- topic/linktext ">flash.display.ShaderInput.input</linktext></link></related-links></apiValue><apiValue id="flash.display:DisplayObject:height:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">height</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the height of the display object, in pixels.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the height of the display object, in pixels. The height is calculated based on the bounds of the content of the display object.
- When you set the <codeph class="+ topic/ph pr-d/codeph ">height</codeph> property, the <codeph class="+ topic/ph pr-d/codeph ">scaleY</codeph> property is adjusted accordingly, as shown in the
- following code:
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- var rect:Shape = new Shape();
- rect.graphics.beginFill(0xFF0000);
- rect.graphics.drawRect(0, 0, 100, 100);
- trace(rect.scaleY) // 1;
- rect.height = 200;
- trace(rect.scaleY) // 2;</codeblock>
-
- <p class="- topic/p ">Except for TextField and Video objects, a display object with no content (such as an empty sprite) has a height
- of 0, even if you try to set <codeph class="+ topic/ph pr-d/codeph ">height</codeph> to a different value.</p>
-
- </apiDesc><example conref="examples\DisplayObject.height.1.as" class="- topic/example "> The following code creates two TextField objects and adjusts the
- <codeph class="+ topic/ph pr-d/codeph ">height</codeph> property of each based on the <codeph class="+ topic/ph pr-d/codeph ">textHeight</codeph> property of
- each; it also positions the second text field by setting its <codeph class="+ topic/ph pr-d/codeph ">y</codeph> property:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.text.TextField;
- var tf1:TextField = new TextField();
- tf1.text = "Text Field 1";
- tf1.border = true;
- tf1.wordWrap = true;
- tf1.width = 40;
- tf1.height = tf1.textHeight + 5;
- addChild(tf1);
- var tf2:TextField = new TextField();
- tf2.text = "Text Field 2";
- tf2.border = true;
- tf2.wordWrap = true;
- tf2.width = 40;
- tf2.height = tf2.textHeight + 5;
- tf2.y = tf1.y + tf1.height + 5;
- addChild(tf2);
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:loaderInfo:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">loaderInfo</apiName><shortdesc class="- topic/shortdesc ">
- Returns a LoaderInfo object containing information about loading the file
- to which this display object belongs.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:LoaderInfo</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Returns a LoaderInfo object containing information about loading the file
- to which this display object belongs. The <codeph class="+ topic/ph pr-d/codeph ">loaderInfo</codeph> property is defined only
- for the root display object of a SWF file or for a loaded Bitmap (not for a Bitmap that is drawn
- with ActionScript). To find the <codeph class="+ topic/ph pr-d/codeph ">loaderInfo</codeph> object associated with the SWF file that contains
- a display object named <codeph class="+ topic/ph pr-d/codeph ">myDisplayObject</codeph>, use <codeph class="+ topic/ph pr-d/codeph ">myDisplayObject.root.loaderInfo</codeph>.
-
- <p class="- topic/p ">A large SWF file can monitor its download by calling
- <codeph class="+ topic/ph pr-d/codeph ">this.root.loaderInfo.addEventListener(Event.COMPLETE, func)</codeph>.</p>
-
- </apiDesc><example conref="examples\DisplayObject.loaderInfo.1.as" class="- topic/example "> The following code assumes that <codeph class="+ topic/ph pr-d/codeph ">this</codeph> refers to
- a display object. The code outputs the URL of the root SWF file for the
- display object:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- trace (this.loaderInfo.url);
-
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#LoaderInfo" class="- topic/link "><linktext class="- topic/linktext ">LoaderInfo class</linktext></link></related-links></apiValue><apiValue id="flash.display:DisplayObject:mask:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">mask</apiName><shortdesc class="- topic/shortdesc ">
- The calling display object is masked by the specified mask object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:DisplayObject</apiValueClassifier><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Sets a mask for the display object.
-
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The calling display object is masked by the specified <codeph class="+ topic/ph pr-d/codeph ">mask</codeph> object.
- To ensure that masking works when the Stage is scaled, the <codeph class="+ topic/ph pr-d/codeph ">mask</codeph> display object
- must be in an active part of the display list. The <codeph class="+ topic/ph pr-d/codeph ">mask</codeph> object itself is not drawn.
- Set <codeph class="+ topic/ph pr-d/codeph ">mask</codeph> to <codeph class="+ topic/ph pr-d/codeph ">null</codeph> to remove the mask.
-
- <p class="- topic/p ">To be able to scale a mask object, it must be on the display list. To be able to drag a mask Sprite object
- (by calling its <codeph class="+ topic/ph pr-d/codeph ">startDrag()</codeph> method), it must be on the display list. To call the
- <codeph class="+ topic/ph pr-d/codeph ">startDrag()</codeph> method for a mask sprite based on a <codeph class="+ topic/ph pr-d/codeph ">mouseDown</codeph> event
- being dispatched by the sprite, set the sprite's <codeph class="+ topic/ph pr-d/codeph ">buttonMode</codeph> property to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.</p>
-
- <p class="- topic/p ">When display objects are cached by setting the <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmap</codeph> property to
- <codeph class="+ topic/ph pr-d/codeph ">true</codeph> an the <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmapMatrix</codeph> property to a Matrix object,
- both the mask and the display object being masked must be part of the same cached
- bitmap. Thus, if the display object is cached, then the mask must be a child of the display object.
- If an ancestor of the display object on the display list is cached, then the mask must be a child of
- that ancestor or one of its descendents. If more than one ancestor of the masked object is cached,
- then the mask must be a descendent of the cached container closest to the masked object in the display list.</p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> A single <codeph class="+ topic/ph pr-d/codeph ">mask</codeph> object cannot be used to mask more than one calling display object.
- When the <codeph class="+ topic/ph pr-d/codeph ">mask</codeph> is assigned to a second display object, it is removed as the mask of the first
- object, and that object's <codeph class="+ topic/ph pr-d/codeph ">mask</codeph> property becomes <codeph class="+ topic/ph pr-d/codeph ">null</codeph>.</p>
-
- </apiDesc><example conref="examples\DisplayObject.mask.1.as" class="- topic/example "> The following code creates a TextField object as well as a Sprite object
- that is set as a mask for the TextField object. When the user clicks the text
- field, the <codeph class="+ topic/ph pr-d/codeph ">drag()</codeph> event listener function calls the <codeph class="+ topic/ph pr-d/codeph ">startDrag()</codeph>
- method of the mask Sprite object:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.text.TextField;
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var tf:TextField = new TextField();
- tf.text = "Lorem ipsum dolor sit amet, consectetur adipisicing elit, "
- + "sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. "
- tf.selectable = false;
- tf.wordWrap = true;
- tf.width = 150;
- addChild(tf);
- var square:Sprite = new Sprite();
- square.graphics.beginFill(0xFF0000);
- square.graphics.drawRect(0, 0, 40, 40);
- addChild(square);
- tf.mask = square;
- tf.addEventListener(MouseEvent.MOUSE_DOWN, drag);
- tf.addEventListener(MouseEvent.MOUSE_UP, noDrag);
- function drag(event:MouseEvent):void {
- square.startDrag();
- }
- function noDrag(event:MouseEvent):void {
- square.stopDrag();
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:mouseX:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">mouseX</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the x coordinate of the mouse or user input device position, in pixels.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the x coordinate of the mouse or user input device position, in pixels.
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note</b>: For a DisplayObject that has been rotated, the returned x coordinate will reflect the
- non-rotated object.</p>
-
- </apiDesc><example conref="examples\DisplayObject.mouseX.1.as" class="- topic/example "> The following code creates a Sprite object and traces the <codeph class="+ topic/ph pr-d/codeph ">mouseX</codeph>
- and <codeph class="+ topic/ph pr-d/codeph ">mouseY</codeph> positions when the user clicks the sprite:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var square:Sprite = new Sprite();
- square.graphics.beginFill(0xFF0000);
- square.graphics.drawRect(0, 0, 200, 200);
- addChild(square);
- square.addEventListener(MouseEvent.CLICK, traceCoordinates);
- function traceCoordinates(event:MouseEvent):void {
- trace(square.mouseX, square.mouseY);
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:mouseY:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">mouseY</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the y coordinate of the mouse or user input device position, in pixels.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the y coordinate of the mouse or user input device position, in pixels.
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note</b>: For a DisplayObject that has been rotated, the returned y coordinate will reflect the
- non-rotated object.</p>
-
- </apiDesc><example conref="examples\DisplayObject.mouseX.1.as" class="- topic/example "> The following code creates a Sprite object and traces the <codeph class="+ topic/ph pr-d/codeph ">mouseX</codeph>
- and <codeph class="+ topic/ph pr-d/codeph ">mouseY</codeph> positions when the user clicks the sprite:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var square:Sprite = new Sprite();
- square.graphics.beginFill(0xFF0000);
- square.graphics.drawRect(0, 0, 200, 200);
- addChild(square);
- square.addEventListener(MouseEvent.CLICK, traceCoordinates);
- function traceCoordinates(event:MouseEvent):void {
- trace(square.mouseX, square.mouseY);
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:name:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">name</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the instance name of the DisplayObject.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If you are attempting to set this property on an object that was
- placed on the timeline in the Flash authoring tool.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">IllegalOperationError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.errors:IllegalOperationError</apiOperationClassifier></apiException><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">The name of this DisplayObject.
-
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the instance name of the DisplayObject. The object can be identified in
- the child list of its parent display object container by calling the
- <codeph class="+ topic/ph pr-d/codeph ">getChildByName()</codeph> method of the display object container.
-
- </apiDesc><example conref="examples\DisplayObject.name.1.as" class="- topic/example "> The following code creates two Sprite object and traces the
- associated <codeph class="+ topic/ph pr-d/codeph ">name</codeph> property when the user clicks either of the objects:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var circle1:Sprite = new Sprite();
- circle1.graphics.beginFill(0xFF0000);
- circle1.graphics.drawCircle(40, 40, 40);
- circle1.name = "circle1";
- addChild(circle1);
- circle1.addEventListener(MouseEvent.CLICK, traceName);
- var circle2:Sprite = new Sprite();
- circle2.graphics.beginFill(0x0000FF);
- circle2.graphics.drawCircle(140, 40, 40);
- circle2.name = "circle2";
- addChild(circle2);
- circle2.addEventListener(MouseEvent.CLICK, traceName);
- function traceName(event:MouseEvent):void {
- trace(event.target.name);
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:opaqueBackground:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">opaqueBackground</apiName><shortdesc class="- topic/shortdesc ">
- Specifies whether the display object is opaque with a certain background color.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Object</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies whether the display object is opaque with a certain background color.
- A transparent bitmap contains alpha
- channel data and is drawn transparently. An opaque bitmap has no alpha channel (and renders faster
- than a transparent bitmap). If the bitmap is opaque, you specify its own background color to use.
-
- <p class="- topic/p ">If set to a number value, the surface is opaque (not transparent) with the RGB background
- color that the number specifies. If set to <codeph class="+ topic/ph pr-d/codeph ">null</codeph> (the default value), the display
- object has a transparent background.</p>
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">opaqueBackground</codeph> property is intended mainly for use with the
- <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmap</codeph> property, for rendering optimization. For display objects in which the
- <codeph class="+ topic/ph pr-d/codeph ">cacheAsBitmap</codeph> property is set to true, setting <codeph class="+ topic/ph pr-d/codeph ">opaqueBackground</codeph> can
- improve rendering performance.</p>
-
- <p class="- topic/p ">The opaque background region is <i class="+ topic/ph hi-d/i ">not</i> matched when calling the <codeph class="+ topic/ph pr-d/codeph ">hitTestPoint()</codeph>
- method with the <codeph class="+ topic/ph pr-d/codeph ">shapeFlag</codeph> parameter set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.</p>
-
- <p class="- topic/p ">The opaque background region does not respond to mouse events.</p>
-
- </apiDesc><example conref="examples\DisplayObject.opaqueBackground.1.as" class="- topic/example "> The following code creates a Shape object with a blue circle
- and sets its <codeph class="+ topic/ph pr-d/codeph ">opaqueBackground</codeph> property to red (0xFF0000):
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Shape;
- var circle:Shape = new Shape();
- circle.graphics.beginFill(0x0000FF);
- circle.graphics.drawCircle(40, 40, 40);
- circle.opaqueBackground = 0xFF0000;
- addChild(circle);
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject/cacheAsBitmap" class="- topic/link "><linktext class="- topic/linktext ">cacheAsBitmap</linktext></link><link href="flash.display.xml#DisplayObject/hitTestPoint()" class="- topic/link "><linktext class="- topic/linktext ">hitTestPoint()</linktext></link></related-links></apiValue><apiValue id="flash.display:DisplayObject:parent:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">parent</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the DisplayObjectContainer object that contains this display object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:DisplayObjectContainer</apiValueClassifier><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The parent display object belongs to a security sandbox
- to which you do not have access. You can avoid this situation by having
- the parent movie call the <codeph class="+ topic/ph pr-d/codeph ">Security.allowDomain()</codeph> method.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">SecurityError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">SecurityError</apiOperationClassifier></apiException></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the DisplayObjectContainer object that contains this display object. Use the <codeph class="+ topic/ph pr-d/codeph ">parent</codeph>
- property to specify a relative path to display objects that are above the
- current display object in the display list hierarchy.
-
- <p class="- topic/p ">You can use <codeph class="+ topic/ph pr-d/codeph ">parent</codeph> to move up multiple levels in the display list as in the following:</p>
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- this.parent.parent.alpha = 20;
- </codeblock>
-
- </apiDesc><example conref="examples\DisplayObject.parent.1.as" class="- topic/example "> The following code creates three Sprite objects and shows how
- the <codeph class="+ topic/ph pr-d/codeph ">parent</codeph> property reflects the display list hierarchy:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- var sprite1:Sprite = new Sprite();
- sprite1.name = "sprite1";
- var sprite2:Sprite = new Sprite();
- sprite2.name = "sprite2";
- var sprite3:Sprite = new Sprite();
- sprite3.name = "sprite3";
- sprite1.addChild(sprite2);
- sprite2.addChild(sprite3);
- trace(sprite2.parent.name); // sprite1
- trace(sprite3.parent.name); // sprite2
- trace(sprite3.parent.parent.name); // sprite1
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:root:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">root</apiName><shortdesc class="- topic/shortdesc ">
- For a display object in a loaded SWF file, the root property is the
- top-most display object in the portion of the display list's tree structure represented by that SWF file.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:DisplayObject</apiValueClassifier><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Return the root display object for this object.
-
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- For a display object in a loaded SWF file, the <codeph class="+ topic/ph pr-d/codeph ">root</codeph> property is the
- top-most display object in the portion of the display list's tree structure represented by that SWF file.
- For a Bitmap object representing a loaded image file, the <codeph class="+ topic/ph pr-d/codeph ">root</codeph> property is the Bitmap object
- itself. For the instance of the main class of the first SWF file loaded, the <codeph class="+ topic/ph pr-d/codeph ">root</codeph> property is the
- display object itself. The <codeph class="+ topic/ph pr-d/codeph ">root</codeph> property of the Stage object is the Stage object itself. The <codeph class="+ topic/ph pr-d/codeph ">root</codeph>
- property is set to <codeph class="+ topic/ph pr-d/codeph ">null</codeph> for any display object that has not been added to the display list, unless
- it has been added to a display object container that is off the display list but that is a child of the
- top-most display object in a loaded SWF file.
-
- <p class="- topic/p ">For example, if you create a new Sprite object by calling the <codeph class="+ topic/ph pr-d/codeph ">Sprite()</codeph> constructor method,
- its <codeph class="+ topic/ph pr-d/codeph ">root</codeph> property is <codeph class="+ topic/ph pr-d/codeph ">null</codeph> until you add it to the display list (or to a display
- object container that is off the display list but that is a child of the top-most display object in a SWF file).</p>
-
- <p class="- topic/p ">For a loaded SWF file, even though the Loader object used to load the file may not be on the display list,
- the top-most display object in the SWF file has its <codeph class="+ topic/ph pr-d/codeph ">root</codeph> property set to itself. The Loader object
- does not have its <codeph class="+ topic/ph pr-d/codeph ">root</codeph> property set until it is added as a child of a display object for which the
- <codeph class="+ topic/ph pr-d/codeph ">root</codeph> property is set.</p>
-
- </apiDesc><example conref="examples\DisplayObject.root.1.as" class="- topic/example "> The following code shows the difference between the <codeph class="+ topic/ph pr-d/codeph ">root</codeph>
- property for the Stage object, for a display object (a Loader object) that is not loaded (both before
- and after it has been added to the display list), and for a loaded object (a loaded Bitmap object):
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Loader;
- import flash.net.URLRequest;
- import flash.events.Event;
- trace(stage.root); // [object Stage]
- var ldr:Loader = new Loader();
- trace (ldr.root); // null
- addChild(ldr);
- trace (ldr.root); // [object ...]
- var urlReq:URLRequest = new URLRequest("example.jpg");
- ldr.load(urlReq);
- ldr.contentLoaderInfo.addEventListener(Event.COMPLETE, loaded);
- function loaded(event:Event):void {
- trace(ldr.content.root); // [object Bitmap]
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:rotationX:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">rotationX</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the x-axis rotation of the DisplayObject instance, in degrees, from its original orientation relative to the 3D parent container.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the x-axis rotation of the DisplayObject instance, in degrees, from its original orientation relative to the 3D parent container. Values from 0 to 180 represent
- clockwise rotation; values from 0 to -180 represent counterclockwise rotation. Values outside this range are added to or
- subtracted from 360 to obtain a value within the range.
-
- </apiDesc><example conref="examples\RotationExample1.as" class="- topic/example "> In this example, two ellipses rotate using their <codeph class="+ topic/ph pr-d/codeph ">rotationX</codeph> and
- <codeph class="+ topic/ph pr-d/codeph ">rotationY</codeph> properties. The first ellipse's registration point is set
- to its center. It rotates around itself. The second ellipse rotates around
- an external point.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- package {
- import flash.display.MovieClip;
- import flash.display.Shape;
- import flash.geom.*;
- import flash.display.Graphics;
- import flash.events.TimerEvent;
- import flash.utils.Timer;
- public class RotationExample1 extends MovieClip {
- private var ellipse:Shape = new Shape();
- private var speed:int = 10;
- private var ellipse1:Shape;
- private var ellipse2:Shape;
-
- public function RotationExample1():void {
- ellipse1 = drawEllipse(-50, -40, (this.stage.stageWidth / 2),
- (this.stage.stageHeight / 2));
-
- ellipse2 = drawEllipse(30, 40, (this.stage.stageWidth / 2),
- (this.stage.stageHeight / 2));
- this.addChild(ellipse1);
- this.addChild(ellipse2);
- var t:Timer = new Timer(50);
- t.addEventListener(TimerEvent.TIMER, timerHandler);
- t.start();
- }
- private function drawEllipse(x1, y1, x2, y2):Shape {
-
- var e:Shape = new Shape();
- e.graphics.beginFill(0xFF0000);
- e.graphics.lineStyle(2);
- e.graphics.drawEllipse(x1, y1, 100, 80);
- e.graphics.endFill();
- e.x = x2;
- e.y = y2;
- e.z = 1;
- return e;
- }
- private function timerHandler(event:TimerEvent):void {
- ellipse1.rotationY += speed;
- ellipse1.rotationX -= speed;
- ellipse2.rotationY += speed;
- ellipse2.rotationX -= speed;
- }
- }
- }
- </codeblock></example><example conref="examples\Slider_rotationX.as" class="- topic/example "> The following example shows how you can 3D rotate a Sprite object around its x-axis with Flash Professional, ActionScript 3.0, and Flash Player 10 by setting the object's rotationX property.
- Example provided by
- <xref href="http://actionscriptexamples.com/2009/02/26/rotating-a-sprite-object-around-its-x-axis-in-flash-using-actionscript-30-and-flash-player-10/" scope="_mmexternal" class="- topic/xref ">ActionScriptExamples.com</xref>.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- //Requires:
- // - Slider control UI component in Flash library.
- // - Publish for Flash Player 10.
- //
-
- [SWF(width="400", height="300")]
-
- import fl.controls.Slider;
- import fl.controls.SliderDirection;
- import fl.events.SliderEvent;
-
- var slider:Slider = new Slider();
- slider.direction = SliderDirection.HORIZONTAL;
- slider.minimum = 0;
- slider.maximum = 360;
- slider.value = 45;
- slider.tickInterval = 45;
- slider.snapInterval = 1;
- slider.liveDragging = true;
- slider.addEventListener(SliderEvent.CHANGE, slider_change);
- slider.move(10, 10);
- addChild(slider);
-
- var spr:Sprite = new Sprite();
- spr.graphics.lineStyle(2, 0xFF0000);
- spr.graphics.drawRect(0, 0, 100, 80);
- spr.x = Math.round((stage.stageWidth - spr.width)/2);
- spr.y = Math.round((stage.stageHeight - spr.height)/2);
- spr.rotationX = 45;
- addChild(spr);
-
- function slider_change(evt:SliderEvent):void {
- spr.rotationX = evt.value;
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:rotationY:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">rotationY</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the y-axis rotation of the DisplayObject instance, in degrees, from its original orientation relative to the 3D parent container.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the y-axis rotation of the DisplayObject instance, in degrees, from its original orientation relative to the 3D parent container. Values from 0 to 180 represent
- clockwise rotation; values from 0 to -180 represent counterclockwise rotation. Values outside this range are added to or
- subtracted from 360 to obtain a value within the range.
-
-
- </apiDesc><example conref="examples\RotationExample1.as" class="- topic/example "> In this example, two ellipses rotate using their <codeph class="+ topic/ph pr-d/codeph ">rotationX</codeph> and
- <codeph class="+ topic/ph pr-d/codeph ">rotationY</codeph> properties. The first ellipse's registration point is set
- to its center. It rotates around itself. The second ellipse rotates around
- an external point.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- package {
- import flash.display.MovieClip;
- import flash.display.Shape;
- import flash.geom.*;
- import flash.display.Graphics;
- import flash.events.TimerEvent;
- import flash.utils.Timer;
- public class RotationExample1 extends MovieClip {
- private var ellipse:Shape = new Shape();
- private var speed:int = 10;
- private var ellipse1:Shape;
- private var ellipse2:Shape;
-
- public function RotationExample1():void {
- ellipse1 = drawEllipse(-50, -40, (this.stage.stageWidth / 2),
- (this.stage.stageHeight / 2));
-
- ellipse2 = drawEllipse(30, 40, (this.stage.stageWidth / 2),
- (this.stage.stageHeight / 2));
- this.addChild(ellipse1);
- this.addChild(ellipse2);
- var t:Timer = new Timer(50);
- t.addEventListener(TimerEvent.TIMER, timerHandler);
- t.start();
- }
- private function drawEllipse(x1, y1, x2, y2):Shape {
-
- var e:Shape = new Shape();
- e.graphics.beginFill(0xFF0000);
- e.graphics.lineStyle(2);
- e.graphics.drawEllipse(x1, y1, 100, 80);
- e.graphics.endFill();
- e.x = x2;
- e.y = y2;
- e.z = 1;
- return e;
- }
- private function timerHandler(event:TimerEvent):void {
- ellipse1.rotationY += speed;
- ellipse1.rotationX -= speed;
- ellipse2.rotationY += speed;
- ellipse2.rotationX -= speed;
- }
- }
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:rotationZ:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">rotationZ</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the z-axis rotation of the DisplayObject instance, in degrees, from its original orientation relative to the 3D parent container.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the z-axis rotation of the DisplayObject instance, in degrees, from its original orientation relative to the 3D parent container. Values from 0 to 180 represent
- clockwise rotation; values from 0 to -180 represent counterclockwise rotation. Values outside this range are added to or
- subtracted from 360 to obtain a value within the range.
-
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:rotation:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">rotation</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the rotation of the DisplayObject instance, in degrees, from its original orientation.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the rotation of the DisplayObject instance, in degrees, from its original orientation. Values from 0 to 180 represent
- clockwise rotation; values from 0 to -180 represent counterclockwise rotation. Values outside this range are added to or
- subtracted from 360 to obtain a value within the range. For example, the statement <codeph class="+ topic/ph pr-d/codeph ">my_video.rotation = 450</codeph> is the
- same as <codeph class="+ topic/ph pr-d/codeph "> my_video.rotation = 90</codeph>.
-
- </apiDesc><example conref="examples\DisplayObject.rotation.1.as" class="- topic/example "> The following code creates a Sprite object and rotates
- the object when the user clicks it:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var square:Sprite = new Sprite();
- square.graphics.beginFill(0xFFCC00);
- square.graphics.drawRect(-50, -50, 100, 100);
- square.x = 150;
- square.y = 150;
- addChild(square);
- square.addEventListener(MouseEvent.CLICK, rotate);
- function rotate(event:MouseEvent):void {
- square.rotation += 15;
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:scale9Grid:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">scale9Grid</apiName><shortdesc class="- topic/shortdesc ">
- The current scaling grid that is in effect.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata><asCustoms class="+ topic/metadata adobe-api-d/asCustoms "><maelexample>The following creates a movie clip that contains a 20-pixel line (which forms a border)
- and a gradient fill. The movie clip scales based on the mouse position, and because of the
- <code>scale9Grid</code> set for the movie clip, the thickness of the 20-pixel line does not
- vary when the clip scales (although the gradient in the movie clip <em>does</em> scale):
-
- <listing version="2.0">
- import flash.geom.Rectangle;
- import flash.geom.Matrix;
-
- this.createEmptyMovieClip("my_mc", this.getNextHighestDepth());
-
- var grid:Rectangle = new Rectangle(20, 20, 260, 260);
- my_mc.scale9Grid = grid ;
-
- my_mc._x = 50;
- my_mc._y = 50;
-
- function onMouseMove()
- {
- my_mc._width = _xmouse;
- my_mc._height = _ymouse;
- }
-
- my_mc.lineStyle(20, 0xff3333, 100);
- var gradient_matrix:Matrix = new Matrix();
- gradient_matrix.createGradientBox(15, 15, Math.PI, 10, 10);
- my_mc.beginGradientFill("radial", [0xffff00, 0x0000ff],
- [100, 100], [0, 0xFF], gradient_matrix,
- "reflect", "RGB", 0.9);
- my_mc.moveTo(0, 0);
- my_mc.lineTo(0, 300);
- my_mc.lineTo(300, 300);
- my_mc.lineTo(300, 0);
- my_mc.lineTo(0, 0);
- my_mc.endFill();
- </listing>
-
- </maelexample></asCustoms></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.geom:Rectangle</apiValueClassifier><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If you pass an invalid argument to the method.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The current scaling grid that is in effect. If set to <codeph class="+ topic/ph pr-d/codeph ">null</codeph>,
- the entire display object is scaled normally when any scale transformation is
- applied.
-
- <p class="- topic/p ">When you define the <codeph class="+ topic/ph pr-d/codeph ">scale9Grid</codeph> property, the display object is divided into a
- grid with nine regions based on the <codeph class="+ topic/ph pr-d/codeph ">scale9Grid</codeph> rectangle, which defines the
- center region of the grid. The eight other regions of the grid are the following areas: </p>
-
- <ul class="- topic/ul "><li class="- topic/li ">The upper-left corner outside of the rectangle</li><li class="- topic/li ">The area above the rectangle </li><li class="- topic/li ">The upper-right corner outside of the rectangle</li><li class="- topic/li ">The area to the left of the rectangle</li><li class="- topic/li ">The area to the right of the rectangle</li><li class="- topic/li ">The lower-left corner outside of the rectangle</li><li class="- topic/li ">The area below the rectangle</li><li class="- topic/li ">The lower-right corner outside of the rectangle</li></ul>
-
- <p class="- topic/p ">You can think of the eight regions outside of the center (defined by the rectangle)
- as being like a picture frame that has special rules applied to it when scaled.</p>
-
- <p class="- topic/p ">When the <codeph class="+ topic/ph pr-d/codeph ">scale9Grid</codeph> property is set and a display object is scaled, all text and
- gradients are scaled normally; however, for other types of objects the following rules apply:</p>
-
- <ul class="- topic/ul "><li class="- topic/li ">Content in the center region is scaled normally. </li><li class="- topic/li ">Content in the corners is not scaled. </li><li class="- topic/li ">Content in the top and bottom regions is scaled horizontally only. Content in the
- left and right regions is scaled vertically only.</li><li class="- topic/li ">All fills (including bitmaps, video, and gradients) are stretched to fit their shapes.</li></ul>
-
- <p class="- topic/p ">If a display object is rotated, all subsequent scaling is normal (and the
- <codeph class="+ topic/ph pr-d/codeph ">scale9Grid</codeph> property is ignored).</p>
-
- <p class="- topic/p ">For example, consider the following display object and a rectangle that is applied as the display
- object's <codeph class="+ topic/ph pr-d/codeph ">scale9Grid</codeph>:</p>
-
- <adobetable class="+ topic/table adobe-d/adobetable "><tgroup cols="2" class="- topic/tgroup "><tbody class="- topic/tbody "><row class="- topic/row "><entry align="center" class="- topic/entry "><adobeimage alt="display object image" href="../../images/scale9Grid-a.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/>
- <p class="- topic/p ">The display object.</p></entry><entry align="center" class="- topic/entry "><adobeimage alt="display object scale 9 region" href="../../images/scale9Grid-b.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/>
- <p class="- topic/p ">The red rectangle shows the <codeph class="+ topic/ph pr-d/codeph ">scale9Grid</codeph>.</p></entry></row></tbody></tgroup></adobetable>
-
- <p class="- topic/p ">When the display object is scaled or stretched, the objects within the rectangle scale
- normally, but the objects outside of the rectangle scale according to the
- <codeph class="+ topic/ph pr-d/codeph ">scale9Grid</codeph> rules:</p>
-
- <adobetable class="+ topic/table adobe-d/adobetable "><tgroup cols="2" class="- topic/tgroup "><tbody class="- topic/tbody "><row class="- topic/row "><entry class="- topic/entry ">Scaled to 75%:</entry><entry class="- topic/entry "><adobeimage alt="display object at 75%" href="../../images/scale9Grid-c.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry></row><row class="- topic/row "><entry class="- topic/entry ">Scaled to 50%:</entry><entry class="- topic/entry "><adobeimage alt="display object at 50%" href="../../images/scale9Grid-d.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry></row><row class="- topic/row "><entry class="- topic/entry ">Scaled to 25%:</entry><entry class="- topic/entry "><adobeimage alt="display object at 25%" href="../../images/scale9Grid-e.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry></row><row class="- topic/row "><entry class="- topic/entry ">Stretched horizontally 150%: </entry><entry class="- topic/entry "><adobeimage alt="display stretched 150%" href="../../images/scale9Grid-f.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry></row></tbody></tgroup></adobetable>
-
- <p class="- topic/p ">A common use for setting <codeph class="+ topic/ph pr-d/codeph ">scale9Grid</codeph> is to set up a display object to be used
- as a component, in which edge regions retain the same width when the component is scaled.</p>
-
- </apiDesc><example conref="examples\DisplayObject.scale9Grid.1.as" class="- topic/example "> The following code creates a Shape object with a rectangle drawn in its
- <codeph class="+ topic/ph pr-d/codeph ">graphics</codeph> property. The rectangle has a 20-pixel-thick line as the border and
- it is filled with a gradient. The timer event calls the <codeph class="+ topic/ph pr-d/codeph ">scale()</codeph> function, which
- scales the Shape object by adjusting the <codeph class="+ topic/ph pr-d/codeph ">scaleX</codeph> and <codeph class="+ topic/ph pr-d/codeph ">scaleY</codeph> properties.
- The <codeph class="+ topic/ph pr-d/codeph ">scale9Grid</codeph> applied to the Shape object prevents the rectangle's border line
- from scaling — only the gradient fill scales:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Shape;
- import flash.display.GradientType;
- import flash.display.SpreadMethod;
- import flash.display.InterpolationMethod;
- import flash.geom.Matrix;
- import flash.geom.Rectangle;
- import flash.utils.Timer;
- import flash.events.TimerEvent;
- var square:Shape = new Shape();
- square.graphics.lineStyle(20, 0xFFCC00);
- var gradientMatrix:Matrix = new Matrix();
- gradientMatrix.createGradientBox(15, 15, Math.PI, 10, 10);
- square.graphics.beginGradientFill(GradientType.RADIAL,
- [0xffff00, 0x0000ff],
- [100, 100],
- [0, 0xFF],
- gradientMatrix,
- SpreadMethod.REFLECT,
- InterpolationMethod.RGB,
- 0.9);
- square.graphics.drawRect(0, 0, 100, 100);
- var grid:Rectangle = new Rectangle(20, 20, 60, 60);
- square.scale9Grid = grid ;
- addChild(square);
- var tim:Timer = new Timer(100);
- tim.start();
- tim.addEventListener(TimerEvent.TIMER, scale);
- var scaleFactor:Number = 1.01;
- function scale(event:TimerEvent):void {
- square.scaleX *= scaleFactor;
- square.scaleY *= scaleFactor;
-
- if (square.scaleX > 2.0) {
- scaleFactor = 0.99;
- }
- if (square.scaleX < 1.0) {
- scaleFactor = 1.01;
- }
- }
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.geom.xml#Rectangle" class="- topic/link "><linktext class="- topic/linktext ">flash.geom.Rectangle</linktext></link></related-links></apiValue><apiValue id="flash.display:DisplayObject:scaleX:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">scaleX</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the horizontal scale (percentage) of the object as applied from the registration point.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the horizontal scale (percentage) of the object as applied from the registration point. The default
- registration point is (0,0). 1.0 equals 100% scale.
-
- <p class="- topic/p ">Scaling the local coordinate system changes the <codeph class="+ topic/ph pr-d/codeph ">x</codeph> and <codeph class="+ topic/ph pr-d/codeph ">y</codeph> property values, which are defined in
- whole pixels. </p>
-
- </apiDesc><example conref="examples\DisplayObject.scaleX.1.as" class="- topic/example "> The following code creates a Sprite object with a rectangle drawn in its
- <codeph class="+ topic/ph pr-d/codeph ">graphics</codeph> property. When the user clicks the sprite, it scales by 10%:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var square:Sprite = new Sprite();
- square.graphics.beginFill(0xFFCC00);
- square.graphics.drawRect(0, 0, 100, 100);
- addChild(square);
- square.addEventListener(MouseEvent.CLICK, scale);
- function scale(event:MouseEvent):void {
- square.scaleX *= 1.10;
- square.scaleY *= 1.10;
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:scaleY:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">scaleY</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the vertical scale (percentage) of an object as applied from the registration point of the object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the vertical scale (percentage) of an object as applied from the registration point of the object. The
- default registration point is (0,0). 1.0 is 100% scale.
-
- <p class="- topic/p ">Scaling the local coordinate system changes the <codeph class="+ topic/ph pr-d/codeph ">x</codeph> and <codeph class="+ topic/ph pr-d/codeph ">y</codeph> property values, which are defined in
- whole pixels. </p>
-
- </apiDesc><example conref="examples\DisplayObject.scaleX.1.as" class="- topic/example "> The following code creates a Sprite object with a rectangle drawn in its
- <codeph class="+ topic/ph pr-d/codeph ">graphics</codeph> property. When the user clicks the sprite, it scales by 10%:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var square:Sprite = new Sprite();
- square.graphics.beginFill(0xFFCC00);
- square.graphics.drawRect(0, 0, 100, 100);
- addChild(square);
- square.addEventListener(MouseEvent.CLICK, scale);
- function scale(event:MouseEvent):void {
- square.scaleX *= 1.10;
- square.scaleY *= 1.10;
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:scaleZ:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">scaleZ</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the depth scale (percentage) of an object as applied from the registration point of the object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the depth scale (percentage) of an object as applied from the registration point of the object. The
- default registration point is (0,0). 1.0 is 100% scale.
-
- <p class="- topic/p ">Scaling the local coordinate system changes the <codeph class="+ topic/ph pr-d/codeph ">x</codeph>, <codeph class="+ topic/ph pr-d/codeph ">y</codeph> and <codeph class="+ topic/ph pr-d/codeph ">z</codeph> property values, which are defined in
- whole pixels. </p>
-
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject/z" class="- topic/link "><linktext class="- topic/linktext ">z</linktext></link></related-links></apiValue><apiValue id="flash.display:DisplayObject:scrollRect:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">scrollRect</apiName><shortdesc class="- topic/shortdesc ">
- The scroll rectangle bounds of the display object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.geom:Rectangle</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The scroll rectangle bounds of the display object. The display object is cropped to the size
- defined by the rectangle, and it scrolls within the rectangle when you change the
- <codeph class="+ topic/ph pr-d/codeph ">x</codeph> and <codeph class="+ topic/ph pr-d/codeph ">y</codeph> properties of the <codeph class="+ topic/ph pr-d/codeph ">scrollRect</codeph> object.
-
- <p class="- topic/p ">The properties of the <codeph class="+ topic/ph pr-d/codeph ">scrollRect</codeph> Rectangle object use the display object's coordinate space
- and are scaled just like the overall display object. The corner bounds of the cropped window on the scrolling
- display object are the origin of the display object (0,0) and the point defined by the
- width and height of the rectangle. They are not centered around the origin, but
- use the origin to define the upper-left corner of the area. A scrolled display object always
- scrolls in whole pixel increments. </p>
-
- <p class="- topic/p ">You can scroll an object left and right by setting the <codeph class="+ topic/ph pr-d/codeph ">x</codeph> property of the
- <codeph class="+ topic/ph pr-d/codeph ">scrollRect</codeph> Rectangle object. You can scroll an object up and down by setting
- the <codeph class="+ topic/ph pr-d/codeph ">y</codeph> property of the <codeph class="+ topic/ph pr-d/codeph ">scrollRect</codeph> Rectangle object. If the display object
- is rotated 90° and you scroll it left and right, the display object actually scrolls up and down.</p>
-
- </apiDesc><example conref="examples\DisplayObject.scrollRect.1.as" class="- topic/example "> The following example shows how the <codeph class="+ topic/ph pr-d/codeph ">scrollRect</codeph> property defines the
- scrolling area for a display object, <codeph class="+ topic/ph pr-d/codeph ">circle</codeph>. When you click the <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> object,
- the <codeph class="+ topic/ph pr-d/codeph ">clicked()</codeph> event handler method adjusts the <codeph class="+ topic/ph pr-d/codeph ">y</codeph> property of the
- <codeph class="+ topic/ph pr-d/codeph ">scrollRect</codeph> property of the <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> object, causing the object to scroll down:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.geom.Rectangle;
- import flash.events.MouseEvent;
- var circle:Sprite = new Sprite();
- circle.graphics.beginFill(0xFFCC00);
- circle.graphics.drawCircle(200, 200, 200);
- circle.scrollRect = new Rectangle(0, 0, 200, 200);
- addChild(circle);
- circle.addEventListener(MouseEvent.CLICK, clicked);
- function clicked(event:MouseEvent):void {
- var rect:Rectangle = event.target.scrollRect;
- rect.y -= 5;
- event.target.scrollRect = rect;
- }
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.geom.xml#Rectangle" class="- topic/link "><linktext class="- topic/linktext ">flash.geom.Rectangle</linktext></link></related-links></apiValue><apiValue id="flash.display:DisplayObject:stage:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">stage</apiName><shortdesc class="- topic/shortdesc ">
- The Stage of the display object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:Stage</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The Stage of the display object. A Flash runtime application has only one Stage object.
- For example, you can create and load multiple display objects into the display list, and the
- <codeph class="+ topic/ph pr-d/codeph ">stage</codeph> property of each display object refers to the same Stage object (even if the
- display object belongs to a loaded SWF file).
-
- <p class="- topic/p ">If a display object is not added to the display list, its <codeph class="+ topic/ph pr-d/codeph ">stage</codeph> property is set to
- <codeph class="+ topic/ph pr-d/codeph ">null</codeph>.</p>
-
- </apiDesc><example conref="examples\DisplayObject.stage.1.as" class="- topic/example "> The following code creates two TextField objects and uses the
- <codeph class="+ topic/ph pr-d/codeph ">width</codeph> property of the Stage object to position the text fields:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.text.TextField;
- var tf1:TextField = new TextField();
- tf1.text = "Text Field 1";
- tf1.border = true;
- tf1.x = 10;
- addChild(tf1);
- tf1.width = tf1.stage.stageWidth / 2 - 10;
- var tf2:TextField = new TextField();
- tf2.text = "Text Field 2";
- tf2.border = true;
- tf2.x = tf1.x + tf1.width + 5;
- addChild(tf2);
- tf2.width = tf2.stage.stageWidth / 2 - 10;
- trace(stage.stageWidth);
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:transform:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">transform</apiName><shortdesc class="- topic/shortdesc ">
- An object with properties pertaining to a display object's matrix, color transform, and pixel bounds.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.geom:Transform</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- An object with properties pertaining to a display object's matrix, color transform, and pixel bounds.
- The specific properties — matrix, colorTransform, and three read-only properties
- (<codeph class="+ topic/ph pr-d/codeph ">concatenatedMatrix</codeph>, <codeph class="+ topic/ph pr-d/codeph ">concatenatedColorTransform</codeph>,
- and <codeph class="+ topic/ph pr-d/codeph ">pixelBounds</codeph>) — are described in the entry for the Transform class.
-
- <p class="- topic/p ">Each of the transform object's properties is itself an object. This concept is important because the only
- way to set new values for the matrix or colorTransform objects is to create a new object and copy that
- object into the transform.matrix or transform.colorTransform property.</p>
-
- <p class="- topic/p ">For example, to increase the <codeph class="+ topic/ph pr-d/codeph ">tx</codeph> value of a display object's matrix, you must make a
- copy of the entire matrix object, then copy the new object into the matrix property of the transform
- object:</p>
-
- <pre xml:space="preserve" class="- topic/pre "><codeph class="+ topic/ph pr-d/codeph ">
- var myMatrix:Matrix = myDisplayObject.transform.matrix;
- myMatrix.tx += 10;
- myDisplayObject.transform.matrix = myMatrix;
- </codeph></pre>
-
- <p class="- topic/p ">You cannot directly set the <codeph class="+ topic/ph pr-d/codeph ">tx</codeph> property. The following code has
- no effect on <codeph class="+ topic/ph pr-d/codeph ">myDisplayObject</codeph>: </p>
-
- <pre xml:space="preserve" class="- topic/pre "><codeph class="+ topic/ph pr-d/codeph ">
- myDisplayObject.transform.matrix.tx += 10;
- </codeph></pre>
-
- <p class="- topic/p ">You can also copy an entire transform object and assign it to another
- display object's transform property. For example, the following code
- copies the entire transform object from <codeph class="+ topic/ph pr-d/codeph ">myOldDisplayObj</codeph> to
- <codeph class="+ topic/ph pr-d/codeph ">myNewDisplayObj</codeph>:</p>
- <codeph class="+ topic/ph pr-d/codeph ">myNewDisplayObj.transform = myOldDisplayObj.transform;</codeph>
- <p class="- topic/p ">The resulting display object, <codeph class="+ topic/ph pr-d/codeph ">myNewDisplayObj</codeph>, now has the same values for its
- matrix, color transform, and pixel bounds as the old display object, <codeph class="+ topic/ph pr-d/codeph ">myOldDisplayObj</codeph>.</p>
-
- <p class="- topic/p ">Note that AIR for TV devices use hardware acceleration, if it is available, for color transforms.</p>
-
- </apiDesc><example conref="examples\DisplayObject.transform.1.as" class="- topic/example "> The following code sets up a <codeph class="+ topic/ph pr-d/codeph ">square</codeph> Sprite object.
- When the user clicks the sprite, the <codeph class="+ topic/ph pr-d/codeph ">transformer()</codeph> method adjusts
- the <codeph class="+ topic/ph pr-d/codeph ">colorTransform</codeph> and <codeph class="+ topic/ph pr-d/codeph ">matrix</codeph> properties of the
- <codeph class="+ topic/ph pr-d/codeph ">transform</codeph> property of the sprite:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.geom.ColorTransform;
- import flash.geom.Matrix;
- import flash.geom.Transform;
- import flash.events.MouseEvent;
- var square:Sprite = new Sprite();
- square.graphics.lineStyle(20, 0xFF2200);
- square.graphics.beginFill(0x0000DD);
- square.graphics.drawRect(0, 0, 100, 100);
- addChild(square);
- var resultColorTransform:ColorTransform = new ColorTransform();
- resultColorTransform.alphaMultiplier = 0.5;
- resultColorTransform.redOffset = 155;
- resultColorTransform.greenMultiplier = 0.5;
- var skewMatrix:Matrix = new Matrix(1, 1, 0, 1);
- square.addEventListener(MouseEvent.CLICK, transformer);
- function transformer(event:MouseEvent):void {
- var transformation:Transform = square.transform;
- var tempMatrix:Matrix = square.transform.matrix;
- tempMatrix.concat(skewMatrix);
- square.transform.colorTransform = resultColorTransform;
-
- square.transform.matrix = tempMatrix;
- }
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.geom.xml#Transform" class="- topic/link "><linktext class="- topic/linktext ">Transform class</linktext></link></related-links></apiValue><apiValue id="flash.display:DisplayObject:visible:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">visible</apiName><shortdesc class="- topic/shortdesc ">
- Whether or not the display object is visible.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Whether or not the display object is visible. Display objects that are not visible
- are disabled. For example, if <codeph class="+ topic/ph pr-d/codeph ">visible=false</codeph> for an InteractiveObject instance,
- it cannot be clicked.
-
- </apiDesc><example conref="examples\DisplayObject.visible.1.as" class="- topic/example "> The following code uses a Timer object to call a function that
- periodically changes the <codeph class="+ topic/ph pr-d/codeph ">visible</codeph> property of a display object,
- resulting in a blinking effect:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.text.TextField;
- import flash.utils.Timer;
- import flash.events.TimerEvent;
- var tf:TextField = new TextField();
- tf.text = "Hello.";
- addChild(tf);
- var tim:Timer = new Timer(250);
- tim.start();
- tim.addEventListener(TimerEvent.TIMER, blinker);
- function blinker(event:TimerEvent):void {
- tf.visible = !tf.visible;
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:width:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">width</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the width of the display object, in pixels.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the width of the display object, in pixels. The width is calculated based on the bounds of the content of the display object.
- When you set the <codeph class="+ topic/ph pr-d/codeph ">width</codeph> property, the <codeph class="+ topic/ph pr-d/codeph ">scaleX</codeph> property is adjusted accordingly, as shown in the
- following code:
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- var rect:Shape = new Shape();
- rect.graphics.beginFill(0xFF0000);
- rect.graphics.drawRect(0, 0, 100, 100);
- trace(rect.scaleX) // 1;
- rect.width = 200;
- trace(rect.scaleX) // 2;</codeblock>
-
- <p class="- topic/p ">Except for TextField and Video objects, a display object with no content (such as an empty sprite) has a width
- of 0, even if you try to set <codeph class="+ topic/ph pr-d/codeph ">width</codeph> to a different value.</p>
-
- </apiDesc><example conref="examples\DisplayObject.width.1.as" class="- topic/example "> The following code sets up a <codeph class="+ topic/ph pr-d/codeph ">square</codeph> Sprite object.
- When the user clicks the sprite, the <codeph class="+ topic/ph pr-d/codeph ">widen()</codeph> method increases
- the <codeph class="+ topic/ph pr-d/codeph ">width</codeph> property of the sprite:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var square:Sprite = new Sprite();
- square.graphics.beginFill(0xFF0000);
- square.graphics.drawRect(0, 0, 100, 100);
- addChild(square);
- square.addEventListener(MouseEvent.CLICK, widen);
- function widen(event:MouseEvent):void {
- square.width += 10;
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:x:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">x</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the x coordinate of the DisplayObject instance relative to the local coordinates of
- the parent DisplayObjectContainer.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the <i class="+ topic/ph hi-d/i ">x</i> coordinate of the DisplayObject instance relative to the local coordinates of
- the parent DisplayObjectContainer. If the object is inside a DisplayObjectContainer that has
- transformations, it is in the local coordinate system of the enclosing DisplayObjectContainer.
- Thus, for a DisplayObjectContainer rotated 90° counterclockwise, the DisplayObjectContainer's
- children inherit a coordinate system that is rotated 90° counterclockwise.
- The object's coordinates refer to the registration point position.
-
- </apiDesc><example conref="examples\DisplayObject.x.1.as" class="- topic/example "> The following code sets up a <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> Sprite object.
- A Timer object is used to change the <codeph class="+ topic/ph pr-d/codeph ">x</codeph> property of the sprite
- every 50 milliseconds:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.utils.Timer;
- import flash.events.TimerEvent;
- var circle:Sprite = new Sprite();
- circle.graphics.beginFill(0xFF0000);
- circle.graphics.drawCircle(100, 100, 100);
- addChild(circle);
- var tim:Timer = new Timer(50);
- tim.start();
- tim.addEventListener(TimerEvent.TIMER, bounce);
- var xInc:Number = 2;
- function bounce(event:TimerEvent):void {
- circle.x += xInc;
- if (circle.x > circle.width) {
- xInc = -2;
- }
- if (circle.x < 0) {
- xInc = 2;
- }
- }
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:y:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">y</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the y coordinate of the DisplayObject instance relative to the local coordinates of
- the parent DisplayObjectContainer.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the <i class="+ topic/ph hi-d/i ">y</i> coordinate of the DisplayObject instance relative to the local coordinates of
- the parent DisplayObjectContainer. If the object is inside a DisplayObjectContainer that has
- transformations, it is in the local coordinate system of the enclosing DisplayObjectContainer.
- Thus, for a DisplayObjectContainer rotated 90° counterclockwise, the DisplayObjectContainer's
- children inherit a coordinate system that is rotated 90° counterclockwise.
- The object's coordinates refer to the registration point position.
-
- </apiDesc><example conref="examples\DisplayObject.height.1.as" class="- topic/example "> The following code creates two TextField objects and adjusts the
- <codeph class="+ topic/ph pr-d/codeph ">height</codeph> property of each based on the <codeph class="+ topic/ph pr-d/codeph ">textHeight</codeph> property of
- each; it also positions the second text field by setting its <codeph class="+ topic/ph pr-d/codeph ">y</codeph> property:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.text.TextField;
- var tf1:TextField = new TextField();
- tf1.text = "Text Field 1";
- tf1.border = true;
- tf1.wordWrap = true;
- tf1.width = 40;
- tf1.height = tf1.textHeight + 5;
- addChild(tf1);
- var tf2:TextField = new TextField();
- tf2.text = "Text Field 2";
- tf2.border = true;
- tf2.wordWrap = true;
- tf2.width = 40;
- tf2.height = tf2.textHeight + 5;
- tf2.y = tf1.y + tf1.height + 5;
- addChild(tf2);
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObject:z:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">z</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the z coordinate position along the z-axis of the DisplayObject
- instance relative to the 3D parent container.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the z coordinate position along the z-axis of the DisplayObject
- instance relative to the 3D parent container. The z property is used for
- 3D coordinates, not screen or pixel coordinates.
- <p class="- topic/p ">When you set a <codeph class="+ topic/ph pr-d/codeph ">z</codeph> property for a display object to something other than the default
- value of <codeph class="+ topic/ph pr-d/codeph ">0</codeph>, a corresponding Matrix3D object is automatically created. for adjusting a
- display object's position and orientation
- in three dimensions. When working with the z-axis,
- the existing behavior of x and y properties changes from screen or pixel coordinates to
- positions relative to the 3D parent container.</p>
- <p class="- topic/p ">For example, a child of the <codeph class="+ topic/ph pr-d/codeph ">_root</codeph> at position x = 100, y = 100, z = 200
- is not drawn at pixel location (100,100). The child is drawn wherever the 3D projection
- calculation puts it. The calculation is:</p>
- <p class="- topic/p "><codeph class="+ topic/ph pr-d/codeph "> (x~~cameraFocalLength/cameraRelativeZPosition, y~~cameraFocalLength/cameraRelativeZPosition)</codeph></p>
-
-
- </apiDesc><example conref="examples\ZAxisExample1.as" class="- topic/example "> This example draws two ellipses and has them go back and forth (down and up the
- <codeph class="+ topic/ph pr-d/codeph ">z</codeph> axis) toward the vanishing point. One ellipse is set to move faster
- than the other.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- package {
- import flash.display.MovieClip;
- import flash.display.Shape;
- import flash.display.Graphics;
- import flash.events.Event;
- import flash.geom.*;
- public class ZAxisExample1 extends MovieClip {
- private var ellipse1Back:int = 1;
- private var ellipse2Back:int = 1;
- private var depth:int = 1000;
-
- public function ZAxisExample1():void {
-
- var ellipse1 = drawEllipse((this.stage.stageWidth / 2) - 100,
- (this.stage.stageHeight / 2), 100, 80, 10);
- var ellipse2 = drawEllipse((this.stage.stageWidth / 2) + 100,
- (this.stage.stageHeight / 2), 100, 80, 300);
- this.addChild(ellipse1);
- this.addChild(ellipse2);
-
- ellipse1.addEventListener(Event.ENTER_FRAME, ellipse1FrameHandler);
- ellipse2.addEventListener(Event.ENTER_FRAME, ellipse2FrameHandler);
- }
- private function drawEllipse(x:Number, y:Number, w:Number, h:Number, z:Number):Shape {
- var s:Shape = new Shape();
- s.z = z;
- s.graphics.beginFill(0xFF0000);
- s.graphics.lineStyle(2);
- s.graphics.drawEllipse(x, y, w, h);
- s.graphics.endFill();
- return s;
- }
- private function ellipse1FrameHandler(e:Event):void {
- ellipse1Back = setDepth(e, ellipse1Back);
- e.currentTarget.z += ellipse1Back * 10;
- }
- private function ellipse2FrameHandler(e:Event):void {
- ellipse2Back = setDepth(e, ellipse2Back);
- e.currentTarget.z += ellipse2Back * 20;
- }
- private function setDepth(e:Event, d:int):int {
- if(e.currentTarget.z > depth) {
- e.currentTarget.z = depth;
- d = -1;
- }else if (e.currentTarget.z < 0) {
- e.currentTarget.z = 0;
- d = 1;
- }
- return d;
- }
- }
- }
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.geom.xml#PerspectiveProjection" class="- topic/link "><linktext class="- topic/linktext ">flash.geom.PerspectiveProjection</linktext></link><link href="flash.geom.xml#Matrix3D" class="- topic/link "><linktext class="- topic/linktext ">flash.geom.Matrix3D</linktext></link><link href="flash.display.xml#DisplayObject/transform" class="- topic/link "><linktext class="- topic/linktext ">transform</linktext></link></related-links></apiValue><apiValue id="flash.display:DisplayObject:blendShader:set" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">blendShader</apiName><shortdesc class="- topic/shortdesc ">
- Sets a shader that is used for blending the foreground and background.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="write" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:Shader</apiValueClassifier><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">When the shader output type is not compatible with this operation
- (the shader must specify a <codeph class="+ topic/ph pr-d/codeph ">pixel4</codeph>
- output).
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">When the shader specifies fewer than two image inputs or the first
- two inputs are not <codeph class="+ topic/ph pr-d/codeph ">image4</codeph> inputs.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">When the shader specifies an image input that isn't provided.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">When a ByteArray or Vector.<Number> instance is used as
- an input and the <codeph class="+ topic/ph pr-d/codeph ">width</codeph>
- and <codeph class="+ topic/ph pr-d/codeph ">height</codeph> properties aren't specified for the
- ShaderInput, or the specified values don't match the amount of
- data in the input object. See the <codeph class="+ topic/ph pr-d/codeph ">ShaderInput.input</codeph>
- property for more information.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Sets a shader that is used for blending the foreground and background. When the
- <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property is set to <codeph class="+ topic/ph pr-d/codeph ">BlendMode.SHADER</codeph>, the specified
- Shader is used to create the blend mode output for the display object.
-
- <p class="- topic/p ">Setting the <codeph class="+ topic/ph pr-d/codeph ">blendShader</codeph> property of a display object to a Shader instance
- automatically sets the display object's <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property to
- <codeph class="+ topic/ph pr-d/codeph ">BlendMode.SHADER</codeph>. If the <codeph class="+ topic/ph pr-d/codeph ">blendShader</codeph> property is set (which sets the
- <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property to <codeph class="+ topic/ph pr-d/codeph ">BlendMode.SHADER</codeph>), then the value of the
- <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property is changed, the blend mode can be reset to use the blend
- shader simply by setting the <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property to <codeph class="+ topic/ph pr-d/codeph ">BlendMode.SHADER</codeph>.
- The <codeph class="+ topic/ph pr-d/codeph ">blendShader</codeph> property does not need to be set again except to change the
- shader that's used for the blend mode.</p>
-
- <p class="- topic/p ">The Shader assigned to the <codeph class="+ topic/ph pr-d/codeph ">blendShader</codeph> property must specify at least two
- <codeph class="+ topic/ph pr-d/codeph ">image4</codeph> inputs. The inputs <b class="+ topic/ph hi-d/b ">do not</b> need to be specified in code using the
- associated ShaderInput objects' <codeph class="+ topic/ph pr-d/codeph ">input</codeph> properties. The background display object
- is automatically
- used as the first input (the input with <codeph class="+ topic/ph pr-d/codeph ">index</codeph> 0). The foreground display object
- is used as the second input (the input with <codeph class="+ topic/ph pr-d/codeph ">index</codeph> 1). A shader used as a blend
- shader can specify more than two inputs. In that case, any additional input must be specified
- by setting its ShaderInput instance's <codeph class="+ topic/ph pr-d/codeph ">input</codeph> property.</p>
-
- <p class="- topic/p ">When you assign a Shader instance to this property the shader is copied internally. The
- blend operation uses that internal copy, not a reference to the original shader. Any changes
- made to the shader, such as changing a parameter value, input, or bytecode, are not applied
- to the copied shader that's used for the blend mode.</p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#BlendMode" class="- topic/link "><linktext class="- topic/linktext ">flash.display.BlendMode</linktext></link><link href="flash.display.xml#Shader" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Shader</linktext></link><link href="flash.display.xml#ShaderInput" class="- topic/link "><linktext class="- topic/linktext ">flash.display.ShaderInput</linktext></link></related-links></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:Loader" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">Loader</apiName><shortdesc class="- topic/shortdesc ">
- The Loader class is used to load SWF files or image (JPG, PNG, or GIF) files.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">flash.display:DisplayObjectContainer</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The Loader class is used to load SWF files or image (JPG, PNG, or GIF) files. Use the
- <codeph class="+ topic/ph pr-d/codeph ">load()</codeph> method to initiate loading. The loaded display object is added as a child
- of the Loader object.
-
- <p class="- topic/p ">Use the URLLoader class to load text or binary data.</p>
-
- <p class="- topic/p ">The Loader class overrides the following methods that it inherits, because a Loader object can only
- have one child display object—the display object that it loads. Calling the following methods throws an
- exception: <codeph class="+ topic/ph pr-d/codeph ">addChild()</codeph>, <codeph class="+ topic/ph pr-d/codeph ">addChildAt()</codeph>, <codeph class="+ topic/ph pr-d/codeph ">removeChild()</codeph>,
- <codeph class="+ topic/ph pr-d/codeph ">removeChildAt()</codeph>, and <codeph class="+ topic/ph pr-d/codeph ">setChildIndex()</codeph>. To remove a loaded display object,
- you must remove the <i class="+ topic/ph hi-d/i ">Loader</i> object from its parent DisplayObjectContainer child array. </p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> The ActionScript 2.0 MovieClipLoader and LoadVars classes are not used
- in ActionScript 3.0. The Loader and URLLoader classes replace them.</p>
-
- <p class="- topic/p ">When you use the Loader class, consider the Flash Player and Adobe AIR security model: </p>
-
- <ul class="- topic/ul "><li class="- topic/li ">You can load content from any accessible source. </li><li class="- topic/li ">Loading is not allowed if the calling SWF file is in a network sandbox and the file
- to be loaded is local. </li><li class="- topic/li ">If the loaded content is a SWF file written with ActionScript 3.0, it cannot be
- cross-scripted by a SWF file in another security sandbox unless that cross-scripting
- arrangement was approved through a call to the <codeph class="+ topic/ph pr-d/codeph ">System.allowDomain()</codeph> or
- the <codeph class="+ topic/ph pr-d/codeph ">System.allowInsecureDomain()</codeph> method in the loaded content file.</li><li class="- topic/li ">If the loaded content is an AVM1 SWF file (written using ActionScript 1.0 or 2.0),
- it cannot be cross-scripted by an AVM2 SWF file (written using ActionScript 3.0). However,
- you can communicate between the two SWF files by using the LocalConnection class.</li><li class="- topic/li ">If the loaded content is an image, its data cannot be accessed by a SWF file
- outside of the security sandbox, unless the domain of that SWF file was included in a
- URL policy file at the origin domain of the image.</li><li class="- topic/li ">Movie clips in the local-with-file-system sandbox cannot script movie clips in the
- local-with-networking sandbox, and the reverse is also prevented. </li><li class="- topic/li ">You cannot connect to commonly reserved ports. For a complete list of blocked ports,
- see "Restricting Networking APIs" in the <i class="+ topic/ph hi-d/i ">ActionScript 3.0 Developer's Guide</i>. </li></ul>
-
- <p class="- topic/p ">However, in AIR, content in the <codeph class="+ topic/ph pr-d/codeph ">application</codeph> security sandbox (content
- installed with the AIR application) are not restricted by these security limitations.</p>
-
- <p class="- topic/p ">For more information related to security, see the Flash Player Developer Center Topic:
- <xref href="http://www.adobe.com/go/devnet_security_en" scope="external" class="- topic/xref ">Security</xref>.</p>
-
- <p class="- topic/p ">When loading a SWF file from an untrusted source (such as a domain other than that of
- the Loader object's root SWF file), you may want to define a mask for the Loader object,
- to prevent the loaded content (which is a child of the Loader object) from drawing to
- portions of the Stage outside of that mask, as shown in the following code:</p>
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">import flash.display.~~;
- import flash.net.URLRequest;
- var rect:Shape = new Shape();
- rect.graphics.beginFill(0xFFFFFF);
- rect.graphics.drawRect(0, 0, 100, 100);
- rect.graphics.endFill();
- addChild(rect);
- var ldr:Loader = new Loader();
- ldr.mask = rect;
- var url:String = "http://www.unknown.example.com/content.swf";
- var urlReq:URLRequest = new URLRequest(url);
- ldr.load(urlReq);
- addChild(ldr);
- </codeblock>
-
- </apiDesc><example conref="examples\LoaderExample.as" class="- topic/example "> The following example uses the LoaderExample class to illustrate how various
- event listeners are used. This task is accomplished by performing the following steps:
- <ol class="- topic/ol "><li class="- topic/li ">A <codeph class="+ topic/ph pr-d/codeph ">url</codeph> property is created, which is the location and name of the image file</li><li class="- topic/li ">In the <codeph class="+ topic/ph pr-d/codeph ">LoaderExample</codeph> constructor, a new Loader object named <codeph class="+ topic/ph pr-d/codeph ">loader</codeph> is
- created, which is then passed to the <codeph class="+ topic/ph pr-d/codeph ">configureListeners()</codeph> method, described in step 3.</li><li class="- topic/li ">The constructor creates a new instance of a URLRequest object,
- <codeph class="+ topic/ph pr-d/codeph ">request</codeph>, with <codeph class="+ topic/ph pr-d/codeph ">url</codeph> passed so that the file name and location are known.</li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">request</codeph> object is passed to the <codeph class="+ topic/ph pr-d/codeph ">loader</codeph> object's
- <codeph class="+ topic/ph pr-d/codeph ">load()</codeph> method, which loads the image onto the display list.</li><li class="- topic/li ">A <codeph class="+ topic/ph pr-d/codeph ">clickHandler</codeph> event listener is registered for the <codeph class="+ topic/ph pr-d/codeph ">click</codeph> event on the loader.
- After a mouse click, the loaded image is unloaded.</li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">configureListeners()</codeph> method adds seven event listeners by using the following methods:
- <ul class="- topic/ul "><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">completeHandler()</codeph> method executes when the image finishes loading.</li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">httpStatusHandler()</codeph> method executes if the image is not loaded
- locally and only if the network request is made available and the Flash Player can detect it.</li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">initHandler()</codeph> method executes before the <codeph class="+ topic/ph pr-d/codeph ">completeHandler()</codeph>
- method and after the <codeph class="+ topic/ph pr-d/codeph ">progressHandler()</codeph> method. Generally, the <codeph class="+ topic/ph pr-d/codeph ">init</codeph>
- event is more useful when loading SWF files.</li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">ioErrorHandler()</codeph> method executes if the image file is not available or not
- accessible.</li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">openHandler()</codeph> method executes when the image file is first opened.</li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">progressHandler()</codeph> method executes when the image file starts to load and
- again when the image is finished loading.</li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">unLoadHandler()</codeph> method executes when the image is unloaded by using the
- <codeph class="+ topic/ph pr-d/codeph ">unload()</codeph> method when the user clicks the image.</li></ul>
- </li></ol>
- <p class="- topic/p "> Keep in mind the following requirements:</p>
-
- <ul class="- topic/ul "><li class="- topic/li ">This example requires that you place a file named Image.gif in the same directory as the compiled SWF file.
- Use an image that has an area that fits within the dimensions of the main SWF file.</li><li class="- topic/li ">Although this example makes use of all events available to the LoaderInfo object, most situations
- require only a subset. In particular, when loading only an image file, the <codeph class="+ topic/ph pr-d/codeph ">complete</codeph> event
- (and perhaps the <codeph class="+ topic/ph pr-d/codeph ">ioError</codeph> event) are sufficient when loading a local image.</li></ul>
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- package {
- import flash.display.Loader;
- import flash.display.Sprite;
- import flash.events.*;
- import flash.net.URLRequest;
- public class LoaderExample extends Sprite {
- private var url:String = "Image.gif";
- public function LoaderExample() {
- var loader:Loader = new Loader();
- configureListeners(loader.contentLoaderInfo);
- loader.addEventListener(MouseEvent.CLICK, clickHandler);
- var request:URLRequest = new URLRequest(url);
- loader.load(request);
- addChild(loader);
- }
- private function configureListeners(dispatcher:IEventDispatcher):void {
- dispatcher.addEventListener(Event.COMPLETE, completeHandler);
- dispatcher.addEventListener(HTTPStatusEvent.HTTP_STATUS, httpStatusHandler);
- dispatcher.addEventListener(Event.INIT, initHandler);
- dispatcher.addEventListener(IOErrorEvent.IO_ERROR, ioErrorHandler);
- dispatcher.addEventListener(Event.OPEN, openHandler);
- dispatcher.addEventListener(ProgressEvent.PROGRESS, progressHandler);
- dispatcher.addEventListener(Event.UNLOAD, unLoadHandler);
- }
- private function completeHandler(event:Event):void {
- trace("completeHandler: " + event);
- }
- private function httpStatusHandler(event:HTTPStatusEvent):void {
- trace("httpStatusHandler: " + event);
- }
- private function initHandler(event:Event):void {
- trace("initHandler: " + event);
- }
- private function ioErrorHandler(event:IOErrorEvent):void {
- trace("ioErrorHandler: " + event);
- }
- private function openHandler(event:Event):void {
- trace("openHandler: " + event);
- }
- private function progressHandler(event:ProgressEvent):void {
- trace("progressHandler: bytesLoaded=" + event.bytesLoaded + " bytesTotal=" + event.bytesTotal);
- }
- private function unLoadHandler(event:Event):void {
- trace("unLoadHandler: " + event);
- }
- private function clickHandler(event:MouseEvent):void {
- trace("clickHandler: " + event);
- var loader:Loader = Loader(event.target);
- loader.unload();
- }
- }
- }
- </codeblock></example></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#LoaderInfo" class="- topic/link "><linktext class="- topic/linktext ">flash.display.LoaderInfo</linktext></link><link href="flash.net.xml#URLLoader" class="- topic/link "><linktext class="- topic/linktext ">flash.net.URLLoader</linktext></link><link href="flash.display.xml#DisplayObject" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObject</linktext></link></related-links><apiConstructor id="flash.display:Loader:Loader" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation apiOperation/apiConstructor"><apiName class="- topic/title reference/title apiRef/apiName ">Loader</apiName><shortdesc class="- topic/shortdesc ">
- Creates a Loader object that you can use to load files, such as SWF, JPEG, GIF, or PNG files.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata><asCustoms class="+ topic/metadata adobe-api-d/asCustoms "><internal>Need wording on parent/child relationships, root DisplayObjects, and so on.
-
- </internal></asCustoms></prolog><apiConstructorDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail apiOperation/apiConstructorDetail"><apiConstructorDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiConstructorDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/></apiConstructorDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Creates a Loader object that you can use to load files, such as SWF, JPEG, GIF, or PNG files.
- Call the <codeph class="+ topic/ph pr-d/codeph ">load()</codeph> method to load the asset as a child of the Loader instance.
- You can then add the Loader object to the display list (for instance, by using the
- <codeph class="+ topic/ph pr-d/codeph ">addChild()</codeph> method of a DisplayObjectContainer instance).
- The asset appears on the Stage as it loads.
-
- <p class="- topic/p ">You can also use a Loader instance "offlist," that is without adding it to a display object
- container on the display list. In this mode, the Loader instance might be used to load a SWF file
- that contains additional modules of an application. </p>
-
- <p class="- topic/p ">To detect when the SWF file is finished loading, you can use the events of the LoaderInfo
- object associated with the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> property of the Loader object.
- At that point, the code in the module SWF file can be executed to initialize and start the module.
- In the offlist mode, a Loader instance might also be used to load a SWF file that contains components or
- media assets. Again, you can use the LoaderInfo object event notifications to detect when the
- components are finished loading. At that point, the application can start using the components
- and media assets in the library of the SWF file by instantiating the ActionScript 3.0 classes that represent
- those components and assets.</p>
-
- <p class="- topic/p ">To determine the status of a Loader object, monitor the following events that the LoaderInfo
- object associated with the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> property of the Loader object:</p>
-
- <ul class="- topic/ul "><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">open</codeph> event is dispatched when loading begins.</li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">ioError</codeph> or <codeph class="+ topic/ph pr-d/codeph ">securityError</codeph> event is dispatched if the file
- cannot be loaded or if an error occured during the load process. </li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">progress</codeph> event fires continuously while the file is being loaded.</li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">complete</codeph> event is dispatched when a file completes downloading, but before
- the loaded movie clip's methods and properties are available. </li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">init</codeph> event is dispatched after the properties and methods of the loaded SWF file
- are accessible, so you can begin manipulating the loaded SWF file.
- This event is dispatched before the <codeph class="+ topic/ph pr-d/codeph ">complete</codeph> handler. In streaming SWF files,
- the <codeph class="+ topic/ph pr-d/codeph ">init</codeph> event can occur significantly earlier than the <codeph class="+ topic/ph pr-d/codeph ">complete</codeph> event.
- For most purposes, use the <codeph class="+ topic/ph pr-d/codeph ">init</codeph> handler.</li></ul>
-
- </apiDesc></apiConstructorDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Loader/load()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Loader.load()</linktext></link><link href="flash.display.xml#LoaderInfo" class="- topic/link "><linktext class="- topic/linktext ">flash.display.LoaderInfo</linktext></link></related-links></apiConstructor><apiOperation id="flash.display:Loader:close" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">close</apiName><shortdesc class="- topic/shortdesc ">
- Cancels a load() method operation that is currently in progress for the Loader instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Cancels a <codeph class="+ topic/ph pr-d/codeph ">load()</codeph> method operation that is currently in progress for the Loader instance.
-
- </apiDesc></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Loader/load()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Loader.load()</linktext></link></related-links></apiOperation><apiOperation id="flash.display:Loader:loadBytes" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">loadBytes</apiName><shortdesc class="- topic/shortdesc ">
- Loads from binary data stored in a ByteArray object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If the <codeph class="+ topic/ph pr-d/codeph ">length</codeph> property of the ByteArray object is not
- greater than 0.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If the <codeph class="+ topic/ph pr-d/codeph ">checkPolicyFile</codeph> or <codeph class="+ topic/ph pr-d/codeph ">securityDomain</codeph>
- property of the <codeph class="+ topic/ph pr-d/codeph ">context</codeph> parameter are non-null.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">IllegalOperationError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.errors:IllegalOperationError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If the <codeph class="+ topic/ph pr-d/codeph ">requestedContentParent</codeph> property of the <codeph class="+ topic/ph pr-d/codeph ">context</codeph> parameter
- is a <codeph class="+ topic/ph pr-d/codeph ">Loader</codeph>.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">IllegalOperationError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.errors:IllegalOperationError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If the <codeph class="+ topic/ph pr-d/codeph ">LoaderContext.parameters</codeph> parameter is
- set to non-null and has some values which are not Strings.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">IllegalOperationError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.errors:IllegalOperationError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If the provided <codeph class="+ topic/ph pr-d/codeph ">applicationDomain</codeph> property of the
- <codeph class="+ topic/ph pr-d/codeph ">context</codeph> property is from a disallowed domain.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">SecurityError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">SecurityError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">You cannot connect to commonly reserved ports.
- For a complete list of blocked ports, see "Restricting Networking APIs" in the
- <i class="+ topic/ph hi-d/i ">ActionScript 3.0 Developer's Guide</i>.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">SecurityError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">SecurityError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">bytes</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.utils:ByteArray</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A ByteArray object. The contents of the ByteArray can be
- any of the file formats supported by the Loader class: SWF, GIF, JPEG, or PNG.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">context</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.system:LoaderContext</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A LoaderContext object. Only the <codeph class="+ topic/ph pr-d/codeph ">applicationDomain</codeph> property
- of the LoaderContext object applies; the <codeph class="+ topic/ph pr-d/codeph ">checkPolicyFile</codeph> and <codeph class="+ topic/ph pr-d/codeph ">securityDomain</codeph>
- properties of the LoaderContext object do not apply.
-
- <p class="- topic/p ">If the <codeph class="+ topic/ph pr-d/codeph ">context</codeph> parameter is not
- specified or refers to a null object, the content is loaded into the current security domain— a
- process referred to as "import loading" in Flash Player security documentation. Specifically,
- if the loading SWF file trusts the remote SWF by incorporating the remote SWF into its code,
- then the loading SWF can import it directly into its own security domain.</p>
-
- <p class="- topic/p ">For more information related to security, see the Flash Player Developer Center Topic:
- <xref href="http://www.adobe.com/go/devnet_security_en" scope="external" class="- topic/xref ">Security</xref>.</p>
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Loads from binary data stored in a ByteArray object.
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">loadBytes()</codeph> method is asynchronous. You must wait for the "init" event before
- accessing the properties of a loaded object.</p>
-
- <p class="- topic/p ">When you use this method, consider the Flash Player security model,
- which is described in the Loader class description. </p>
-
- </apiDesc></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.utils.xml#ByteArray" class="- topic/link "><linktext class="- topic/linktext ">flash.utils.ByteArray</linktext></link><link href="flash.system.xml#LoaderContext/applicationDomain" class="- topic/link "><linktext class="- topic/linktext ">flash.system.LoaderContext.applicationDomain</linktext></link></related-links><adobeApiEvent id="flash.display:Loader:loadBytes_asyncError" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">asyncError</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:AsyncErrorEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object if the
- <codeph class="+ topic/ph pr-d/codeph ">LoaderContext.requestedContentParent</codeph> property has been specified and it is not possible to add the
- loaded content as a child to the specified DisplayObjectContainer. This could happen if the loaded content is a
- <codeph class="+ topic/ph pr-d/codeph ">flash.display.AVM1Movie</codeph> or if the <codeph class="+ topic/ph pr-d/codeph ">addChild()</codeph> call to the requestedContentParent throws
- an error.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object if the
- LoaderContext.requestedContentParent property has been specified and it is not possible to add the
- loaded content as a child to the specified DisplayObjectContainer.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadBytes_complete" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">complete</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when the operation is
- complete. The <codeph class="+ topic/ph pr-d/codeph ">complete</codeph> event is always dispatched after the <codeph class="+ topic/ph pr-d/codeph ">init</codeph> event.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when the operation is
- complete.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadBytes_init" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">init</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when the properties and methods
- of the loaded data are accessible. The <codeph class="+ topic/ph pr-d/codeph ">init</codeph> event always precedes the <codeph class="+ topic/ph pr-d/codeph ">complete</codeph>
- event.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when the properties and methods
- of the loaded data are accessible.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadBytes_ioError" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">ioError</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:IOErrorEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when the runtime cannot parse
- the data in the byte array.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when the runtime cannot parse
- the data in the byte array.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadBytes_open" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">open</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when the operation starts.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when the operation starts.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadBytes_progress" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">progress</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:ProgressEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object as data is transfered in memory.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object as data is transfered in memory.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadBytes_securityError" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">securityError</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:SecurityErrorEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object if the
- <codeph class="+ topic/ph pr-d/codeph ">LoaderContext.requestedContentParent</codeph> property has been specified and the security sandbox
- of the <codeph class="+ topic/ph pr-d/codeph ">LoaderContext.requestedContentParent</codeph> does not have access to the loaded SWF.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object if the
- LoaderContext.requestedContentParent property has been specified and the security sandbox
- of the LoaderContext.requestedContentParent does not have access to the loaded SWF.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadBytes_unload" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">unload</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when a loaded object is removed.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when a loaded object is removed.</shortdesc></adobeApiEvent></apiOperation><apiOperation id="flash.display:Loader:loadFilePromise" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">loadFilePromise</apiName><shortdesc class="- topic/shortdesc ">
- Loads an IFilePromise instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="2.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If the <codeph class="+ topic/ph pr-d/codeph ">requestedContentParent</codeph> property of the <codeph class="+ topic/ph pr-d/codeph ">context</codeph> parameter
- is a <codeph class="+ topic/ph pr-d/codeph ">Loader</codeph>.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">IllegalOperationError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.errors:IllegalOperationError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If the <codeph class="+ topic/ph pr-d/codeph ">LoaderContext.parameters</codeph> parameter is
- set to non-null and has some values which are not Strings.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">IllegalOperationError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.errors:IllegalOperationError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If the <codeph class="+ topic/ph pr-d/codeph ">IFilePromise</codeph> object passed as parameter is null
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">promise</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.desktop:IFilePromise</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A IFilePromise object. The data source of the object can be
- any of the file formats supported by the Loader class: SWF, GIF, JPEG, or PNG.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">context</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.system:LoaderContext</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A LoaderContext object. Only the <codeph class="+ topic/ph pr-d/codeph ">applicationDomain</codeph> property
- of the LoaderContext object applies; the <codeph class="+ topic/ph pr-d/codeph ">checkPolicyFile</codeph> and <codeph class="+ topic/ph pr-d/codeph ">securityDomain</codeph>
- properties of the LoaderContext object do not apply.
-
- <p class="- topic/p ">If the <codeph class="+ topic/ph pr-d/codeph ">context</codeph> parameter is not
- specified or refers to a null object, the content is loaded into the current security domain— a
- process referred to as "import loading" in Flash Player security documentation. Specifically,
- if the loading SWF file trusts the remote SWF by incorporating the remote SWF into its code,
- then the loading SWF can import it directly into its own security domain.</p>
-
- <p class="- topic/p ">For more information related to security, see the Flash Player Developer Center Topic:
- <xref href="http://www.adobe.com/go/devnet_security_en" scope="external" class="- topic/xref ">Security</xref>.</p>
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Loads an IFilePromise instance.
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">loadFilePromise</codeph> method takes an <codeph class="+ topic/ph pr-d/codeph ">IFilePromise</codeph> object and
- loads the binary data. If the data is a progressive stream, such as a video wait for the "init"
- or progress events before accessing the properties of the loaded object. Otherwise, wait for
- the complete event to make sure that the data is fully loaded.</p>
-
- <p class="- topic/p ">When you use this method, consider the Flash Player security model,
- which is described in the Loader class description. </p>
-
- </apiDesc></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.media.xml#MediaPromise" class="- topic/link "><linktext class="- topic/linktext ">MediaPromise</linktext></link><link href="flash.media.xml#CameraRoll/browseForImage()" class="- topic/link "><linktext class="- topic/linktext ">CameraRoll.browseForImage()</linktext></link><link href="flash.media.xml#CameraUI" class="- topic/link "><linktext class="- topic/linktext ">CameraUI</linktext></link></related-links><adobeApiEvent id="flash.display:Loader:loadFilePromise_asyncError" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">asyncError</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:AsyncErrorEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object if the
- <codeph class="+ topic/ph pr-d/codeph ">LoaderContext.requestedContentParent</codeph> property has been specified and it is not possible to add the
- loaded content as a child to the specified DisplayObjectContainer. This could happen if the loaded content is a
- <codeph class="+ topic/ph pr-d/codeph ">flash.display.AVM1Movie</codeph> or if the <codeph class="+ topic/ph pr-d/codeph ">addChild()</codeph> call to the requestedContentParent throws
- an error.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object if the
- LoaderContext.requestedContentParent property has been specified and it is not possible to add the
- loaded content as a child to the specified DisplayObjectContainer.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadFilePromise_complete" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">complete</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when the operation is
- complete. The <codeph class="+ topic/ph pr-d/codeph ">complete</codeph> event is always dispatched after the <codeph class="+ topic/ph pr-d/codeph ">init</codeph> event.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when the operation is
- complete.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadFilePromise_init" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">init</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when the properties and methods
- of the loaded data are accessible. The <codeph class="+ topic/ph pr-d/codeph ">init</codeph> event always precedes the <codeph class="+ topic/ph pr-d/codeph ">complete</codeph>
- event.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when the properties and methods
- of the loaded data are accessible.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadFilePromise_ioError" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">ioError</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:IOErrorEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when the runtime cannot parse
- the data in the data source or if the data source stream is not readable.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when the runtime cannot parse
- the data in the data source or if the data source stream is not readable.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadFilePromise_open" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">open</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when the operation starts.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when the operation starts.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadFilePromise_progress" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">progress</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:ProgressEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object as data is transfered in memory.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object as data is transfered in memory.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadFilePromise_securityError" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">securityError</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:SecurityErrorEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object if the
- <codeph class="+ topic/ph pr-d/codeph ">LoaderContext.requestedContentParent</codeph> property has been specified and the security sandbox
- of the <codeph class="+ topic/ph pr-d/codeph ">LoaderContext.requestedContentParent</codeph> does not have access to the loaded SWF.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object if the
- LoaderContext.requestedContentParent property has been specified and the security sandbox
- of the LoaderContext.requestedContentParent does not have access to the loaded SWF.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:loadFilePromise_unload" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">unload</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when a loaded object is removed.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when a loaded object is removed.</shortdesc></adobeApiEvent></apiOperation><apiOperation id="flash.display:Loader:load" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">load</apiName><shortdesc class="- topic/shortdesc ">
- Loads a SWF, JPEG, progressive JPEG, unanimated GIF, or PNG file into an object that is a child of
- this Loader object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata><asCustoms class="+ topic/metadata adobe-api-d/asCustoms "><oldexample>The following example shows how to use the <code>MovieClipLoader.loadClip()</code>
- method by creating a handler for the <code>onLoadInit</code> event and then making the request.
- <p class="- topic/p ">You should either place the following code directly into a frame action on a Timeline, or
- paste it into a class that extends MovieClip. This code also expects an image named YourImage.jpg
- to exist in the same directory as the compiled SWF file.</p>
-
- <listing version="2.0">
- var container:MovieClip = createEmptyMovieClip("container", getNextHighestDepth());
- var mcLoader:MovieClipLoader = new MovieClipLoader();
- mcLoader.addListener(this);
- mcLoader.loadClip("YourImage.jpg", container);
-
- function onLoadInit(mc:MovieClip) {
- trace("onLoadInit: " + mc);
- }
- </listing>
-
- </oldexample></asCustoms></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The <codeph class="+ topic/ph pr-d/codeph ">digest</codeph> property of the <codeph class="+ topic/ph pr-d/codeph ">request</codeph> object is not
- <codeph class="+ topic/ph pr-d/codeph ">null</codeph>. You should only set the <codeph class="+ topic/ph pr-d/codeph ">digest</codeph> property of a URLRequest object
- when calling the <codeph class="+ topic/ph pr-d/codeph ">URLLoader.load()</codeph> method when loading a SWZ file (an Adobe
- platform component).
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">IOError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.errors:IOError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The value of <codeph class="+ topic/ph pr-d/codeph ">LoaderContext.securityDomain</codeph> must be either <codeph class="+ topic/ph pr-d/codeph ">null</codeph>
- or <codeph class="+ topic/ph pr-d/codeph ">SecurityDomain.currentDomain</codeph>. This reflects the fact that you can only
- place the loaded media in its natural security sandbox or your own (the latter requires a
- policy file).
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">SecurityError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">SecurityError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Local SWF files may not set LoaderContext.securityDomain to anything
- other than <codeph class="+ topic/ph pr-d/codeph ">null</codeph>. It is not permitted to import non-local media into a local
- sandbox, or to place other local media in anything other than its natural sandbox.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">SecurityError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">SecurityError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc "> You cannot connect to commonly reserved ports.
- For a complete list of blocked ports, see "Restricting Networking APIs" in the
- <i class="+ topic/ph hi-d/i ">ActionScript 3.0 Developer's Guide</i>.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">SecurityError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">SecurityError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If the <codeph class="+ topic/ph pr-d/codeph ">applicationDomain</codeph> or <codeph class="+ topic/ph pr-d/codeph ">securityDomain</codeph>
- properties of the <codeph class="+ topic/ph pr-d/codeph ">context</codeph> parameter are from a disallowed domain.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">SecurityError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">SecurityError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If a local SWF file is attempting to use the <codeph class="+ topic/ph pr-d/codeph ">securityDomain</codeph> property
- of the <codeph class="+ topic/ph pr-d/codeph ">context</codeph> parameter.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">SecurityError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">SecurityError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If the <codeph class="+ topic/ph pr-d/codeph ">requestedContentParent</codeph> property of the <codeph class="+ topic/ph pr-d/codeph ">context</codeph> parameter
- is a <codeph class="+ topic/ph pr-d/codeph ">Loader</codeph>.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">IllegalOperationError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.errors:IllegalOperationError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If the <codeph class="+ topic/ph pr-d/codeph ">LoaderContext.parameters</codeph> parameter is
- set to non-null and has some values which are not Strings.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">IllegalOperationError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.errors:IllegalOperationError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">request</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.net:URLRequest</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc "> The absolute or relative URL of the SWF, JPEG, GIF, or PNG file to be loaded. A
- relative path must be relative to the main SWF file. Absolute URLs must include the
- protocol reference, such as http:// or file:///. Filenames cannot include disk drive
- specifications.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">context</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.system:LoaderContext</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A LoaderContext object, which has properties that define the following:
-
- <ul class="- topic/ul "><li class="- topic/li ">Whether or not to check for the existence of a policy file
- upon loading the object</li><li class="- topic/li ">The ApplicationDomain for the loaded object</li><li class="- topic/li ">The SecurityDomain for the loaded object</li><li class="- topic/li ">The ImageDecodingPolicy for the loaded image object</li></ul>
- <p class="- topic/p ">If the <codeph class="+ topic/ph pr-d/codeph ">context</codeph> parameter is not specified or refers to a null object,
- the loaded content remains in its own security domain.</p>
-
- <p class="- topic/p ">For complete details, see the description of the properties in the
- <xref href="../system/LoaderContext.html" class="- topic/xref ">LoaderContext</xref> class.</p>
-
- </apiDesc></apiParam><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Loads a SWF file or image file into a DisplayObject that is a child of this Loader instance.
-
- </apiTipText></apiTipTexts></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Loads a SWF, JPEG, progressive JPEG, unanimated GIF, or PNG file into an object that is a child of
- this Loader object. If you load an animated GIF file, only the first frame is displayed.
- As the Loader object can contain only a single child, issuing a subsequent <codeph class="+ topic/ph pr-d/codeph ">load()</codeph>
- request terminates the previous request, if still pending, and commences a new load.
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note</b>:
- In AIR 1.5 and Flash Player 10, the maximum size for a loaded image is 8,191 pixels in width or height,
- and the total number of pixels cannot exceed 16,777,215 pixels. (So, if an loaded image is 8,191 pixels
- wide, it can only be 2,048 pixels high.) In Flash Player 9 and earlier and AIR 1.1 and earlier, the limitation
- is 2,880 pixels in height and 2,880 pixels in width.</p>
-
- <p class="- topic/p ">A SWF file or image loaded into a Loader object inherits the position, rotation, and scale
- properties of the parent display objects of the Loader object. </p>
-
- <p class="- topic/p ">Use the <codeph class="+ topic/ph pr-d/codeph ">unload()</codeph> method to remove movies or images loaded with this
- method, or to cancel a load operation that is in progress.</p>
-
- <p class="- topic/p ">You can prevent a SWF file from using this method by setting the <codeph class="+ topic/ph pr-d/codeph ">allowNetworking</codeph>
- parameter of the the <codeph class="+ topic/ph pr-d/codeph ">object</codeph> and <codeph class="+ topic/ph pr-d/codeph ">embed</codeph> tags in the HTML
- page that contains the SWF content.</p>
-
- <p class="- topic/p ">When you use this method, consider the Flash Player security model,
- which is described in the Loader class description. </p>
-
- <p class="- topic/p "> In Flash Player 10 and later, if you use a multipart Content-Type (for example "multipart/form-data")
- that contains an upload (indicated by a "filename" parameter in a "content-disposition" header within the POST body),
- the POST operation is subject to the security rules applied to uploads:</p>
- <ul class="- topic/ul "><li class="- topic/li ">The POST operation must be performed in response to a user-initiated action, such as a mouse click or key press.</li><li class="- topic/li ">If the POST operation is cross-domain (the POST target is not on the same server as the SWF file
- that is sending the POST request),
- the target server must provide a URL policy file that permits cross-domain access.</li></ul>
- <p class="- topic/p ">Also, for any multipart Content-Type, the syntax must be valid (according to the RFC2046 standard).
- If the syntax appears to be invalid, the POST operation is subject to the security rules applied to uploads.</p>
-
- <p class="- topic/p ">For more information related to security, see the Flash Player Developer Center Topic:
- <xref href="http://www.adobe.com/go/devnet_security_en" scope="external" class="- topic/xref ">Security</xref>.</p>
-
- </apiDesc></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Loader/contentLoaderInfo" class="- topic/link "><linktext class="- topic/linktext ">contentLoaderInfo</linktext></link><link href="flash.net.xml#URLRequest" class="- topic/link "><linktext class="- topic/linktext ">flash.net.URLRequest</linktext></link><link href="flash.display.xml#DisplayObject" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObject</linktext></link><link href="flash.display.xml#Loader/unload()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Loader.unload()</linktext></link><link href="flash.display.xml#LoaderInfo" class="- topic/link "><linktext class="- topic/linktext ">flash.display.LoaderInfo</linktext></link><link href="flash.system.xml#LoaderContext" class="- topic/link "><linktext class="- topic/linktext ">flash.system.LoaderContext</linktext></link></related-links><adobeApiEvent id="flash.display:Loader:load_asyncError" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">asyncError</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:AsyncErrorEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object if the
- <codeph class="+ topic/ph pr-d/codeph ">LoaderContext.requestedContentParent</codeph> property has been specified and it is not possible to add the
- loaded content as a child to the specified DisplayObjectContainer. This could happen if the loaded content is a
- <codeph class="+ topic/ph pr-d/codeph ">flash.display.AVM1Movie</codeph> or if the <codeph class="+ topic/ph pr-d/codeph ">addChild()</codeph> call to the requestedContentParent throws
- an error.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object if the
- LoaderContext.requestedContentParent property has been specified and it is not possible to add the
- loaded content as a child to the specified DisplayObjectContainer.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:load_complete" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">complete</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when the file has
- completed loading. The <codeph class="+ topic/ph pr-d/codeph ">complete</codeph> event is always dispatched after the <codeph class="+ topic/ph pr-d/codeph ">init</codeph> event.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when the file has
- completed loading.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:load_httpStatus" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">httpStatus</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:HTTPStatusEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when a network
- request is made over HTTP and Flash Player can detect the HTTP status code.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when a network
- request is made over HTTP and Flash Player can detect the HTTP status code.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:load_init" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">init</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when the properties and methods
- of the loaded SWF file are accessible. The <codeph class="+ topic/ph pr-d/codeph ">init</codeph> event always precedes the <codeph class="+ topic/ph pr-d/codeph ">complete</codeph>
- event.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when the properties and methods
- of the loaded SWF file are accessible.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:load_ioError" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">ioError</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:IOErrorEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when an input or output
- error occurs that causes a load operation to fail.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when an input or output
- error occurs that causes a load operation to fail.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:load_open" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">open</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when the loading operation starts.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when the loading operation starts.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:load_progress" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">progress</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:ProgressEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object as data is received
- while load operation progresses.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object as data is received
- while load operation progresses.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:load_securityError" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">securityError</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:SecurityErrorEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object if a SWF file
- in the local-with-filesystem sandbox attempts to load content in the local-with-networking sandbox, or vice versa.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object if a SWF file
- in the local-with-filesystem sandbox attempts to load content in the local-with-networking sandbox, or vice versa.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:load_securityError" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">securityError</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:SecurityErrorEvent</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object if the
- <codeph class="+ topic/ph pr-d/codeph ">LoaderContext.requestedContentParent</codeph> property has been specified and the security sandbox
- of the <codeph class="+ topic/ph pr-d/codeph ">LoaderContext.requestedContentParent</codeph> does not have access to the loaded SWF.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object if the
- LoaderContext.requestedContentParent property has been specified and the security sandbox
- of the LoaderContext.requestedContentParent does not have access to the loaded SWF.</shortdesc></adobeApiEvent><adobeApiEvent id="flash.display:Loader:load_unload" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">unload</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched by the <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> object when a loaded object is removed.
-
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched by the contentLoaderInfo object when a loaded object is removed.</shortdesc></adobeApiEvent></apiOperation><apiOperation id="flash.display:Loader:unloadAndStop" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">unloadAndStop</apiName><shortdesc class="- topic/shortdesc ">
- Attempts to unload child SWF file contents and stops the execution of commands from loaded SWF files.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">gc</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">true</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Provides a hint to the garbage collector to run on the child SWF objects (<codeph class="+ topic/ph pr-d/codeph ">true</codeph>) or not (<codeph class="+ topic/ph pr-d/codeph ">false</codeph>).
- If you are unloading many objects asynchronously, setting the <codeph class="+ topic/ph pr-d/codeph ">gc</codeph> paramter to <codeph class="+ topic/ph pr-d/codeph ">false</codeph> might improve
- application performance. However, if the parameter is set to
- <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, media and display objects of the child SWF file might persist in memory after running the
- <codeph class="+ topic/ph pr-d/codeph ">unloadAndStop()</codeph> command.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Attempts to unload child SWF file contents and stops the execution of commands from loaded SWF files.
- This method attempts to unload SWF files
- that were loaded using <codeph class="+ topic/ph pr-d/codeph ">Loader.load()</codeph> or <codeph class="+ topic/ph pr-d/codeph ">Loader.loadBytes()</codeph> by removing references to EventDispatcher,
- NetConnection, Timer, Sound, or Video objects of the child SWF file. As a result, the following occurs for the child SWF file
- and the child SWF file's display list:
- <ul class="- topic/ul "><li class="- topic/li ">Sounds are stopped.</li><li class="- topic/li ">Stage event listeners are removed.</li><li class="- topic/li ">Event listeners for <codeph class="+ topic/ph pr-d/codeph ">enterFrame</codeph>, <codeph class="+ topic/ph pr-d/codeph ">frameConstructed</codeph>, <codeph class="+ topic/ph pr-d/codeph ">exitFrame</codeph>,
- <codeph class="+ topic/ph pr-d/codeph ">activate</codeph> and <codeph class="+ topic/ph pr-d/codeph ">deactivate</codeph> are removed.</li><li class="- topic/li ">Timers are stopped.</li><li class="- topic/li ">Camera and Microphone instances are detached</li><li class="- topic/li ">Movie clips are stopped.</li></ul>
- </apiDesc></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObject</linktext></link><link href="flash.display.xml#Loader/load()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Loader.load()</linktext></link></related-links></apiOperation><apiOperation id="flash.display:Loader:unload" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">unload</apiName><shortdesc class="- topic/shortdesc ">
- Removes a child of this Loader object that was loaded by using the load() method.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata><asCustoms class="+ topic/metadata adobe-api-d/asCustoms "><internal>The funky-looking code formatting above is intentional to work around a bug!
- </internal></asCustoms></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Removes a child of this Loader object that was loaded by using the <codeph class="+ topic/ph pr-d/codeph ">load()</codeph> method.
- The <codeph class="+ topic/ph pr-d/codeph ">property</codeph> of the associated LoaderInfo object is reset to <codeph class="+ topic/ph pr-d/codeph ">null</codeph>.
- The child is not necessarily destroyed because other objects might have references to it; however,
- it is no longer a child of the Loader object.
-
- <p class="- topic/p ">As a best practice, before you unload a child SWF file, you should explicitly
- close any streams in the child SWF file's objects, such as LocalConnection, NetConnection,
- NetStream, and Sound objects. Otherwise, audio in the child SWF file might continue to play, even
- though the child SWF file was unloaded. To close streams in the child SWF file, add an event listener
- to the child that listens for the <codeph class="+ topic/ph pr-d/codeph ">unload</codeph> event. When the parent calls
- <codeph class="+ topic/ph pr-d/codeph ">Loader.unload()</codeph>, the <codeph class="+ topic/ph pr-d/codeph ">unload</codeph> event is dispatched to the child.
- The following code shows how you might do this:</p>
- <pre xml:space="preserve" class="- topic/pre ">
- function closeAllStreams(evt:Event) {
- myNetStream.close();
- mySound.close();
- myNetConnection.close();
- myLocalConnection.close();
- }
- myMovieClip.loaderInfo.addEventListener(Event.UNLOAD, closeAllStreams);</pre>
-
- </apiDesc></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Loader/load()" class="- topic/link "><linktext class="- topic/linktext ">Loader.load()</linktext></link><link href="flash.media.xml#Sound/close()" class="- topic/link "><linktext class="- topic/linktext ">flash.media.Sound.close()</linktext></link><link href="flash.net.xml#LocalConnection/close()" class="- topic/link "><linktext class="- topic/linktext ">flash.net.LocalConnection.close()</linktext></link><link href="flash.net.xml#NetConnection/close()" class="- topic/link "><linktext class="- topic/linktext ">flash.net.NetConnection.close()</linktext></link><link href="flash.net.xml#NetStream/close()" class="- topic/link "><linktext class="- topic/linktext ">flash.net.NetStream.close()</linktext></link><link href="../../operators.html#delete" class="- topic/link "><linktext class="- topic/linktext ">delete operator</linktext></link></related-links></apiOperation><apiValue id="flash.display:Loader:contentLoaderInfo:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">contentLoaderInfo</apiName><shortdesc class="- topic/shortdesc ">
- Returns a LoaderInfo object corresponding to the object being loaded.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:LoaderInfo</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Returns a LoaderInfo object corresponding to the object being loaded. LoaderInfo objects
- are shared between the Loader object and the loaded content object. The LoaderInfo object
- supplies loading progress information and statistics about the loaded file.
-
- <p class="- topic/p ">Events related to the load are dispatched by the LoaderInfo object referenced by the
- <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph> property of the Loader object. The <codeph class="+ topic/ph pr-d/codeph ">contentLoaderInfo</codeph>
- property is set to a valid LoaderInfo object, even before the content is loaded, so that you can add
- event listeners to the object prior to the load.</p>
-
- <p class="- topic/p ">To detect uncaught errors that happen in a loaded SWF, use the
- <codeph class="+ topic/ph pr-d/codeph ">Loader.uncaughtErrorEvents</codeph> property, not the
- <codeph class="+ topic/ph pr-d/codeph ">Loader.contentLoaderInfo.uncaughtErrorEvents</codeph> property.</p>
-
- </apiDesc><example conref="examples\Loader_contentLoaderInfo.as" class="- topic/example "> The following example shows how you can load and position an image in ActionScript 3.0 using the Loader class and the complete event on the Loader object's contentLoaderInfo property.
- Example provided by
- <xref href="http://actionscriptexamples.com/2008/03/03/positioning-a-dynamically-loaded-image-in-actionscript-20-and-actionscript-30-using-the-moviecliploader-class-and-loader-class/" scope="_mmexternal" class="- topic/xref ">ActionScriptExamples.com</xref>.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- var url:String = "http://www.helpexamples.com/flash/images/image2.jpg";
- var urlRequest:URLRequest = new URLRequest(url);
- var loader:Loader = new Loader();
- loader.contentLoaderInfo.addEventListener(Event.COMPLETE, loader_complete);
- loader.load(urlRequest);
- addChild(loader);
-
- function loader_complete(evt:Event):void {
- var target_mc:Loader = evt.currentTarget.loader as Loader;
- target_mc.x = (stage.stageWidth - target_mc.width) / 2;
- target_mc.y = (stage.stageHeight - target_mc.height) / 2;
- }
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#LoaderInfo" class="- topic/link "><linktext class="- topic/linktext ">flash.display.LoaderInfo</linktext></link></related-links></apiValue><apiValue id="flash.display:Loader:content:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">content</apiName><shortdesc class="- topic/shortdesc ">
- Contains the root display object of the SWF file or image (JPG, PNG, or GIF)
- file that was loaded by using the load() or loadBytes() methods.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:DisplayObject</apiValueClassifier><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The loaded SWF file or image file belongs to a security
- sandbox to which you do not have access. For a loaded SWF file, you can avoid this situation by having
- the file call the <codeph class="+ topic/ph pr-d/codeph ">Security.allowDomain()</codeph> method or by having the loading file specify a
- <codeph class="+ topic/ph pr-d/codeph ">loaderContext</codeph> parameter with its <codeph class="+ topic/ph pr-d/codeph ">securityDomain</codeph> property set to
- <codeph class="+ topic/ph pr-d/codeph ">SecurityDomain.currentDomain</codeph> when you call the <codeph class="+ topic/ph pr-d/codeph ">load()</codeph> or
- <codeph class="+ topic/ph pr-d/codeph ">loadBytes()</codeph> method.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">SecurityError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">SecurityError</apiOperationClassifier></apiException></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Contains the root display object of the SWF file or image (JPG, PNG, or GIF)
- file that was loaded by using the <codeph class="+ topic/ph pr-d/codeph ">load()</codeph> or <codeph class="+ topic/ph pr-d/codeph ">loadBytes()</codeph> methods.
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObject</linktext></link><link href="flash.display.xml#Loader/load()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Loader.load()</linktext></link></related-links></apiValue><apiValue id="flash.display:Loader:uncaughtErrorEvents:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">uncaughtErrorEvents</apiName><shortdesc class="- topic/shortdesc ">
- An object that dispatches an uncaughtError event when an unhandled error
- occurs in the SWF that's loaded by this Loader object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.events:UncaughtErrorEvents</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- An object that dispatches an <codeph class="+ topic/ph pr-d/codeph ">uncaughtError</codeph> event when an unhandled error
- occurs in the SWF that's loaded by this Loader object.
- An uncaught error happens when an error is
- thrown outside of any <codeph class="+ topic/ph pr-d/codeph ">try..catch</codeph> blocks or when an ErrorEvent
- object is dispatched with no registered listeners.
-
- <p class="- topic/p ">Note that a Loader object's <codeph class="+ topic/ph pr-d/codeph ">uncaughtErrorEvents</codeph> property
- dispatches events that bubble through it, not events that it dispatches directly.
- It never dispatches an <codeph class="+ topic/ph pr-d/codeph ">uncaughtErrorEvent</codeph> in the target phase. It only
- dispatches the event in the capture and bubbling phases. To detect an uncaught error
- in the current SWF (the SWF in which the Loader object
- is defined) use the <codeph class="+ topic/ph pr-d/codeph ">LoaderInfo.uncaughtErrorEvents</codeph> property instead.</p>
-
- <p class="- topic/p ">If the content loaded by the Loader object is an AVM1 (ActionScript 2) SWF file,
- uncaught errors in the AVM1 SWF file do not result in an <codeph class="+ topic/ph pr-d/codeph ">uncaughtError</codeph>
- event.</p>
-
- </apiDesc><example conref="examples\Loader.uncaughtErrorEvents.1.as" class="- topic/example "> The following example demonstrates the use of an uncaught error event
- handler to detect uncaught errors in a loaded SWF. The example defines
- an <codeph class="+ topic/ph pr-d/codeph ">uncaughtError</codeph> event handler to detect uncaught errors.
-
- <p class="- topic/p ">In the constructor, the code creates a Loader object and registers a listener for
- the <codeph class="+ topic/ph pr-d/codeph ">uncaughtError</codeph> event dispatched by the Loader object's
- <codeph class="+ topic/ph pr-d/codeph ">uncaughtErrorEvents</codeph> property.</p>
-
- <p class="- topic/p ">In the <codeph class="+ topic/ph pr-d/codeph ">uncaughtErrorHandler()</codeph> method, the code checks the data type of
- the <codeph class="+ topic/ph pr-d/codeph ">error</codeph> property and responds accordingly.</p>
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- package
- {
- import flash.display.Loader;
- import flash.display.Sprite;
- import flash.events.ErrorEvent;
- import flash.events.UncaughtErrorEvent;
- import flash.net.URLRequest;
- public class LoaderUncaughtErrorEventExample extends Sprite
- {
- private var ldr:Loader;
-
- public function LoaderUncaughtErrorEventExample()
- {
- ldr = new Loader();
- ldr.load(new URLRequest("child.swf"));
- ldr.uncaughtErrorEvents.addEventListener(UncaughtErrorEvent.UNCAUGHT_ERROR, uncaughtErrorHandler);
- }
-
- private function uncaughtErrorHandler(event:UncaughtErrorEvent):void
- {
- if (event.error is Error)
- {
- var error:Error = event.error as Error;
- // do something with the error
- }
- else if (event.error is ErrorEvent)
- {
- var errorEvent:ErrorEvent = event.error as ErrorEvent;
- // do something with the error
- }
- else
- {
- // a non-Error, non-ErrorEvent type was thrown and uncaught
- }
- }
- }
- }
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.events.xml#UncaughtErrorEvent" class="- topic/link "><linktext class="- topic/linktext ">UncaughtErrorEvent</linktext></link><link href="flash.display.xml#LoaderInfo/uncaughtErrorEvents" class="- topic/link "><linktext class="- topic/linktext ">LoaderInfo.uncaughtErrorEvents</linktext></link></related-links></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:NativeMenuItem" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">NativeMenuItem</apiName><shortdesc class="- topic/shortdesc ">
- The NativeMenuItem class represents a single item in a menu.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">flash.events:EventDispatcher</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The NativeMenuItem class represents a single item in a menu.
-
- <p class="- topic/p ">A menu item can be a command, a submenu, or a separator line:</p>
-
- <ul class="- topic/ul "><li class="- topic/li ">To create a command item, call the NativeMenuItem constructor, passing in a
- string for the label and <codeph class="+ topic/ph pr-d/codeph ">false</codeph> for the <codeph class="+ topic/ph pr-d/codeph ">isSeparator</codeph>
- parameter.</li><li class="- topic/li ">To create a submenu, create a command item for the parent menu and
- assign the NativeMenu object of the submenu to the item's <codeph class="+ topic/ph pr-d/codeph ">submenu</codeph>
- property. You can also call the <codeph class="+ topic/ph pr-d/codeph ">addSubmenu()</codeph> method of the
- parent NativeMenu object to create the item and set the <codeph class="+ topic/ph pr-d/codeph ">submenu</codeph>
- property at the same time.</li><li class="- topic/li ">To create a separator, call the NativeMenuItem constructor, passing in an empty
- string for the label and <codeph class="+ topic/ph pr-d/codeph ">true</codeph> for the <codeph class="+ topic/ph pr-d/codeph ">isSeparator</codeph>
- parameter.</li></ul>
-
- <p class="- topic/p ">Listen for <codeph class="+ topic/ph pr-d/codeph ">select</codeph> events on an item or a parent menu to detect when a
- menu command is selected. Neither submenus nor separators dispatch
- select events. Listen for <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> events to determine when
- a menu item is about to be displayed or activated through a key equivalent.</p>
-
- </apiDesc></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#NativeMenu" class="- topic/link "><linktext class="- topic/linktext ">flash.display.NativeMenu</linktext></link><link href="flash.display.xml#NativeMenu/addSubmenu()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.NativeMenu.addSubmenu()</linktext></link></related-links><adobeApiEvent id="flash.display:NativeMenuItem_flash.events.Event.PREPARING_preparing" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">preparing</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched by this NativeMenuItem object when its key equivalent is pressed and immediately before the containing menu is displayed.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="2.6" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.PREPARING</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched by this NativeMenuItem object when its key equivalent is pressed and immediately before the containing menu is displayed.
-
- <p class="- topic/p ">Listen to this event to update the item either before the containing menu is displayed, or when its key
- equivalent is pressed by the user. The <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event is dispatched before the key equivalent
- is fully evaluated. You can enable, disable, or remove the item from the menu in the <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event handler
- and those changes will be in effect when the key equivalent is processed. For example, if you remove or disable this
- menu item, then the sequence of events is effectively canceled
- and no <codeph class="+ topic/ph pr-d/codeph ">select</codeph> event is dispatched.
- A <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event is also dispatched by the other items in a menu. </p>
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event supersedes the <codeph class="+ topic/ph pr-d/codeph ">displaying</codeph> event and provides additional functionality. Listen for the
- <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event or the <codeph class="+ topic/ph pr-d/codeph ">displaying</codeph> event, but not both. </p>
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:NativeMenuItem_flash.events.Event.DISPLAYING_displaying" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">displaying</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched by this NativeMenuItem object immediately before the
- menu containing the item is displayed.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.DISPLAYING</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched by this NativeMenuItem object immediately before the
- menu containing the item is displayed.
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event supersedes the <codeph class="+ topic/ph pr-d/codeph ">displaying</codeph> event and provides additional functionality. Listen for the
- <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event or the <codeph class="+ topic/ph pr-d/codeph ">displaying</codeph> event, but not both. </p>
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:NativeMenuItem_flash.events.Event.SELECT_select" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">select</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched whenever a menu item is selected by the user.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.SELECT</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched whenever a menu item is selected by the user.
-
- <p class="- topic/p ">A <codeph class="+ topic/ph pr-d/codeph ">select</codeph> event <i class="+ topic/ph hi-d/i ">bubbles</i> from this item to its containing menu and on up
- through the parent menu chain to the root menu object. The <codeph class="+ topic/ph pr-d/codeph ">target</codeph>
- property of the event object references this NativeMenuItem object;
- the <codeph class="+ topic/ph pr-d/codeph ">currentTarget</codeph> property references the dispatching
- object (either this NativeMenuItem or an ancestral NativeMenu object).</p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> If the window containing the menu is in fullscreen mode
- (<codeph class="+ topic/ph pr-d/codeph ">stage.displayState == StageDisplayState.FULL_SCREEN</codeph>),
- the NativeMenuItem object does <i class="+ topic/ph hi-d/i ">not</i> dispatch a <codeph class="+ topic/ph pr-d/codeph ">select</codeph> event
- when the user enters a keyboard equivalent for a menu item.</p>
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><apiConstructor id="flash.display:NativeMenuItem:NativeMenuItem" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation apiOperation/apiConstructor"><apiName class="- topic/title reference/title apiRef/apiName ">NativeMenuItem</apiName><shortdesc class="- topic/shortdesc ">
- Creates a new NativeMenuItem object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiConstructorDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail apiOperation/apiConstructorDetail"><apiConstructorDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiConstructorDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">label</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">String</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData "/><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The display label for the item, or an empty string for separators.
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">isSeparator</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">false</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph> to create a separator; set to
- <codeph class="+ topic/ph pr-d/codeph ">false</codeph> otherwise.
-
- </apiDesc></apiParam></apiConstructorDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Creates a new NativeMenuItem object.
-
- <p class="- topic/p ">To create a menu command, set the <codeph class="+ topic/ph pr-d/codeph ">label</codeph> parameter to a
- string containing the display label and set <codeph class="+ topic/ph pr-d/codeph ">isSeparator</codeph>
- to <codeph class="+ topic/ph pr-d/codeph ">false</codeph>.</p>
-
- <p class="- topic/p ">To create a submenu command, create a command item and then assign the
- NativeMenu object for the submenu to the item's <codeph class="+ topic/ph pr-d/codeph ">submenu</codeph>
- property. Add the item to the parent menu.</p>
-
- <p class="- topic/p ">To create a separator, set the <codeph class="+ topic/ph pr-d/codeph ">label</codeph> parameter to an empty
- string and set <codeph class="+ topic/ph pr-d/codeph ">isSeparator</codeph> to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.</p>
-
- <p class="- topic/p ">Add and remove items from a menu using the NativeMenu <codeph class="+ topic/ph pr-d/codeph ">addItem()</codeph>
- and <codeph class="+ topic/ph pr-d/codeph ">removeItem()</codeph> methods.</p>
-
- </apiDesc></apiConstructorDetail><related-links class="- topic/related-links "><link href="flash.display.xml#NativeMenu/addSubmenu()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.NativeMenu.addSubmenu()</linktext></link></related-links></apiConstructor><apiOperation id="flash.display:NativeMenuItem:clone" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">clone</apiName><shortdesc class="- topic/shortdesc ">
- Creates a copy of the NativeMenuItem object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier></apiReturn></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Creates a copy of the NativeMenuItem object.
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenuItem:toString" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">toString</apiName><shortdesc class="- topic/shortdesc ">
- Returns a string containing all the properties of the NativeMenuItem object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiIsOverride class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiIsOverride "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A string containing all the properties of the Event object.
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">String</apiOperationClassifier></apiReturn></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Returns a string containing all the properties of the NativeMenuItem object.
-
- </apiDesc></apiOperationDetail></apiOperation><apiValue id="flash.display:NativeMenuItem:checked:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">checked</apiName><shortdesc class="- topic/shortdesc ">
- Controls whether this menu item displays a checkmark.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Controls whether this menu item displays a checkmark.
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:NativeMenuItem:data:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">data</apiName><shortdesc class="- topic/shortdesc ">
- An arbitrary data object associated with this menu item.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Object</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- An arbitrary data object associated with this menu item.
-
- <p class="- topic/p ">You can assign any object to this property. The assigned object is
- not used by the menu system, but is available to event handling code
- (through the target property of the event object).
- By default, the value of this property is <codeph class="+ topic/ph pr-d/codeph ">null</codeph>.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:NativeMenuItem:enabled:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">enabled</apiName><shortdesc class="- topic/shortdesc ">
- Controls whether this menu item is enabled.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Controls whether this menu item is enabled.
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:NativeMenuItem:isSeparator:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">isSeparator</apiName><shortdesc class="- topic/shortdesc ">
- Reports whether this item is a menu separator line.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Reports whether this item is a menu separator line.
-
- <p class="- topic/p ">Create a separator line by setting the <codeph class="+ topic/ph pr-d/codeph ">isSeparator</codeph>
- parameter in the NativeMenuItem constructor to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:NativeMenuItem:keyEquivalentModifiers:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">keyEquivalentModifiers</apiName><shortdesc class="- topic/shortdesc ">
- The array of key codes for the key equivalent modifiers.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Array</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The array of key codes for the key equivalent modifiers.
-
- <p class="- topic/p ">Use the constants defined in the Keyboard class to specify the
- modifier key codes. Valid modifier keys include:</p>
- <ul class="- topic/ul "><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">Keyboard.ALTERNATE</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">Keyboard.COMMAND</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">Keyboard.CONTROL</codeph></li></ul>
-
- <p class="- topic/p ">If you do not assign any modifiers, then by default the <codeph class="+ topic/ph pr-d/codeph ">Keyboard.CONTROL</codeph> key is
- assigned on Windows or Linux and the <codeph class="+ topic/ph pr-d/codeph ">Keyboard.COMMAND</codeph> key is assigned on Mac OS X. If you
- do not want the key equivalent to include these modifiers, set this property to an empty array.</p>
-
- <p class="- topic/p ">If you assign an uppercase letter to the <codeph class="+ topic/ph pr-d/codeph ">keyEquivalent</codeph> property, the Shift key is
- used as a modifier automatically. Setting <codeph class="+ topic/ph pr-d/codeph ">keyEquivalentModifier</codeph> to an empty array
- does not remove the Shift key as a modifier.</p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.ui.xml#Keyboard" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Keyboard</linktext></link></related-links></apiValue><apiValue id="flash.display:NativeMenuItem:keyEquivalent:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">keyEquivalent</apiName><shortdesc class="- topic/shortdesc ">
- The key equivalent for this menu item.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The key equivalent for this menu item.
-
- <p class="- topic/p ">Set the <codeph class="+ topic/ph pr-d/codeph ">keyEquivalent</codeph> with a lowercase letter to assign
- a shortcut without a Shift-key modifier. Set with an uppercase letter
- to assign a shortcut with the Shift-key modifier.</p>
-
- <p class="- topic/p ">By default, a key equivalent modifier (Ctrl on Windows or Linux and
- Command on Mac OS X) is included as part of the key equivalent.
- If you want the key equivalent to be a key with no modifier,
- set the <codeph class="+ topic/ph pr-d/codeph ">keyEquivalentModifiers</codeph> property to an
- empty array.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:NativeMenuItem:label:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">label</apiName><shortdesc class="- topic/shortdesc ">
- The display string of this menu item.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The display string of this menu item.
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:NativeMenuItem:menu:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">menu</apiName><shortdesc class="- topic/shortdesc ">
- The menu that contains this item.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:NativeMenu</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The menu that contains this item.
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:NativeMenuItem:mnemonicIndex:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">mnemonicIndex</apiName><shortdesc class="- topic/shortdesc ">
- The position of the mnemonic character in the menu item label.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">int</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The position of the mnemonic character in the menu item label.
-
- <p class="- topic/p ">The character at the specified position is the mnemonic
- character for the menu item. The index is zero-based, so the first
- character has an index of 0.</p>
-
- <p class="- topic/p ">This property is ignored on operating systems that do not use
- menu mnemonics.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:NativeMenuItem:name:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">name</apiName><shortdesc class="- topic/shortdesc ">
- The name of this menu item.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The name of this menu item.
-
- <p class="- topic/p ">The name value is not displayed and can be used as a
- locale-independent identifier. A name is not assigned automatically.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:NativeMenuItem:submenu:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">submenu</apiName><shortdesc class="- topic/shortdesc ">
- The submenu associated with this menu item.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:NativeMenu</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The submenu associated with this menu item.
-
- <p class="- topic/p ">Assigning a NativeMenu object to this property changes the
- appearance and behavior of the menu item. A submenu item displays
- the submenu icon and no longer dispatches select events.</p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> Adding a menu as a submenu of itself (in a circular reference)
- can cause an application to hang.</p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#NativeMenu/addSubmenu()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.NativeMenu.addSubmenu()</linktext></link></related-links></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:NativeMenu" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">NativeMenu</apiName><shortdesc class="- topic/shortdesc ">
- The NativeMenu class contains methods and properties for defining native menus.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">flash.events:EventDispatcher</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The NativeMenu class contains methods and properties for defining native menus.
-
- <p class="- topic/p "><i class="+ topic/ph hi-d/i ">AIR profile support:</i> This feature is supported
- on all desktop operating systems, but is not supported on mobile devices or AIR for TV devices. You can test
- for support at run time using the <codeph class="+ topic/ph pr-d/codeph ">NativeMenu.isSupported</codeph> property. See
- <xref href="http://help.adobe.com/en_US/air/build/WS144092a96ffef7cc16ddeea2126bb46b82f-8000.html" class="- topic/xref ">
- AIR Profile Support</xref> for more information regarding API support across multiple profiles.</p>
-
- <p class="- topic/p ">A native menu is a menu that is controlled and drawn by the operating system rather than by your application.
- AIR supports the following types of native menus:</p>
-
- <ul class="- topic/ul "><li class="- topic/li "><b class="+ topic/ph hi-d/b ">Application menus</b> are supported on OS X. Use the <codeph class="+ topic/ph pr-d/codeph ">NativeApplication.supportsMenu</codeph> property to test whether
- application menus are supported on the host operating system. An application menu is displayed on the Menu bar at the top of the
- Mac desktop. OS X provides a default menu for every application, but many of the menu commands are not functional. You can add
- event listeners to the default items, replace individual menus and items, or even replace the default menu entirely.
- Access the application menu object using the NativeApplication <codeph class="+ topic/ph pr-d/codeph ">menu</codeph> property.</li><li class="- topic/li "><b class="+ topic/ph hi-d/b ">Window menus</b> are supported on Windows and Linux. Use the <codeph class="+ topic/ph pr-d/codeph ">NativeWindow.supportsMenu</codeph> property to
- test whether window menus are supported on the host operating system. A window menu is displayed below the window title bar. The area
- occupied by the menu is not part of the window stage. Applications cannot draw into this area. Assign a menu to a window using the
- NativeWindow <codeph class="+ topic/ph pr-d/codeph ">menu</codeph> property.</li><li class="- topic/li "><b class="+ topic/ph hi-d/b ">Dock icon menus</b> are supported on OS X. Use the <codeph class="+ topic/ph pr-d/codeph ">NativeApplication.supportsDockIcon</codeph> property to test whether
- dock icons are supported on the host operating system. Items in a dock icon menu are displayed above the default items provided by
- the operating system. The default items cannot be accessed by application code. Assign a menu to the <codeph class="+ topic/ph pr-d/codeph ">menu</codeph> property of
- the application's DockIcon object.</li><li class="- topic/li "><b class="+ topic/ph hi-d/b ">System tray icon menus</b> are supported on Windows and most Linux operating systems. Use the
- <codeph class="+ topic/ph pr-d/codeph ">NativeApplication.supportsSystemTrayIcon</codeph> property to test whether system tray icons are supported on the host
- operating system. A system tray icon menu is displayed in response to a right-click on the icon, in much the same fashion as
- a context menu. Assign a menu to the <codeph class="+ topic/ph pr-d/codeph ">menu</codeph> property of the application's SystemTrayIcon object.</li><li class="- topic/li "><b class="+ topic/ph hi-d/b ">Context menus</b> are supported on all operating systems. Context menus are displayed in response to a user interface event,
- such as a right-click or a command-click on an InteractiveObject displayed in the application. The UI mechanism for showing the menu
- varies by host operating system and hardware. Assign a menu to the <codeph class="+ topic/ph pr-d/codeph ">contextMenu</codeph> property of an
- InteractiveObject. In AIR, a context menu can be created with either the NativeMenu class or the ContextMenu class. In
- Flash Player, only the ContextMenu class can be used. ContextMenus in AIR do not have built-in items; a default context menu is
- not displayed.</li><li class="- topic/li "><b class="+ topic/ph hi-d/b ">Pop-up menus</b> are supported on all operating systems. Pop-up menus are functionally the same as context menus, but
- are displayed using the menu <codeph class="+ topic/ph pr-d/codeph ">display()</codeph> method rather than as a response to a user interface event. A pop-up
- menu is not attached to any other object. Simply create the native menu and call the <codeph class="+ topic/ph pr-d/codeph ">display()</codeph> method.</li></ul>
-
- <p class="- topic/p ">A menu object contains menu items. A menu item can represent a command, a submenu, or a separator line.
- Add menu items to a menu using the <codeph class="+ topic/ph pr-d/codeph ">addItem()</codeph> or <codeph class="+ topic/ph pr-d/codeph ">addItemAt()</codeph> method. The display order of the menu items
- matches the order of the items in the menu's <codeph class="+ topic/ph pr-d/codeph ">items</codeph> array.</p>
-
- <p class="- topic/p ">To create a submenu, add a menu item to the parent menu object. Assign the menu object representing
- the submenu to the <codeph class="+ topic/ph pr-d/codeph ">submenu</codeph> property of the matching menu item in the parent menu.</p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> The root menu of window and application menus must contain only submenu items; items
- that do not represent submenus may not be displayed and are contrary to user expectation for
- these types of menus.</p>
-
- <p class="- topic/p ">Menus dispatch <codeph class="+ topic/ph pr-d/codeph ">select</codeph> events when a command item in the menu or one of its
- submenus is selected. (Submenu and separator items are not selectable.) The
- <codeph class="+ topic/ph pr-d/codeph ">target</codeph> property of the event object references the
- selected item.</p>
-
- <p class="- topic/p ">Menus dispatch <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> events just before the menu is displayed and when a key equivalent attached
- to one of the items in the menu is pressed. You
- can use this event to update the contents of the menu based on the current
- state of the application.</p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> If you are using the Flex Framework, consider using the FlexNativeMenu class.
- It is typically easier to define menus declaratively in MXML than it is to write ActionScript code to create the menu
- structure item-by-item.</p>
-
-
-
- </apiDesc></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InteractiveObject/contextMenu" class="- topic/link "><linktext class="- topic/linktext ">flash.display.InteractiveObject.contextMenu</linktext></link><link href="flash.display.xml#NativeMenuItem" class="- topic/link "><linktext class="- topic/linktext ">flash.display.NativeMenuItem</linktext></link><link href="flash.display.xml#NativeWindow/menu" class="- topic/link "><linktext class="- topic/linktext ">flash.display.NativeWindow.menu</linktext></link><link href="flash.desktop.xml#DockIcon" class="- topic/link "><linktext class="- topic/linktext ">flash.desktop.DockIcon</linktext></link><link href="flash.desktop.xml#SystemTrayIcon" class="- topic/link "><linktext class="- topic/linktext ">flash.desktop.SystemTrayIcon</linktext></link><link href="flash.desktop.xml#NativeApplication/menu" class="- topic/link "><linktext class="- topic/linktext ">flash.desktop.NativeApplication.menu</linktext></link><link href="flash.desktop.xml#NativeApplication/icon" class="- topic/link "><linktext class="- topic/linktext ">flash.desktop.NativeApplication.icon</linktext></link><link href="" invalidHref="mx.controls.FlexNativeMenu.xml" class="- topic/link "><linktext class="- topic/linktext ">mx.controls.FlexNativeMenu</linktext></link></related-links><adobeApiEvent id="flash.display:NativeMenu_flash.events.Event.PREPARING_preparing" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">preparing</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched by the NativeMenu object when a key equivalent is pressed and immediately before the menu is displayed.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="2.6" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.PREPARING</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched by the NativeMenu object when a key equivalent is pressed and immediately before the menu is displayed.
-
- <p class="- topic/p ">Listen to this event to update the menu either before it is displayed, or when a key
- equivalent is pressed by the user. The <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event is dispatched before the key equivalent
- is fully evaluated. You can enable, disable, add, or remove items from the menu in the <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event handler
- and those changes will be in effect when the key equivalent is processed. For example, if you remove or disable the
- menu item assigned to the triggering key equivalent, then the sequence of events is effectively canceled
- and no <codeph class="+ topic/ph pr-d/codeph ">select</codeph> event is dispatched.
- A <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event is also dispatched by the items in a menu. </p>
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event supersedes the <codeph class="+ topic/ph pr-d/codeph ">displaying</codeph> event and provides additional functionality. Listen for the
- <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event or the <codeph class="+ topic/ph pr-d/codeph ">displaying</codeph> event, but not both. </p>
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:NativeMenu_flash.events.Event.DISPLAYING_displaying" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">displaying</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched by this NativeMenu object immediately before the
- menu is displayed.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.DISPLAYING</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched by this NativeMenu object immediately before the
- menu is displayed.
-
- <p class="- topic/p ">Listen to this event to update the menu before it is displayed.
- A <codeph class="+ topic/ph pr-d/codeph ">displaying</codeph> event is also dispatched by the items in a menu.</p>
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event supersedes the <codeph class="+ topic/ph pr-d/codeph ">displaying</codeph> event and provides additional functionality. Listen for the
- <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event or the <codeph class="+ topic/ph pr-d/codeph ">displaying</codeph> event, but not both. </p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> On Mac OS X, prior to AIR 2.6, menus and menu items dispatched a <codeph class="+ topic/ph pr-d/codeph ">displaying</codeph> event when the user pressed a key
- equivalent. (This event was not dispatched for key equivalent interaction on other operating systems.) As of AIR 2.6, <codeph class="+ topic/ph pr-d/codeph ">displaying</codeph>
- events are no longer dispatched when the user presses a key equivalent. Use the <codeph class="+ topic/ph pr-d/codeph ">preparing</codeph> event instead.</p>
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><adobeApiEvent id="flash.display:NativeMenu_flash.events.Event.SELECT_select" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">select</apiName><shortdesc class="- topic/shortdesc ">
- Dispatched by this NativeMenu object when one of its menu items or an item
- in one of its descendant submenus is selected.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><apiEventType class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiEventType ">flash.events.Event.SELECT</apiEventType><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events.Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Dispatched by this NativeMenu object when one of its menu items or an item
- in one of its descendant submenus is selected.
-
- <p class="- topic/p ">A <codeph class="+ topic/ph pr-d/codeph ">select</codeph> event <i class="+ topic/ph hi-d/i ">bubbles</i> from a menu item to its containing menu and on up
- through the parent menu chain to the root menu object. The <codeph class="+ topic/ph pr-d/codeph ">target</codeph>
- property of the event object references the selected NativeMenuItem object;
- the <codeph class="+ topic/ph pr-d/codeph ">currentTarget</codeph> property references this NativeMenu object.</p>
-
- </apiDesc></adobeApiEventDetail></adobeApiEvent><apiConstructor id="flash.display:NativeMenu:NativeMenu" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation apiOperation/apiConstructor"><apiName class="- topic/title reference/title apiRef/apiName ">NativeMenu</apiName><shortdesc class="- topic/shortdesc ">
- Creates a new NativeMenu object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiConstructorDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail apiOperation/apiConstructorDetail"><apiConstructorDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiConstructorDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/></apiConstructorDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Creates a new NativeMenu object.
-
- </apiDesc></apiConstructorDetail></apiConstructor><apiOperation id="flash.display:NativeMenu:addItemAt" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">addItemAt</apiName><shortdesc class="- topic/shortdesc ">
- Inserts a menu item at the specified position.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If <codeph class="+ topic/ph pr-d/codeph ">item</codeph> is <codeph class="+ topic/ph pr-d/codeph ">null</codeph>.
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If <codeph class="+ topic/ph pr-d/codeph ">item</codeph> is a member of another menu.
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If the index is outside the bounds of the menu's
- <codeph class="+ topic/ph pr-d/codeph ">items</codeph> array.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">RangeError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">RangeError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">item</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The NativeMenuItem object to insert.
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">index</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The (zero-based) position in menu
- at which to insert the menu item.
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> Adding an item to a menu can cause an application to hang if the item's
- submenu is set to the menu itself (causing a circular reference).</p>
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Inserts a menu item at the specified position. The position is indexed from the top.
- Set the <codeph class="+ topic/ph pr-d/codeph ">index</codeph> parameter to zero to insert the item at the top of the menu.
- All types of menus: window, application, system tray icon, dock icon, context, and pop-up,
- index the menu position from the top.
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenu:addItem" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">addItem</apiName><shortdesc class="- topic/shortdesc ">
- Adds a menu item at the bottom of the menu.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If <codeph class="+ topic/ph pr-d/codeph ">item</codeph> is <codeph class="+ topic/ph pr-d/codeph ">null</codeph>.
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If <codeph class="+ topic/ph pr-d/codeph ">item</codeph> is a member of another menu.
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">item</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The NativeMenuItem object to add at the bottom of the menu.
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Adds a menu item at the bottom of the menu.
-
- <p class="- topic/p ">When creating a context menu, you can add either NativeMenuItem or
- ContextMenuItem objects. However, it is advisable to use only one type of object in a context
- menu so that all items in the menu have the same properties.</p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> Adding an item to a menu can cause an application to hang if the item's
- submenu is set to the menu itself (causing a circular reference).</p>
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenu:addSubmenuAt" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">addSubmenuAt</apiName><shortdesc class="- topic/shortdesc ">
- Adds a submenu to the menu by inserting a new menu item at the
- specified position.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The NativeMenuItem object created for the submenu.
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">submenu</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenu</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The NativeMenu object that defines the submenu to be added.
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">index</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The position in the <codeph class="+ topic/ph pr-d/codeph ">items</codeph> array of this
- menu at which to insert the menu item to be added.
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">label</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">String</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The display label for the menu item to be added.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Adds a submenu to the menu by inserting a new menu item at the
- specified position.
-
- <p class="- topic/p ">Calling the <codeph class="+ topic/ph pr-d/codeph ">addSubMenuAt()</codeph> method is equivalent to creating a new menu
- item, inserting it at the desired position in the menu, and assigning
- a NativeMenu object to the item's <codeph class="+ topic/ph pr-d/codeph ">submenu</codeph> property.</p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> Adding a menu as a submenu of itself (in a circular reference)
- can cause an application to hang.</p>
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenu:addSubmenu" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">addSubmenu</apiName><shortdesc class="- topic/shortdesc ">
- Adds a submenu to the menu by inserting a new menu item.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The NativeMenuItem object created for the submenu.
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">submenu</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenu</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The NativeMenu object that defines the submenu to be added.
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">label</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">String</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The display label for the menu item to be added.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Adds a submenu to the menu by inserting a new menu item.
-
- <p class="- topic/p ">Calling the <codeph class="+ topic/ph pr-d/codeph ">addSubMenu()</codeph> method is equivalent to creating a new menu
- item, adding it to the menu, and assigning a NativeMenu object to the
- item's <codeph class="+ topic/ph pr-d/codeph ">submenu</codeph> property.</p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> Adding a menu as a submenu of itself (in a circular reference)
- can cause an application to hang.</p>
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenu:clone" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">clone</apiName><shortdesc class="- topic/shortdesc ">
-
- Creates a copy of the menu and all items.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenu</apiOperationClassifier></apiReturn></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
-
- Creates a copy of the menu and all items.
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenu:containsItem" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">containsItem</apiName><shortdesc class="- topic/shortdesc ">
- Reports whether this menu contains the specified menu item.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc "><codeph class="+ topic/ph pr-d/codeph ">true</codeph> if <codeph class="+ topic/ph pr-d/codeph ">item</codeph> is in this menu.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">item</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The NativeMenuItem object to look up.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Reports whether this menu contains the specified menu item.
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenu:display" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">display</apiName><shortdesc class="- topic/shortdesc ">
- Pops up this menu at the specified location.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">stage</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:Stage</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The Stage object on which to display this menu.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">stageX</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Number</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The number of horizontal pixels, relative to the origin
- of stage, at which to display this menu.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">stageY</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Number</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The number of vertical pixels, relative to the origin
- of stage, at which to display this menu.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Pops up this menu at the specified location.
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenu:getItemAt" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">getItemAt</apiName><shortdesc class="- topic/shortdesc ">
- Gets the menu item at the specified index.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If <codeph class="+ topic/ph pr-d/codeph ">index</codeph> is outside the bounds of the menu's
- <codeph class="+ topic/ph pr-d/codeph ">items</codeph> array.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">RangeError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">RangeError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The NativeMenuItem object at the specified position in the menu.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">index</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The (zero-based) position of the item to return.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Gets the menu item at the specified index.
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenu:getItemByName" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">getItemByName</apiName><shortdesc class="- topic/shortdesc ">
- Gets the menu item with the specified name.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The NativeMenuItem object with the specified name or
- <codeph class="+ topic/ph pr-d/codeph ">null</codeph>, if no such item exists in the menu.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">name</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">String</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The string to look up.
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Gets the menu item with the specified name.
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> The <codeph class="+ topic/ph pr-d/codeph ">name</codeph> property of menu items is not assigned by
- default.</p>
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenu:getItemIndex" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">getItemIndex</apiName><shortdesc class="- topic/shortdesc ">
- Gets the position of the specified item.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The (zero-based) position of the specified item in this menu
- or <codeph class="+ topic/ph pr-d/codeph ">-1</codeph>, if the item is not in this menu.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">item</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The NativeMenuItem object to look up.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Gets the position of the specified item.
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenu:removeAllItems" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">removeAllItems</apiName><shortdesc class="- topic/shortdesc ">
- Removes all items from the menu.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Removes all items from the menu.
-
-
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenu:removeItemAt" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">removeItemAt</apiName><shortdesc class="- topic/shortdesc ">
- Removes and returns the menu item at the specified index.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If <codeph class="+ topic/ph pr-d/codeph ">index</codeph> is outside the bounds of
- this menu's <codeph class="+ topic/ph pr-d/codeph ">items</codeph> array.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">RangeError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">RangeError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The NativeMenuItem object removed.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">index</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The (zero-based) position of the item to remove.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Removes and returns the menu item at the specified index.
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenu:removeItem" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">removeItem</apiName><shortdesc class="- topic/shortdesc ">
- Removes the specified menu item.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If the <codeph class="+ topic/ph pr-d/codeph ">item</codeph> is not in this menu
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">RangeError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">RangeError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">item</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The NativeMenuItem object to remove from this menu.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Removes the specified menu item.
-
- </apiDesc></apiOperationDetail></apiOperation><apiOperation id="flash.display:NativeMenu:setItemIndex" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">setItemIndex</apiName><shortdesc class="- topic/shortdesc ">
- Moves a menu item to the specified position.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If <codeph class="+ topic/ph pr-d/codeph ">index</codeph> is outside the bounds of the
- menu's <codeph class="+ topic/ph pr-d/codeph ">items</codeph> array.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">RangeError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">RangeError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">item</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:NativeMenuItem</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The NativeMenuItem object to move.
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">index</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The (zero-based) position in the menu to which to move the
- <codeph class="+ topic/ph pr-d/codeph ">item</codeph>.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Moves a menu item to the specified position. If the item is not already in the menu,
- calling this method adds the item to the menu.
-
- </apiDesc></apiOperationDetail></apiOperation><apiValue id="flash.display:NativeMenu:isSupported:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">isSupported</apiName><shortdesc class="- topic/shortdesc ">
- Indicates whether any form of native menu is supported on the client system.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="2.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata><asCustoms class="+ topic/metadata adobe-api-d/asCustoms "><supportsMenu>
-
- </supportsMenu></asCustoms></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates whether any form of native menu is supported on the client system.
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#NativeWindow/supportsMenu" class="- topic/link "><linktext class="- topic/linktext ">flash.display.NativeWindow.supportsMenu</linktext></link><link href="flash.desktop.xml#NativeApplication" class="- topic/link "><linktext class="- topic/linktext ">flash.desktop.NativeApplication</linktext></link></related-links></apiValue><apiValue id="flash.display:NativeMenu:items:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">items</apiName><shortdesc class="- topic/shortdesc ">
- The array of NativeMenuItem objects in this menu.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Array</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The array of NativeMenuItem objects in this menu.
-
- <p class="- topic/p ">The array is sorted in display order.</p>
-
- <p class="- topic/p "><i class="+ topic/ph hi-d/i ">Note:</i> This property is read-only in AIR 1.0. It became read/write in AIR 1.1.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:NativeMenu:numItems:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">numItems</apiName><shortdesc class="- topic/shortdesc ">
- The number of NativeMenuItem objects in this menu.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">int</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The number of NativeMenuItem objects in this menu.
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:NativeMenu:parent:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">parent</apiName><shortdesc class="- topic/shortdesc ">
- The parent menu.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:NativeMenu</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The parent menu.
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">parent</codeph> of the root (top-level) menu object is
- <codeph class="+ topic/ph pr-d/codeph ">null</codeph>.</p>
-
- </apiDesc></apiValueDetail></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:StageOrientation" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">StageOrientation</apiName><shortdesc class="- topic/shortdesc ">
- The StageOrientation class defines constants enumerating the possible orientations of the stage and the device.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiFinal class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiFinal "/><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">The StageOrientation class provides values for the orientation property of the Stage
- class and for other properties and methods where Stage orientation is referenced.
-
- </apiTipText></apiTipTexts><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">Object</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The StageOrientation class defines constants enumerating the possible orientations of the stage and the device.
-
- </apiDesc></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Stage/orientation" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Stage.orientation</linktext></link><link href="flash.display.xml#Stage/setOrientation()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Stage.setOrientation()</linktext></link><link href="flash.display.xml#Stage/deviceOrientation" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Stage.deviceOrientation</linktext></link><link href="flash.events.xml#StageOrientationEvent/afterOrientation" class="- topic/link "><linktext class="- topic/linktext ">flash.events.StageOrientationEvent.afterOrientation</linktext></link><link href="flash.events.xml#StageOrientationEvent/beforeOrientation" class="- topic/link "><linktext class="- topic/linktext ">flash.events.StageOrientationEvent.beforeOrientation</linktext></link></related-links><apiValue id="flash.display:StageOrientation:DEFAULT" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">DEFAULT</apiName><shortdesc class="- topic/shortdesc ">
- Specifies that the stage is currently in the default orientation of the device (right-side up).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">default</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies that the stage is currently in the default orientation of the device (right-side up).
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:StageOrientation:ROTATED_LEFT" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">ROTATED_LEFT</apiName><shortdesc class="- topic/shortdesc ">
- Specifies that the stage is currently rotated left relative to the default orientation.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">rotatedLeft</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies that the stage is currently rotated left relative to the default orientation.
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> When the orientation of the device is rotated left, the orientation of the
- stage must be rotated right in order to remain upright.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:StageOrientation:ROTATED_RIGHT" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">ROTATED_RIGHT</apiName><shortdesc class="- topic/shortdesc ">
- Specifies that the stage is currently rotated right relative to the default orientation.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">rotatedRight</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies that the stage is currently rotated right relative to the default orientation.
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> When the orientation of the device is rotated right, the orientation of the
- stage must be rotated left in order to remain upright.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:StageOrientation:UNKNOWN" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">UNKNOWN</apiName><shortdesc class="- topic/shortdesc ">
- Specifies that the device has not determined an orientation.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">unknown</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies that the device has not determined an orientation. This state can occur when
- the device is lying flat on a table and also while the application is initializing.
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:StageOrientation:UPSIDE_DOWN" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">UPSIDE_DOWN</apiName><shortdesc class="- topic/shortdesc ">
- Specifies that the stage is currently upside down relative to the default orientation.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">upsideDown</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies that the stage is currently upside down relative to the default orientation.
-
- </apiDesc></apiValueDetail></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:DisplayObjectContainer" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">DisplayObjectContainer</apiName><shortdesc class="- topic/shortdesc ">
- The DisplayObjectContainer class is the base class for all objects that can serve as display object containers on
- the display list.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">The abstract base class for all display objects that can contain child objects.
-
- </apiTipText></apiTipTexts><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">flash.display:InteractiveObject</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The DisplayObjectContainer class is the base class for all objects that can serve as display object containers on
- the display list. The display list manages all objects displayed in the Flash runtimes.
- Use the DisplayObjectContainer class to arrange the display objects in the display list.
- Each DisplayObjectContainer object has its own child list for organizing the z-order of the objects.
- The z-order is the front-to-back order that determines which object is drawn in front, which is behind,
- and so on.
-
- <p class="- topic/p ">DisplayObject is an abstract base class; therefore, you cannot call DisplayObject directly. Invoking
- <codeph class="+ topic/ph pr-d/codeph ">new DisplayObject()</codeph> throws an <codeph class="+ topic/ph pr-d/codeph ">ArgumentError</codeph> exception.</p>
-
- The DisplayObjectContainer class is an abstract base class for all objects that can contain child objects.
- It cannot be instantiated directly; calling the <codeph class="+ topic/ph pr-d/codeph ">new DisplayObjectContainer()</codeph> constructor
- throws an <codeph class="+ topic/ph pr-d/codeph ">ArgumentError</codeph> exception.
-
- <p class="- topic/p ">For more information, see the "Display Programming" chapter of the <i class="+ topic/ph hi-d/i ">ActionScript 3.0 Developer's Guide</i>.</p>
-
- </apiDesc><example conref="examples\DisplayObjectContainerExample.as" class="- topic/example "> The following example uses the class <codeph class="+ topic/ph pr-d/codeph ">DisplayObjectContainerExample</codeph> to
- create five orange squares in succession. This task is accomplished by performing the following steps:
-
- <ol class="- topic/ol "><li class="- topic/li ">The constructor calls the <codeph class="+ topic/ph pr-d/codeph ">configureAssets()</codeph> method.</li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">configureAssets()</codeph> method creates <codeph class="+ topic/ph pr-d/codeph ">child</codeph> and
- <codeph class="+ topic/ph pr-d/codeph ">lastChild</codeph> Sprite objects.</li><li class="- topic/li ">A <codeph class="+ topic/ph pr-d/codeph ">for</codeph> loop creates the five orange squares and positions
- them one after another.</li><li class="- topic/li ">Each time a CustomSprite object is created, its constructor calls the <codeph class="+ topic/ph pr-d/codeph ">draw()</codeph>
- method of the <codeph class="+ topic/ph pr-d/codeph ">CustomSprite</codeph> object, which creates a 50-by-50-pixel square
- by calling the <codeph class="+ topic/ph pr-d/codeph ">beginFill()</codeph>, <codeph class="+ topic/ph pr-d/codeph ">drawRect()</codeph>, and <codeph class="+ topic/ph pr-d/codeph ">endFill()</codeph>
- methods of the Graphics class. The <codeph class="+ topic/ph pr-d/codeph ">addChild()</codeph> method adds each square to the
- display list.</li></ol>
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- package {
- import flash.display.DisplayObject;
- import flash.display.Sprite;
- public class DisplayObjectContainerExample extends Sprite {
- private var gutter:uint = 5;
- private var childCount:uint = 5;
- public function DisplayObjectContainerExample() {
- configureAssets();
- }
- private function configureAssets():void {
- var child:Sprite = new CustomSprite();
- var lastChild:Sprite = child;
- for (var i:uint = 1; i <= childCount; i++) {
- child = new CustomSprite();
- child.x = lastChild.x + lastChild.width + gutter;
- addChild(child);
- lastChild = child;
- }
- }
- }
- }
- import flash.display.Sprite;
- class CustomSprite extends Sprite {
- private var size:uint = 50;
- private var bgColor:uint = 0xFFCC00;
- public function CustomSprite() {
- draw(size, size);
- }
- private function draw(w:uint, h:uint):void {
- graphics.beginFill(bgColor);
- graphics.drawRect(0, 0, w, h);
- graphics.endFill();
- }
- }
- </codeblock></example></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObject</linktext></link></related-links><apiConstructor id="flash.display:DisplayObjectContainer:DisplayObjectContainer" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation apiOperation/apiConstructor"><apiName class="- topic/title reference/title apiRef/apiName ">DisplayObjectContainer</apiName><shortdesc class="- topic/shortdesc ">
- Calling the new DisplayObjectContainer() constructor throws an
- ArgumentError exception.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiConstructorDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail apiOperation/apiConstructorDetail"><apiConstructorDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiConstructorDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/></apiConstructorDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Calling the <codeph class="+ topic/ph pr-d/codeph ">new DisplayObjectContainer()</codeph> constructor throws an
- <codeph class="+ topic/ph pr-d/codeph ">ArgumentError</codeph> exception. You <i class="+ topic/ph hi-d/i ">can</i>, however, call constructors for
- the following subclasses of DisplayObjectContainer:
-
- <ul class="- topic/ul "><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">new Loader()</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">new Sprite()</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">new MovieClip()</codeph></li></ul>
-
- </apiDesc></apiConstructorDetail></apiConstructor><apiOperation id="flash.display:DisplayObjectContainer:addChildAt" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">addChildAt</apiName><shortdesc class="- topic/shortdesc ">
- Adds a child DisplayObject instance to this DisplayObjectContainer
- instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Throws if the index position does not exist in the child list.
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">RangeError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">RangeError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Throws if the child is the same as the parent. Also throws if
- the caller is a child (or grandchild etc.) of the child being added.
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The DisplayObject instance that you pass in the
- <codeph class="+ topic/ph pr-d/codeph ">child</codeph> parameter.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">child</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The DisplayObject instance to add as a child of this
- DisplayObjectContainer instance.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">index</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The index position to which the child is added. If you specify a
- currently occupied index position, the child object that exists at that position and all
- higher positions are moved up one position in the child list.
-
- </apiDesc></apiParam><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Adds a child object to this DisplayObjectContainer instance.
-
- </apiTipText></apiTipTexts></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Adds a child DisplayObject instance to this DisplayObjectContainer
- instance. The child is added
- at the index position specified. An index of 0 represents the back (bottom)
- of the display list for this DisplayObjectContainer object.
-
- <p class="- topic/p ">For example, the following example shows three display objects, labeled a, b, and c, at
- index positions 0, 2, and 1, respectively:</p>
-
- <p class="- topic/p "><adobeimage alt="b over c over a" href="../../images/DisplayObjectContainer_layers.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- <p class="- topic/p ">If you add a child object that already has a different display object container as
- a parent, the object is removed from the child list of the other display object container. </p>
-
- </apiDesc><example conref="examples\DisplayObjectContainer.addChildAt.1.as" class="- topic/example "> The following example creates a <codeph class="+ topic/ph pr-d/codeph ">container</codeph> display object container and
- adds a display objects <codeph class="+ topic/ph pr-d/codeph ">circle1</codeph> to its display list. Then, by calling
- <codeph class="+ topic/ph pr-d/codeph ">container.addChildAt(circle2, 0)</codeph>, it adds the <codeph class="+ topic/ph pr-d/codeph ">circle2</codeph> object to index position
- zero (the back), and moves the <codeph class="+ topic/ph pr-d/codeph ">circle1</codeph> object to index position 1:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- var container:Sprite = new Sprite();
- var circle1:Sprite = new Sprite();
- var circle2:Sprite = new Sprite();
- container.addChild(circle1);
- container.addChildAt(circle2, 0);
- trace(container.getChildAt(0) == circle2); // true
- trace(container.getChildAt(1) == circle1); // true
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObjectContainer/addChild()" class="- topic/link "><linktext class="- topic/linktext ">addChild()</linktext></link></related-links><adobeApiEvent id="flash.display:DisplayObjectContainer:addChildAt_added" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">added</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched when a display object is added to the display list.
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched when a display object is added to the display list.</shortdesc></adobeApiEvent></apiOperation><apiOperation id="flash.display:DisplayObjectContainer:addChild" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">addChild</apiName><shortdesc class="- topic/shortdesc ">
- Adds a child DisplayObject instance to this DisplayObjectContainer instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Throws if the child is the same as the parent. Also throws if
- the caller is a child (or grandchild etc.) of the child being added.
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The DisplayObject instance that you pass in the
- <codeph class="+ topic/ph pr-d/codeph ">child</codeph> parameter.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">child</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The DisplayObject instance to add as a child of this DisplayObjectContainer instance.
-
- </apiDesc></apiParam><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Adds a child object to this DisplayObjectContainer instance.
-
- </apiTipText></apiTipTexts></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Adds a child DisplayObject instance to this DisplayObjectContainer instance. The child is added
- to the front (top) of all other children in this DisplayObjectContainer instance. (To add a child to a
- specific index position, use the <codeph class="+ topic/ph pr-d/codeph ">addChildAt()</codeph> method.)
-
- <p class="- topic/p ">If you add a child object that already has a different display object container as
- a parent, the object is removed from the child list of the other display object container. </p>
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> The command <codeph class="+ topic/ph pr-d/codeph ">stage.addChild()</codeph> can cause problems with a published SWF file,
- including security problems and conflicts with other loaded SWF files. There is only one Stage within a Flash runtime instance,
- no matter how many SWF files you load into the runtime. So, generally, objects
- should not be added to the Stage, directly, at all. The only object the Stage should
- contain is the root object. Create a DisplayObjectContainer to contain all of the items on the
- display list. Then, if necessary, add that DisplayObjectContainer instance to the Stage.</p>
-
- </apiDesc><example conref="examples\DisplayObjectContainer.numChildren.1.as" class="- topic/example "> The following example sets up two Sprite objects named <codeph class="+ topic/ph pr-d/codeph ">container1</codeph> and
- <codeph class="+ topic/ph pr-d/codeph ">container2</codeph>. A Sprite is a type of display object container. The example calls the
- <codeph class="+ topic/ph pr-d/codeph ">addChild()</codeph> method to set up the display hierarchy: <codeph class="+ topic/ph pr-d/codeph ">container1</codeph> is a child of
- <codeph class="+ topic/ph pr-d/codeph ">container2</codeph>, and two other display objects, <codeph class="+ topic/ph pr-d/codeph ">circle1</codeph> and <codeph class="+ topic/ph pr-d/codeph ">circle2</codeph>,
- are children of <codeph class="+ topic/ph pr-d/codeph ">container1</codeph>. The calls to the <codeph class="+ topic/ph pr-d/codeph ">trace()</codeph> method show the number
- of children of each object. Note that grandchildren are not included in the <codeph class="+ topic/ph pr-d/codeph ">numChildren</codeph> count:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- var container1:Sprite = new Sprite();
- var container2:Sprite = new Sprite();
- var circle1:Sprite = new Sprite();
- circle1.graphics.beginFill(0xFFCC00);
- circle1.graphics.drawCircle(40, 40, 40);
- var circle2:Sprite = new Sprite();
- circle2.graphics.beginFill(0x00CCFF);
- circle2.graphics.drawCircle(80, 40, 40);
- container2.addChild(container1);
- container1.addChild(circle1);
- container1.addChild(circle2);
- trace(container1.numChildren); // 2
- trace(container2.numChildren); // 1
- trace(circle1.numChildren); // 0
- trace(circle2.numChildren); // 0
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObjectContainer/addChildAt()" class="- topic/link "><linktext class="- topic/linktext ">addChildAt()</linktext></link></related-links><adobeApiEvent id="flash.display:DisplayObjectContainer:addChild_added" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef adobeApiEvent/adobeApiEvent "><apiName class="- topic/title reference/title apiRef/apiName ">added</apiName><prolog class="- topic/prolog "/><adobeApiEventDetail class="- topic/body reference/refbody apiRef/apiDetail adobeApiEvent/adobeApiEventDetail "><adobeApiEventDef class="- topic/section reference/section apiRef/apiDef adobeApiEvent/adobeApiEventDef "><adobeApiEventClassifier class="- topic/xref reference/xref apiRef/apiRelation adobeApiEvent/adobeApiEventClassifier ">flash.events:Event</adobeApiEventClassifier><apiGeneratedEvent class="- topic/state reference/state apiRef/apiQualifier adobeApiEvent/apiGeneratedEvent "/></adobeApiEventDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Dispatched when a display object is added to the display list.
- </apiDesc></adobeApiEventDetail><shortdesc class="- topic/shortdesc ">Dispatched when a display object is added to the display list.</shortdesc></adobeApiEvent></apiOperation><apiOperation id="flash.display:DisplayObjectContainer:areInaccessibleObjectsUnderPoint" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">areInaccessibleObjectsUnderPoint</apiName><shortdesc class="- topic/shortdesc ">
- Indicates whether the security restrictions
- would cause any display objects to be omitted from the list returned by calling
- the DisplayObjectContainer.getObjectsUnderPoint() method
- with the specified point point.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc "><codeph class="+ topic/ph pr-d/codeph ">true</codeph> if the point contains child display objects with security restrictions.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">point</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Point</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The point under which to look.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates whether the security restrictions
- would cause any display objects to be omitted from the list returned by calling
- the <codeph class="+ topic/ph pr-d/codeph ">DisplayObjectContainer.getObjectsUnderPoint()</codeph> method
- with the specified <codeph class="+ topic/ph pr-d/codeph ">point</codeph> point. By default, content from one domain cannot
- access objects from another domain unless they are permitted to do so with a call to the
- <codeph class="+ topic/ph pr-d/codeph ">Security.allowDomain()</codeph> method. For more information, related to security,
- see the Flash Player Developer Center Topic:
- <xref href="http://www.adobe.com/go/devnet_security_en" scope="external" class="- topic/xref ">Security</xref>.
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">point</codeph> parameter is in the coordinate space of the Stage,
- which may differ from the coordinate space of the display object container (unless the
- display object container is the Stage). You can use the <codeph class="+ topic/ph pr-d/codeph ">globalToLocal()</codeph> and
- the <codeph class="+ topic/ph pr-d/codeph ">localToGlobal()</codeph> methods to convert points between these coordinate
- spaces.</p>
-
- </apiDesc><example conref="examples\DisplayObjectContainer.areInaccessibleObjectsUnderPoint.as" class="- topic/example "> The following code creates a display object container named <codeph class="+ topic/ph pr-d/codeph ">container</codeph>.
- The next block of code uses a Loader object to load a JPEG file named "test.jpg" from a remote file server.
- Note that the <codeph class="+ topic/ph pr-d/codeph ">checkPolicyFile</codeph> property of the LoaderContext object used as a parameter in the
- <codeph class="+ topic/ph pr-d/codeph ">load()</codeph> method is set to <codeph class="+ topic/ph pr-d/codeph ">false</codeph>. Once the file is loaded, the code calls
- the <codeph class="+ topic/ph pr-d/codeph ">loaded()</codeph> method, which in turn calls <codeph class="+ topic/ph pr-d/codeph ">container.areInaccessibleObjectsUnderPoint()</codeph>,
- which returns a value of <codeph class="+ topic/ph pr-d/codeph ">true</codeph> because the loaded content is assumed to be from an
- inaccessible domain:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.display.Loader;
- import flash.system.LoaderContext;
- import flash.net.URLRequest;
- import flash.events.Event;
- import flash.geom.Point;
- var container:Sprite = new Sprite();
- var urlReq:URLRequest = new URLRequest("http://localhost/RemoteFile.swf");
- var ldr:Loader = new Loader();
- var context:LoaderContext = new LoaderContext();
- context.checkPolicyFile = false;
- ldr.load(urlReq, context);
- ldr.contentLoaderInfo.addEventListener(Event.COMPLETE, loaded);
- ldr.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, urlNotFound);
- function loaded(event:Event):void {
- var pt:Point = new Point(1, 1);
- trace(container.areInaccessibleObjectsUnderPoint(pt)); // true
- }
- function urlNotFound(event:Event):void {
- trace("The URL was not found.");
- }
- </codeblock> This example assumes that the SWF file produced by this code is loaded from a different domain
- than that of the JPEG file, and that the loaded JPEG file occupies the point (1, 1).
- </example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.system.xml#Security/allowDomain()" class="- topic/link "><linktext class="- topic/linktext ">flash.system.Security.allowDomain()</linktext></link><link href="flash.display.xml#DisplayObjectContainer/getObjectsUnderPoint()" class="- topic/link "><linktext class="- topic/linktext ">getObjectsUnderPoint()</linktext></link><link href="flash.display.xml#DisplayObject/globalToLocal()" class="- topic/link "><linktext class="- topic/linktext ">DisplayObject.globalToLocal()</linktext></link><link href="flash.display.xml#DisplayObject/localToGlobal()" class="- topic/link "><linktext class="- topic/linktext ">DisplayObject.localToGlobal()</linktext></link></related-links></apiOperation><apiOperation id="flash.display:DisplayObjectContainer:contains" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">contains</apiName><shortdesc class="- topic/shortdesc ">
- Determines whether the specified display object is a child of the DisplayObjectContainer instance or
- the instance itself.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc "><codeph class="+ topic/ph pr-d/codeph ">true</codeph> if the <codeph class="+ topic/ph pr-d/codeph ">child</codeph> object is a child of the DisplayObjectContainer
- or the container itself; otherwise <codeph class="+ topic/ph pr-d/codeph ">false</codeph>.
-
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">child</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The child object to test.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Determines whether the specified display object is a child of the DisplayObjectContainer instance or
- the instance itself.
- The search includes the entire display list including this DisplayObjectContainer instance. Grandchildren,
- great-grandchildren, and so on each return <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.
-
- </apiDesc><example conref="examples\DisplayObjectContainer.contains.1.as" class="- topic/example "> The following example sets up a number of Sprite objects and adds some to the child list
- of others. (A Sprite object is a type of display object container.) The relationship between various objects is
- shown by calling the <codeph class="+ topic/ph pr-d/codeph ">contains()</codeph> method:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- var sprite1:Sprite = new Sprite();
- var sprite2:Sprite = new Sprite();
- var sprite3:Sprite = new Sprite();
- var sprite4:Sprite = new Sprite();
- sprite1.addChild(sprite2);
- sprite2.addChild(sprite3);
- trace(sprite1.contains(sprite1)); // true
- trace(sprite1.contains(sprite2)); // true
- trace(sprite1.contains(sprite3)); // true
- trace(sprite1.contains(sprite4)); // false
- </codeblock></example></apiOperationDetail></apiOperation><apiOperation id="flash.display:DisplayObjectContainer:getChildAt" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">getChildAt</apiName><shortdesc class="- topic/shortdesc ">
- Returns the child display object instance that exists at the specified index.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Throws if the index does not exist in the child list.
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">RangeError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">RangeError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">This child display object belongs to a sandbox
- to which you do not have access. You can avoid this situation by having
- the child movie call <codeph class="+ topic/ph pr-d/codeph ">Security.allowDomain()</codeph>.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">SecurityError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">SecurityError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The child display object at the specified index position.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">index</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The index position of the child object.
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Returns the child display object instance that exists at the specified index.
-
- </apiDesc><example conref="examples\DisplayObjectContainer.getChildAt.1.as" class="- topic/example "> The following example creates a display object container named <codeph class="+ topic/ph pr-d/codeph ">container</codeph>
- and then adds a three display objects to the child list of the <codeph class="+ topic/ph pr-d/codeph ">container</codeph> object. The calls to the
- <codeph class="+ topic/ph pr-d/codeph ">getChildAt()</codeph> method then reveal the positions of the child objects:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- var container:Sprite = new Sprite();
- var sprite1:Sprite = new Sprite();
- var sprite2:Sprite = new Sprite();
- var sprite3:Sprite = new Sprite();
- container.addChild(sprite1);
- container.addChild(sprite2);
- container.addChildAt(sprite3, 0);
- trace(container.getChildAt(0) == sprite3); // true
- trace(container.getChildAt(1) == sprite1); // true
- trace(container.getChildAt(2) == sprite2); // true
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObjectContainer/getChildByName()" class="- topic/link "><linktext class="- topic/linktext ">getChildByName()</linktext></link></related-links></apiOperation><apiOperation id="flash.display:DisplayObjectContainer:getChildByName" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">getChildByName</apiName><shortdesc class="- topic/shortdesc ">
- Returns the child display object that exists with the specified name.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">This child display object belongs to a sandbox
- to which you do not have access. You can avoid this situation by having
- the child movie call the <codeph class="+ topic/ph pr-d/codeph ">Security.allowDomain()</codeph> method.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">SecurityError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">SecurityError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The child display object with the specified name.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">name</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">String</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The name of the child to return.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Returns the child display object that exists with the specified name.
- If more that one child display object has the specified name,
- the method returns the first object in the child list.
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">getChildAt()</codeph> method is faster than the
- <codeph class="+ topic/ph pr-d/codeph ">getChildByName()</codeph> method. The <codeph class="+ topic/ph pr-d/codeph ">getChildAt()</codeph> method accesses
- a child from a cached array, whereas the <codeph class="+ topic/ph pr-d/codeph ">getChildByName()</codeph> method
- has to traverse a linked list to access a child.</p>
-
- </apiDesc><example conref="examples\DisplayObjectContainer.getChildByName.1.as" class="- topic/example "> The following example creates a display object container named
- <codeph class="+ topic/ph pr-d/codeph ">container</codeph> and then adds two child display objects to the container.
- Then, the code calls the <codeph class="+ topic/ph pr-d/codeph ">getChildByName()</codeph> and <codeph class="+ topic/ph pr-d/codeph ">getChildIndex()</codeph>
- methods to return the index position of the child of the <codeph class="+ topic/ph pr-d/codeph ">container</codeph> object that
- has the <codeph class="+ topic/ph pr-d/codeph ">name "sprite1"</codeph>.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.display.DisplayObject;
- var container:Sprite = new Sprite();
- var sprite1:Sprite = new Sprite();
- sprite1.name = "sprite1";
- var sprite2:Sprite = new Sprite();
- sprite2.name = "sprite2";
- container.addChild(sprite1);
- container.addChild(sprite2);
- var target:DisplayObject = container.getChildByName("sprite1");
- trace(container.getChildIndex(target)); // 0
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObjectContainer/getChildAt()" class="- topic/link "><linktext class="- topic/linktext ">getChildAt()</linktext></link><link href="flash.display.xml#DisplayObject/name" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObject.name</linktext></link></related-links></apiOperation><apiOperation id="flash.display:DisplayObjectContainer:getChildIndex" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">getChildIndex</apiName><shortdesc class="- topic/shortdesc ">
- Returns the index position of a child DisplayObject instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Throws if the child parameter is not a child of this object.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The index position of the child display object to identify.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">child</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The DisplayObject instance to identify.
-
- </apiDesc></apiParam><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Returns the index number of a child DisplayObject instance.
-
- </apiTipText></apiTipTexts></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Returns the index position of a <codeph class="+ topic/ph pr-d/codeph ">child</codeph> DisplayObject instance.
-
- </apiDesc><example conref="examples\DisplayObjectContainer.getChildByName.1.as" class="- topic/example "> The following example creates a display object container named
- <codeph class="+ topic/ph pr-d/codeph ">container</codeph> and then adds two child display objects to the container.
- Then, the code calls the <codeph class="+ topic/ph pr-d/codeph ">getChildByName()</codeph> and <codeph class="+ topic/ph pr-d/codeph ">getChildIndex()</codeph>
- methods to return the index position of the child of the <codeph class="+ topic/ph pr-d/codeph ">container</codeph> object that
- has the <codeph class="+ topic/ph pr-d/codeph ">name "sprite1"</codeph>.
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.display.DisplayObject;
- var container:Sprite = new Sprite();
- var sprite1:Sprite = new Sprite();
- sprite1.name = "sprite1";
- var sprite2:Sprite = new Sprite();
- sprite2.name = "sprite2";
- container.addChild(sprite1);
- container.addChild(sprite2);
- var target:DisplayObject = container.getChildByName("sprite1");
- trace(container.getChildIndex(target)); // 0
- </codeblock></example></apiOperationDetail></apiOperation><apiOperation id="flash.display:DisplayObjectContainer:getObjectsUnderPoint" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">getObjectsUnderPoint</apiName><shortdesc class="- topic/shortdesc ">
- Returns an array of objects that lie under the specified point and are children
- (or grandchildren, and so on) of this DisplayObjectContainer instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">An array of objects that lie under the specified point and are children
- (or grandchildren, and so on) of this DisplayObjectContainer instance.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Array</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">point</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Point</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The point under which to look.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Returns an array of objects that lie under the specified point and are children
- (or grandchildren, and so on) of this DisplayObjectContainer instance. Any child objects that
- are inaccessible for security reasons are omitted from the returned array. To determine whether
- this security restriction affects the returned array, call the
- <codeph class="+ topic/ph pr-d/codeph ">areInaccessibleObjectsUnderPoint()</codeph> method.
-
- <p class="- topic/p ">The <codeph class="+ topic/ph pr-d/codeph ">point</codeph> parameter is in the coordinate space of the Stage,
- which may differ from the coordinate space of the display object container (unless the
- display object container is the Stage). You can use the <codeph class="+ topic/ph pr-d/codeph ">globalToLocal()</codeph> and
- the <codeph class="+ topic/ph pr-d/codeph ">localToGlobal()</codeph> methods to convert points between these coordinate
- spaces.</p>
-
- </apiDesc><example conref="examples\DisplayObjectContainer.getObjectsUnderPoint.1.as" class="- topic/example "> The following example creates a display object container named <codeph class="+ topic/ph pr-d/codeph ">container</codeph>
- and then adds two overlapping child display objects to the container. Then the code calls the
- <codeph class="+ topic/ph pr-d/codeph ">getObjectsUnderPoint()</codeph> twice — first using a point that touches only one object,
- then using a point where the objects overlap — and the <codeph class="+ topic/ph pr-d/codeph ">length</codeph> of the return
- Array shows the number of objects at each point in the container:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.geom.Point;
- var container:Sprite = new Sprite();
- var square1:Sprite = new Sprite();
- square1.graphics.beginFill(0xFFCC00);
- square1.graphics.drawRect(0, 0, 40, 40);
- var square2:Sprite = new Sprite();
- square2.graphics.beginFill(0x00CCFF);
- square2.graphics.drawRect(20, 0, 30, 40);
- container.addChild(square1);
- container.addChild(square2);
- var pt:Point = new Point(10, 20);
- var objects:Array = container.getObjectsUnderPoint(pt);
- trace(objects.length); // 1
- pt = new Point(35, 20);
- objects = container.getObjectsUnderPoint(pt);
- trace(objects.length); // 2
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObjectContainer/areInaccessibleObjectsUnderPoint()" class="- topic/link "><linktext class="- topic/linktext ">areInaccessibleObjectsUnderPoint()</linktext></link><link href="flash.display.xml#DisplayObject/globalToLocal()" class="- topic/link "><linktext class="- topic/linktext ">DisplayObject.globalToLocal()</linktext></link><link href="flash.display.xml#DisplayObject/localToGlobal()" class="- topic/link "><linktext class="- topic/linktext ">DisplayObject.localToGlobal()</linktext></link></related-links></apiOperation><apiOperation id="flash.display:DisplayObjectContainer:removeChildAt" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">removeChildAt</apiName><shortdesc class="- topic/shortdesc ">
- Removes a child DisplayObject from the specified index position in the child list of
- the DisplayObjectContainer.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">This child display object belongs to a sandbox
- to which the calling object does not have access. You can avoid this situation by having
- the child movie call the <codeph class="+ topic/ph pr-d/codeph ">Security.allowDomain()</codeph> method.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">SecurityError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">SecurityError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Throws if the index does not exist in the child list.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">RangeError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">RangeError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The DisplayObject instance that was removed.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">index</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The child index of the DisplayObject to remove.
-
- </apiDesc></apiParam><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Removes a child display object, at the specified <codeph class="+ topic/ph pr-d/codeph ">index</codeph> position, from the
- DisplayObjectContainer instance.
-
- </apiTipText></apiTipTexts></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Removes a child DisplayObject from the specified <codeph class="+ topic/ph pr-d/codeph ">index</codeph> position in the child list of
- the DisplayObjectContainer. The <codeph class="+ topic/ph pr-d/codeph ">parent</codeph> property of the removed child is set to
- <codeph class="+ topic/ph pr-d/codeph ">null</codeph>, and the object is garbage collected if no other references to the child exist. The index
- positions of any display objects above the child in the DisplayObjectContainer are decreased by 1.
-
- <p class="- topic/p ">The garbage collector reallocates unused memory space. When a variable or
- object is no longer actively referenced or stored somewhere, the garbage collector sweeps
- through and wipes out the memory space it used to occupy if no other references to it exist.</p>
-
- </apiDesc><example conref="examples\DisplayObjectContainer.removeChildAt.1.as" class="- topic/example "> The following example creates a display object container named
- <codeph class="+ topic/ph pr-d/codeph ">container</codeph> and then adds two child display objects to the container.
- The code then shows that when you call the <codeph class="+ topic/ph pr-d/codeph ">removeChildAt()</codeph> method
- to remove the child at the lowest index position (0), any other child object in the list
- moves down one position:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- var container:Sprite = new Sprite();
- var sprite1:Sprite = new Sprite();
- sprite1.name = "sprite1";
- var sprite2:Sprite = new Sprite();
- sprite2.name = "sprite2";
- container.addChild(sprite1);
- container.addChild(sprite2);
- trace(container.numChildren) // 2
- container.removeChildAt(0);
- trace(container.numChildren) // 1
- trace(container.getChildAt(0).name); // sprite2
- </codeblock></example></apiOperationDetail></apiOperation><apiOperation id="flash.display:DisplayObjectContainer:removeChild" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">removeChild</apiName><shortdesc class="- topic/shortdesc ">
- Removes the specified child DisplayObject instance from the child list of the DisplayObjectContainer instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Throws if the child parameter is not a child of this object.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The DisplayObject instance that you pass in the
- <codeph class="+ topic/ph pr-d/codeph ">child</codeph> parameter.
-
- </apiDesc><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">child</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The DisplayObject instance to remove.
-
- </apiDesc></apiParam><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Removes a child display object from the DisplayObjectContainer
- instance.
-
- </apiTipText></apiTipTexts></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Removes the specified <codeph class="+ topic/ph pr-d/codeph ">child</codeph> DisplayObject instance from the child list of the DisplayObjectContainer instance.
- The <codeph class="+ topic/ph pr-d/codeph ">parent</codeph> property of the removed child is set to <codeph class="+ topic/ph pr-d/codeph ">null</codeph>
- , and the object is garbage collected if no other
- references to the child exist. The index positions of any display objects above the child in the
- DisplayObjectContainer are decreased by 1.
-
- <p class="- topic/p ">The garbage collector reallocates unused memory space. When a variable
- or object is no longer actively referenced or stored somewhere, the garbage collector sweeps
- through and wipes out the memory space it used to occupy if no other references to it exist.</p>
-
- </apiDesc><example conref="examples\DisplayObjectContainer.removeChild.1.as" class="- topic/example "> The following example creates a display object container named
- <codeph class="+ topic/ph pr-d/codeph ">container</codeph> and then adds two child display objects to the container.
- An event listener is added to the <codeph class="+ topic/ph pr-d/codeph ">container</codeph> object, so that when the
- user clicks a child object of the container, the <codeph class="+ topic/ph pr-d/codeph ">removeChild()</codeph> method
- removes the child clicked from the child list of the container:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
-
- import flash.display.DisplayObject;
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var container:Sprite = new Sprite();
- addChild(container);
- var circle1:Sprite = new Sprite();
- circle1.graphics.beginFill(0xFFCC00);
- circle1.graphics.drawCircle(40, 40, 40);
- var circle2:Sprite = new Sprite();
- circle2.graphics.beginFill(0x00CCFF);
- circle2.graphics.drawCircle(120, 40, 40);
- container.addChild(circle1);
- container.addChild(circle2);
- container.addEventListener(MouseEvent.CLICK, clicked);
- function clicked(event:MouseEvent):void {
- container.removeChild(DisplayObject(event.target));
- }
- </codeblock></example></apiOperationDetail></apiOperation><apiOperation id="flash.display:DisplayObjectContainer:setChildIndex" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">setChildIndex</apiName><shortdesc class="- topic/shortdesc ">
- Changes the position of an existing child in the display object container.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Throws if the index does not exist in the child list.
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">RangeError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">RangeError</apiOperationClassifier></apiException><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Throws if the child parameter is not a child of this object.
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">child</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The child DisplayObject instance for which you want to change
- the index number.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">index</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The resulting index number for the <codeph class="+ topic/ph pr-d/codeph ">child</codeph> display object.
-
- </apiDesc></apiParam><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Changes the index number of an existing child.
-
- </apiTipText></apiTipTexts></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Changes the position of an existing child in the display object container.
- This affects the layering of child objects. For example, the following example shows three
- display objects, labeled a, b, and c, at index positions 0, 1, and 2, respectively:
-
- <p class="- topic/p "><adobeimage alt="c over b over a" href="../../images/DisplayObjectContainerSetChildIndex1.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- <p class="- topic/p ">When you use the <codeph class="+ topic/ph pr-d/codeph ">setChildIndex()</codeph> method and specify an index position
- that is already occupied, the only positions that change are those in between the display object's former and new position.
- All others will stay the same.
- If a child is moved to an index LOWER than its current index, all children in between will INCREASE by 1 for their index reference.
- If a child is moved to an index HIGHER than its current index, all children in between will DECREASE by 1 for their index reference.
- For example, if the display object container
- in the previous example is named <codeph class="+ topic/ph pr-d/codeph ">container</codeph>, you can swap the position
- of the display objects labeled a and b by calling the following code:</p>
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">container.setChildIndex(container.getChildAt(1), 0);</codeblock>
-
- <p class="- topic/p ">This code results in the following arrangement of objects:</p>
-
- <p class="- topic/p "><adobeimage alt="c over a over b" href="../../images/DisplayObjectContainerSetChildIndex2.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- </apiDesc><example conref="examples\DisplayObjectContainer.setChildIndex.1.as" class="- topic/example "> The following example creates a display object container named
- <codeph class="+ topic/ph pr-d/codeph ">container</codeph> and then adds three slightly overlapping child display
- objects to the container. When the user clicks any of these objects, the
- <codeph class="+ topic/ph pr-d/codeph ">clicked()</codeph> method calls the <codeph class="+ topic/ph pr-d/codeph ">setChildIndex()</codeph>
- method to move the clicked object to the top-most position in the child list of
- the <codeph class="+ topic/ph pr-d/codeph ">container</codeph> object:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var container:Sprite = new Sprite();
- addChild(container);
- var circle1:Sprite = new Sprite();
- circle1.graphics.beginFill(0xFF0000);
- circle1.graphics.drawCircle(40, 40, 40);
- circle1.addEventListener(MouseEvent.CLICK, clicked);
-
- var circle2:Sprite = new Sprite();
- circle2.graphics.beginFill(0x00FF00);
- circle2.graphics.drawCircle(100, 40, 40);
- circle2.addEventListener(MouseEvent.CLICK, clicked);
-
- var circle3:Sprite = new Sprite();
- circle3.graphics.beginFill(0x0000FF);
- circle3.graphics.drawCircle(70, 80, 40);
- circle3.addEventListener(MouseEvent.CLICK, clicked);
-
- container.addChild(circle1);
- container.addChild(circle2);
- container.addChild(circle3);
- addChild(container);
-
- function clicked(event:MouseEvent):void {
- var circle:Sprite = Sprite(event.target);
- var topPosition:uint = container.numChildren - 1;
- container.setChildIndex(circle, topPosition);
- }
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObjectContainer/addChildAt()" class="- topic/link "><linktext class="- topic/linktext ">addChildAt()</linktext></link><link href="flash.display.xml#DisplayObjectContainer/getChildIndex()" class="- topic/link "><linktext class="- topic/linktext ">getChildIndex()</linktext></link></related-links></apiOperation><apiOperation id="flash.display:DisplayObjectContainer:swapChildrenAt" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">swapChildrenAt</apiName><shortdesc class="- topic/shortdesc ">
- Swaps the z-order (front-to-back order) of the child objects at the two specified index positions in the
- child list.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If either index does not exist in the child list.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">RangeError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">RangeError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">index1</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The index position of the first child object.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">index2</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The index position of the second child object.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Swaps the z-order (front-to-back order) of the child objects at the two specified index positions in the
- child list. All other child objects in the display object container remain in the same index positions.
-
- </apiDesc><example conref="examples\DisplayObjectContainer.swapChildrenAt.1.as" class="- topic/example "> The following example creates a display object container named
- <codeph class="+ topic/ph pr-d/codeph ">container</codeph>, then adds three child display objects to the container,
- and then shows how a call to the <codeph class="+ topic/ph pr-d/codeph ">swapChildrenAt()</codeph> method rearranges
- the child list of the display object container:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- var container:Sprite = new Sprite();
- var sprite1:Sprite = new Sprite();
- sprite1.name = "sprite1";
- var sprite2:Sprite = new Sprite();
- sprite2.name = "sprite2";
- var sprite3:Sprite = new Sprite();
- sprite3.name = "sprite3";
- container.addChild(sprite1);
- container.addChild(sprite2);
- container.addChild(sprite3);
- trace(container.getChildAt(0).name); // sprite1
- trace(container.getChildAt(1).name); // sprite2
- trace(container.getChildAt(2).name); // sprite3
- container.swapChildrenAt(0, 2);
- trace(container.getChildAt(0).name); // sprite3
- trace(container.getChildAt(1).name); // sprite2
- trace(container.getChildAt(2).name); // sprite1
- </codeblock></example></apiOperationDetail></apiOperation><apiOperation id="flash.display:DisplayObjectContainer:swapChildren" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">swapChildren</apiName><shortdesc class="- topic/shortdesc ">
- Swaps the z-order (front-to-back order) of the two specified child objects.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Throws if either child parameter is not a child of this object.
-
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ArgumentError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">ArgumentError</apiOperationClassifier></apiException><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">child1</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The first child object.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">child2</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:DisplayObject</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The second child object.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Swaps the z-order (front-to-back order) of the two specified child objects. All other child
- objects in the display object container remain in the same index positions.
-
- </apiDesc><example conref="examples\DisplayObjectContainer.swapChildren.1.as" class="- topic/example "> The following example creates a display object container named
- <codeph class="+ topic/ph pr-d/codeph ">container</codeph>, then adds two child display objects to the container,
- and then shows the effect of a call to the <codeph class="+ topic/ph pr-d/codeph ">swapChildren()</codeph> method:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- var container:Sprite = new Sprite();
- var sprite1:Sprite = new Sprite();
- sprite1.name = "sprite1";
- var sprite2:Sprite = new Sprite();
- sprite2.name = "sprite2";
- container.addChild(sprite1);
- container.addChild(sprite2);
- trace(container.getChildAt(0).name); // sprite1
- trace(container.getChildAt(1).name); // sprite2
- container.swapChildren(sprite1, sprite2);
- trace(container.getChildAt(0).name); // sprite2
- trace(container.getChildAt(1).name); // sprite1
- </codeblock></example></apiOperationDetail></apiOperation><apiValue id="flash.display:DisplayObjectContainer:mouseChildren:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">mouseChildren</apiName><shortdesc class="- topic/shortdesc ">
- Determines whether or not the children of the object are mouse, or user input device, enabled.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Determines whether or not the children of the object are mouse, or user input device, enabled.
- If an object is enabled, a user can interact with it by using a mouse or user input device. The default is <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.
-
- <p class="- topic/p ">This property is useful when you create a button with an instance of the Sprite class
- (instead of using the SimpleButton class). When you use a Sprite instance to create a button,
- you can choose to decorate the button by using the <codeph class="+ topic/ph pr-d/codeph ">addChild()</codeph> method to add additional
- Sprite instances. This process can cause unexpected behavior with mouse events because
- the Sprite instances you add as children can become the target object of a mouse event
- when you expect the parent instance to be the target object. To ensure that the parent
- instance serves as the target objects for mouse events, you can set the
- <codeph class="+ topic/ph pr-d/codeph ">mouseChildren</codeph> property of the parent instance to <codeph class="+ topic/ph pr-d/codeph ">false</codeph>.</p>
- <p class="- topic/p "> No event is dispatched by setting this property. You must use the
- <codeph class="+ topic/ph pr-d/codeph ">addEventListener()</codeph> method to create interactive functionality.</p>
-
- </apiDesc><example conref="examples\DisplayObjectContainer.mouseChildren.1.as" class="- topic/example "> The following example sets up a Sprite object (a type of display object container) named
- <codeph class="+ topic/ph pr-d/codeph ">container</codeph> and shows that when you set its <codeph class="+ topic/ph pr-d/codeph ">mouseChildren</codeph> property to
- <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, the target of a <codeph class="+ topic/ph pr-d/codeph ">mouseClick</codeph> event is the <codeph class="+ topic/ph pr-d/codeph ">container</codeph>
- object, not any one of its child objects:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var container:Sprite = new Sprite();
- container.name = "container";
- addChild(container);
- var circle:Sprite = new Sprite();
- circle.name = "circle";
- circle.graphics.beginFill(0xFFCC00);
- circle.graphics.drawCircle(40, 40, 40);
- container.addChild(circle);
- container.mouseChildren = false;
- container.addEventListener(MouseEvent.CLICK, clicked);
- function clicked(event:MouseEvent):void {
- trace(event.target.name); // container
- }
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Sprite/buttonMode" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Sprite.buttonMode</linktext></link><link href="flash.events.xml#EventDispatcher/addEventListener()" class="- topic/link "><linktext class="- topic/linktext ">flash.events.EventDispatcher.addEventListener()</linktext></link></related-links></apiValue><apiValue id="flash.display:DisplayObjectContainer:numChildren:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">numChildren</apiName><shortdesc class="- topic/shortdesc ">
- Returns the number of children of this object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">int</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Returns the number of children of this object.
-
- </apiDesc><example conref="examples\DisplayObjectContainer.numChildren.1.as" class="- topic/example "> The following example sets up two Sprite objects named <codeph class="+ topic/ph pr-d/codeph ">container1</codeph> and
- <codeph class="+ topic/ph pr-d/codeph ">container2</codeph>. A Sprite is a type of display object container. The example calls the
- <codeph class="+ topic/ph pr-d/codeph ">addChild()</codeph> method to set up the display hierarchy: <codeph class="+ topic/ph pr-d/codeph ">container1</codeph> is a child of
- <codeph class="+ topic/ph pr-d/codeph ">container2</codeph>, and two other display objects, <codeph class="+ topic/ph pr-d/codeph ">circle1</codeph> and <codeph class="+ topic/ph pr-d/codeph ">circle2</codeph>,
- are children of <codeph class="+ topic/ph pr-d/codeph ">container1</codeph>. The calls to the <codeph class="+ topic/ph pr-d/codeph ">trace()</codeph> method show the number
- of children of each object. Note that grandchildren are not included in the <codeph class="+ topic/ph pr-d/codeph ">numChildren</codeph> count:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- var container1:Sprite = new Sprite();
- var container2:Sprite = new Sprite();
- var circle1:Sprite = new Sprite();
- circle1.graphics.beginFill(0xFFCC00);
- circle1.graphics.drawCircle(40, 40, 40);
- var circle2:Sprite = new Sprite();
- circle2.graphics.beginFill(0x00CCFF);
- circle2.graphics.drawCircle(80, 40, 40);
- container2.addChild(container1);
- container1.addChild(circle1);
- container1.addChild(circle2);
- trace(container1.numChildren); // 2
- trace(container2.numChildren); // 1
- trace(circle1.numChildren); // 0
- trace(circle2.numChildren); // 0
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObjectContainer:tabChildren:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">tabChildren</apiName><shortdesc class="- topic/shortdesc ">
- Determines whether the children of the object are tab enabled.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier><apiException class="+ topic/ph reference/ph apiRef/apiDefItem apiOperation/apiEvent adobe-api-d/apiException "><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Calling this property of the Stage object
- throws an exception. The Stage object does not implement this property.
-
- </apiDesc><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">IllegalOperationError</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.errors:IllegalOperationError</apiOperationClassifier></apiException></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Determines whether the children of the object are tab enabled. Enables or disables tabbing for the
- children of the object. The default is <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> Do not use the <codeph class="+ topic/ph pr-d/codeph ">tabChildren</codeph> property with Flex.
- Instead, use the <codeph class="+ topic/ph pr-d/codeph ">mx.core.UIComponent.hasFocusableChildren</codeph> property.</p>
-
- </apiDesc><example conref="examples\DisplayObjectContainer.tabChildren.1.as" class="- topic/example "> The following example creates a <codeph class="+ topic/ph pr-d/codeph ">container1</codeph> display object container and
- adds two display objects, <codeph class="+ topic/ph pr-d/codeph ">circle1</codeph> and <codeph class="+ topic/ph pr-d/codeph ">circle2</codeph>,
- to its child list. The example sets tabChildren to <codeph class="+ topic/ph pr-d/codeph ">false</codeph> for the children so it can
- manage its own tab order using <codeph class="+ topic/ph pr-d/codeph ">tabIndex</codeph>:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- var container:Sprite = new Sprite();
- container.tabChildren = false;
- var circle1:Sprite = new Sprite();
- circle1.graphics.beginFill(0xFFCC00);
- circle1.graphics.drawCircle(40, 40, 40);
- circle1.tabIndex = 1;
- var circle2:Sprite = new Sprite();
- circle2.graphics.beginFill(0x00CCFF);
- circle2.graphics.drawCircle(120, 40, 40);
- circle2.tabIndex = 0;
- container.addChild(circle1);
- container.addChild(circle2);
- </codeblock> To see the results of this example, compile and run the file. When you select one of the circles,
- you can press the TAB key to switch the display object that has focus (indicated by a yellow highlight rectangle).
- </example></apiValueDetail></apiValue><apiValue id="flash.display:DisplayObjectContainer:textSnapshot:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">textSnapshot</apiName><shortdesc class="- topic/shortdesc ">
- Returns a TextSnapshot object for this DisplayObjectContainer instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.text:TextSnapshot</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Returns a TextSnapshot object for this DisplayObjectContainer instance.
-
- </apiDesc><example conref="examples\DisplayObjectContainer.textSnapshot.1.as" class="- topic/example "> The following example works only in the Flash authoring environment. Flex does not include any
- ways of adding static text to a file. To prepare the Flash file for this example, add one or more static text fields
- in the first frame of a movie. Then insert the following script into the first frame and run the file. The output
- will be the static text that you added:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- trace(this.textSnapshot.getText(0, this.textSnapshot.charCount));
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.text.xml#TextSnapshot" class="- topic/link "><linktext class="- topic/linktext ">flash.text.TextSnapshot</linktext></link></related-links></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:GraphicsGradientFill" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">GraphicsGradientFill</apiName><shortdesc class="- topic/shortdesc ">
- Defines a gradient fill.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiFinal class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiFinal "/><apiBaseInterface>flash.display:IGraphicsFill</apiBaseInterface><apiBaseInterface>flash.display:IGraphicsData</apiBaseInterface><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">Object</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Defines a gradient fill.
-
- <p class="- topic/p ">
- Use a GraphicsGradientFill object with the <codeph class="+ topic/ph pr-d/codeph ">Graphics.drawGraphicsData()</codeph> method.
- Drawing a GraphicsGradientFill object is the equivalent of calling the <codeph class="+ topic/ph pr-d/codeph ">Graphics.beginGradientFill()</codeph> method.
- </p>
-
- </apiDesc></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Graphics/beginGradientFill()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.beginGradientFill()</linktext></link><link href="flash.display.xml#Graphics/drawGraphicsData()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.drawGraphicsData()</linktext></link></related-links><apiConstructor id="flash.display:GraphicsGradientFill:GraphicsGradientFill" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation apiOperation/apiConstructor"><apiName class="- topic/title reference/title apiRef/apiName ">GraphicsGradientFill</apiName><shortdesc class="- topic/shortdesc ">
- Creates a new GraphicsGradientFill object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiConstructorDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail apiOperation/apiConstructorDetail"><apiConstructorDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiConstructorDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">type</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">String</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">linear</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A value from the GradientType class that
- specifies which gradient type to use: <codeph class="+ topic/ph pr-d/codeph ">GradientType.LINEAR</codeph> or
- <codeph class="+ topic/ph pr-d/codeph ">GradientType.RADIAL</codeph>.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">colors</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Array</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">An array of RGB hexadecimal color values used in the gradient; for example,
- red is 0xFF0000, blue is 0x0000FF, and so on. You can specify up to 15 colors.
- For each color, specify a corresponding value in the alphas and ratios parameters.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">alphas</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Array</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">An array of alpha values for the corresponding colors in the colors array;
- valid values are 0 to 1. If the value is less than 0, 0 is used. If the value is
- greater than 1, 1 is used.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">ratios</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Array</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">An array of color distribution ratios; valid values are 0-255. This value
- defines the percentage of the width where the color is sampled at 100%. The value 0 represents
- the left position in the gradient box, and 255 represents the right position in the
- gradient box.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">matrix</apiItemName><apiType value="any" name="type" class="- topic/state reference/state apiRef/apiType "/><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A transformation matrix as defined by the
- flash.geom.Matrix class. The flash.geom.Matrix class includes a
- <codeph class="+ topic/ph pr-d/codeph ">createGradientBox()</codeph> method, which lets you conveniently set up
- the matrix for use with the <codeph class="+ topic/ph pr-d/codeph ">beginGradientFill()</codeph> method.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">spreadMethod</apiItemName><apiType value="any" name="type" class="- topic/state reference/state apiRef/apiType "/><apiData class="- topic/ph reference/ph apiRef/apiData ">pad</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A value from the SpreadMethod class that
- specifies which spread method to use, either: <codeph class="+ topic/ph pr-d/codeph ">SpreadMethod.PAD</codeph>,
- <codeph class="+ topic/ph pr-d/codeph ">SpreadMethod.REFLECT</codeph>, or <codeph class="+ topic/ph pr-d/codeph ">SpreadMethod.REPEAT</codeph>.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">interpolationMethod</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">String</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">rgb</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A value from the InterpolationMethod class that
- specifies which value to use: <codeph class="+ topic/ph pr-d/codeph ">InterpolationMethod.LINEAR_RGB</codeph> or
- <codeph class="+ topic/ph pr-d/codeph ">InterpolationMethod.RGB</codeph>
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">focalPointRatio</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Number</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">0.0</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A number that controls the
- location of the focal point of the gradient. A value of 0 sets the focal point in the center. A value of 1
- sets the focal point at one border of the gradient circle. A value of -1 sets the focal point
- at the other border of the gradient circle. A value less than -1 or greater than
- 1 is rounded to -1 or 1, respectively.
-
- </apiDesc></apiParam></apiConstructorDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Creates a new GraphicsGradientFill object.
-
- </apiDesc></apiConstructorDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Graphics/beginGradientFill()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.beginGradientFill()</linktext></link><link href="flash.display.xml#GradientType" class="- topic/link "><linktext class="- topic/linktext ">flash.display.GradientType</linktext></link><link href="flash.geom.xml#Matrix" class="- topic/link "><linktext class="- topic/linktext ">flash.geom.Matrix</linktext></link><link href="flash.display.xml#SpreadMethod" class="- topic/link "><linktext class="- topic/linktext ">flash.display.SpreadMethod</linktext></link><link href="flash.display.xml#InterpolationMethod" class="- topic/link "><linktext class="- topic/linktext ">flash.display.InterpolationMethod</linktext></link></related-links></apiConstructor><apiValue id="flash.display:GraphicsGradientFill:alphas" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">alphas</apiName><shortdesc class="- topic/shortdesc ">
- An array of alpha values for the corresponding colors in the colors array.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Array</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- An array of alpha values for the corresponding colors in the colors array.
- Valid values are between 0 and 1. If the value is less than 0, 0 is used. If the value is
- greater than 1, 1 is used.
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:GraphicsGradientFill:colors" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">colors</apiName><shortdesc class="- topic/shortdesc ">
- An array of RGB hexadecimal color values to use in the gradient.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Array</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- An array of RGB hexadecimal color values to use in the gradient. For example,
- red is 0xFF0000, blue is 0x0000FF, and so on. You can specify up to 15 colors.
- For each color, specify a corresponding value in the alphas and ratios properties.
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:GraphicsGradientFill:focalPointRatio" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">focalPointRatio</apiName><shortdesc class="- topic/shortdesc ">
- A number that controls the
- location of the focal point of the gradient.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- A number that controls the
- location of the focal point of the gradient. A value of 0 sets the focal point in the center. A value of 1
- means that the focal point is at one border of the gradient circle.A value of -1 sets the focal point
- at the other border of the gradient circle. A value of less than -1 or greater than
- 1 is rounded to -1 or 1, respectively. For example, the following
- shows a <codeph class="+ topic/ph pr-d/codeph ">focalPointRatio</codeph> set to 0.75:
-
- <p class="- topic/p "><adobeimage alt="radial gradient with focalPointRatio set to 0.75" href="../../images/radial_sketch.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/> </p>
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:GraphicsGradientFill:matrix" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">matrix</apiName><shortdesc class="- topic/shortdesc ">
- A transformation matrix as defined by the
- Matrix class.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.geom:Matrix</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- A transformation matrix as defined by the
- Matrix class. The flash.geom.Matrix class includes a
- <codeph class="+ topic/ph pr-d/codeph ">createGradientBox()</codeph> method to set up
- the matrix for use with the <codeph class="+ topic/ph pr-d/codeph ">beginGradientFill()</codeph> method.
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.geom.xml#Matrix/createGradientBox()" class="- topic/link "><linktext class="- topic/linktext ">flash.geom.Matrix.createGradientBox()</linktext></link></related-links></apiValue><apiValue id="flash.display:GraphicsGradientFill:ratios" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">ratios</apiName><shortdesc class="- topic/shortdesc ">
- An array of color distribution ratios.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Array</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- An array of color distribution ratios. Valid values are between 0 and 255. This value
- defines the percentage of the width where the color is sampled at 100%. The value 0 represents
- the left position in the gradient box, and the value 255 represents the right position in the
- gradient box.
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> This value represents positions in the gradient box, not the
- coordinate space of the final gradient which can be wider or thinner than the gradient box.
- Specify a value for corresponding to each value in the <codeph class="+ topic/ph pr-d/codeph ">colors</codeph> property. </p>
-
- <p class="- topic/p ">For example, for a linear gradient that includes two colors (blue and green) the
- following example illustrates the placement of the colors in the gradient based on different values
- in the <codeph class="+ topic/ph pr-d/codeph ">ratios</codeph> array:</p>
-
- <adobetable class="innertable"><tgroup cols="2" class="- topic/tgroup "><thead class="- topic/thead "><row class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">ratios</codeph></entry><entry class="- topic/entry ">Gradient</entry></row></thead><tbody class="- topic/tbody "><row class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">[0, 127]</codeph></entry><entry class="- topic/entry "><adobeimage alt="linear gradient blue to green with ratios 0 and 127" href="../../images/gradient-ratios-1.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry></row><row class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">[0, 255]</codeph></entry><entry class="- topic/entry "><adobeimage alt="linear gradient blue to green with ratios 0 and 255" href="../../images/gradient-ratios-2.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry></row><row class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">[127, 255]</codeph></entry><entry class="- topic/entry "><adobeimage alt="linear gradient blue to green with ratios 127 and 255" href="../../images/gradient-ratios-3.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></entry></row></tbody></tgroup></adobetable>
-
- <p class="- topic/p ">The values in the array must increase sequentially; for example,
- <codeph class="+ topic/ph pr-d/codeph ">[0, 63, 127, 190, 255]</codeph>. </p>
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:GraphicsGradientFill:interpolationMethod:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">interpolationMethod</apiName><shortdesc class="- topic/shortdesc ">
- A value from the InterpolationMethod class that
- specifies which value to use.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- A value from the InterpolationMethod class that
- specifies which value to use. Valid values are: <codeph class="+ topic/ph pr-d/codeph ">InterpolationMethod.LINEAR_RGB</codeph> or
- <codeph class="+ topic/ph pr-d/codeph ">InterpolationMethod.RGB</codeph>
-
- <p class="- topic/p ">For example, the following shows a simple linear gradient between two colors (with the <codeph class="+ topic/ph pr-d/codeph ">spreadMethod</codeph>
- parameter set to <codeph class="+ topic/ph pr-d/codeph ">SpreadMethod.REFLECT</codeph>). The different interpolation methods change
- the appearance as follows: </p>
-
- <adobetable class="+ topic/table adobe-d/adobetable "><tgroup cols="2" class="- topic/tgroup "><tbody class="- topic/tbody "><row class="- topic/row "><entry align="center" class="- topic/entry "> <adobeimage alt="linear gradient with InterpolationMethod.LINEAR_RGB" href="../../images/beginGradientFill_interp_linearrgb.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/> </entry><entry align="center" class="- topic/entry "> <adobeimage alt="linear gradient with InterpolationMethod.RGB" href="../../images/beginGradientFill_interp_rgb.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/> </entry></row><row class="- topic/row "><entry align="center" class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">InterpolationMethod.LINEAR_RGB</codeph></entry><entry align="center" class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">InterpolationMethod.RGB</codeph></entry></row></tbody></tgroup></adobetable>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#InterpolationMethod" class="- topic/link "><linktext class="- topic/linktext ">flash.display.InterpolationMethod</linktext></link></related-links></apiValue><apiValue id="flash.display:GraphicsGradientFill:spreadMethod:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">spreadMethod</apiName><shortdesc class="- topic/shortdesc ">
- A value from the SpreadMethod class that
- specifies which spread method to use.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- A value from the SpreadMethod class that
- specifies which spread method to use. Valid values are: <codeph class="+ topic/ph pr-d/codeph ">SpreadMethod.PAD</codeph>,
- <codeph class="+ topic/ph pr-d/codeph ">SpreadMethod.REFLECT</codeph>, or <codeph class="+ topic/ph pr-d/codeph ">SpreadMethod.REPEAT</codeph>.
-
- <p class="- topic/p ">For example, the following shows a simple linear gradient between two colors:</p>
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.geom.*
- import flash.display.*
- var fillType:String = GradientType.LINEAR;
- var colors:Array = [0xFF0000, 0x0000FF];
- var alphas:Array = [1, 1];
- var ratios:Array = [0x00, 0xFF];
- var matr:Matrix = new Matrix();
- matr.createGradientBox(20, 20, 0, 0, 0);
- var spreadMethod:String = SpreadMethod.PAD;
- this.graphics.beginGradientFill(fillType, colors, alphas, ratios, matr, spreadMethod);
- this.graphics.drawRect(0,0,100,100);
- </codeblock>
-
- <p class="- topic/p ">This example uses <codeph class="+ topic/ph pr-d/codeph ">SpreadMethod.PAD</codeph> for the spread method, and
- the gradient fill looks like the following:</p>
-
- <p class="- topic/p "><adobeimage alt="linear gradient with SpreadMethod.PAD" href="../../images/beginGradientFill_spread_pad.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- <p class="- topic/p ">If you use <codeph class="+ topic/ph pr-d/codeph ">SpreadMethod.REFLECT</codeph> for the spread method, the gradient fill
- looks like the following:</p>
-
- <p class="- topic/p "><adobeimage alt="linear gradient with SpreadMethod.REFLECT" href="../../images/beginGradientFill_spread_reflect.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- <p class="- topic/p ">If you use <codeph class="+ topic/ph pr-d/codeph ">SpreadMethod.REPEAT</codeph> for the spread method, the gradient fill
- looks like the following:</p>
-
- <p class="- topic/p "><adobeimage alt="linear gradient with SpreadMethod.REPEAT" href="../../images/beginGradientFill_spread_repeat.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#SpreadMethod" class="- topic/link "><linktext class="- topic/linktext ">flash.display.SpreadMethod</linktext></link></related-links></apiValue><apiValue id="flash.display:GraphicsGradientFill:type:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">type</apiName><shortdesc class="- topic/shortdesc ">
- A value from the GradientType class that
- specifies which gradient type to use.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- A value from the GradientType class that
- specifies which gradient type to use. Values are <codeph class="+ topic/ph pr-d/codeph ">GradientType.LINEAR</codeph> or
- <codeph class="+ topic/ph pr-d/codeph ">GradientType.RADIAL</codeph>.
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#GradientType" class="- topic/link "><linktext class="- topic/linktext ">flash.display.GradientType</linktext></link></related-links></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:Sprite" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">Sprite</apiName><shortdesc class="- topic/shortdesc ">
- The Sprite class is a basic display list building block: a display list node that can display
- graphics and can also contain children.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">The basic display object for ActionScript created objects.
-
-
- </apiTipText></apiTipTexts><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">flash.display:DisplayObjectContainer</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The Sprite class is a basic display list building block: a display list node that can display
- graphics and can also contain children.
-
- <p class="- topic/p ">A Sprite object is similar to a movie clip, but does not have a timeline. Sprite is an
- appropriate base class for objects that do not require timelines. For example, Sprite would be a
- logical base class for user interface (UI) components that typically do not use the timeline.</p>
-
- <p class="- topic/p ">The Sprite class is new in ActionScript 3.0. It provides an alternative to the functionality of
- the MovieClip class, which retains all the functionality of previous ActionScript releases to
- provide backward compatibility.</p>
-
- </apiDesc><example conref="examples\SpriteExample.as" class="- topic/example "> The following example uses the SpriteExample class to draw an
- orange square on the stage, and then dispatches events whenever the user clicks or drags the
- square. This task is accomplished by performing the following steps:
- <ol class="- topic/ol "><li class="- topic/li ">Declare the <codeph class="+ topic/ph pr-d/codeph ">size</codeph> property (100 x 100 pixels) and the background color
- (orange) for later use in drawing the square.</li><li class="- topic/li ">The constructor then creates a new <codeph class="+ topic/ph pr-d/codeph ">child</codeph> Sprite object and uses it to add
- two event listeners and their associated methods: <codeph class="+ topic/ph pr-d/codeph ">mouseDownHandler()</codeph> and
- <codeph class="+ topic/ph pr-d/codeph ">mouseUpHandler()</codeph>.</li><li class="- topic/li ">The <codeph class="+ topic/ph pr-d/codeph ">child</codeph> Sprite object is then passed to the
- <codeph class="+ topic/ph pr-d/codeph ">draw()</codeph> method, which draws the orange square.</li><li class="- topic/li ">The child is then placed on the display list by a call to the <codeph class="+ topic/ph pr-d/codeph ">addChild()</codeph>
- method. </li><li class="- topic/li ">The event listeners work as follows:
-
- <ul class="- topic/ul "><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">mouseDownHandler()</codeph>: when the user clicks the Sprite object,
- this method adds a mouseMove event listener, the <codeph class="+ topic/ph pr-d/codeph ">mouseMoveHandler()</codeph> method,
- which processes the mouse moves. Then the <codeph class="+ topic/ph pr-d/codeph ">startDrag()</codeph> method is called, which
- allows the Sprite object to be dragged.</li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">mouseUpHandler()</codeph>: when the mouse button is released, the mouseMove event listener
- is removed and the <codeph class="+ topic/ph pr-d/codeph ">stopDrag()</codeph> method is called, which freezes the orange square in
- place.</li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">mouseMoveHandler</codeph>: as long as the left mouse button is being held down, this
- method instructs the player to continuously redraw the orange square.</li></ul>
- </li></ol>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note: </b>Each of the event listener methods declares a local <codeph class="+ topic/ph pr-d/codeph ">sprite</codeph>
- variable, which is assigned the <codeph class="+ topic/ph pr-d/codeph ">target</codeph> property of the event.</p>
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- package {
- import flash.display.Sprite;
- import flash.events.*;
- public class SpriteExample extends Sprite {
- private var size:uint = 100;
- private var bgColor:uint = 0xFFCC00;
- public function SpriteExample() {
- var child:Sprite = new Sprite();
- child.addEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler);
- child.addEventListener(MouseEvent.MOUSE_UP, mouseUpHandler);
- draw(child);
- addChild(child);
- }
- private function mouseDownHandler(event:MouseEvent):void {
- trace("mouseDownHandler");
- var sprite:Sprite = Sprite(event.target);
- sprite.addEventListener(MouseEvent.MOUSE_MOVE, mouseMoveHandler);
- sprite.startDrag();
- }
- private function mouseUpHandler(event:MouseEvent):void {
- trace("mouseUpHandler");
- var sprite:Sprite = Sprite(event.target);
- sprite.removeEventListener(MouseEvent.MOUSE_MOVE, mouseMoveHandler);
- sprite.stopDrag();
- }
- private function mouseMoveHandler(event:MouseEvent):void {
- trace("mouseMoveHandler");
- event.updateAfterEvent();
- }
- private function draw(sprite:Sprite):void {
- sprite.graphics.beginFill(bgColor);
- sprite.graphics.drawRect(0, 0, size, size);
- sprite.graphics.endFill();
- }
- }
- }
- </codeblock></example></apiClassifierDetail><apiConstructor id="flash.display:Sprite:Sprite" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation apiOperation/apiConstructor"><apiName class="- topic/title reference/title apiRef/apiName ">Sprite</apiName><shortdesc class="- topic/shortdesc ">
- Creates a new Sprite instance.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiConstructorDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail apiOperation/apiConstructorDetail"><apiConstructorDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiConstructorDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/></apiConstructorDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Creates a new Sprite instance. After you create the Sprite instance, call the
- <codeph class="+ topic/ph pr-d/codeph ">DisplayObjectContainer.addChild()</codeph> or <codeph class="+ topic/ph pr-d/codeph ">DisplayObjectContainer.addChildAt()</codeph>
- method to add the Sprite to a parent DisplayObjectContainer.
-
- </apiDesc></apiConstructorDetail></apiConstructor><apiOperation id="flash.display:Sprite:startDrag" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">startDrag</apiName><shortdesc class="- topic/shortdesc ">
- Lets the user drag the specified sprite.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata><asCustoms class="+ topic/metadata adobe-api-d/asCustoms "><keyword class="- topic/keyword ">movieclip, movieclip.startDrag, startDrag
-
- </keyword></asCustoms></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">lockCenter</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">false</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Specifies whether the draggable sprite is locked to the center of
- the pointer position (<codeph class="+ topic/ph pr-d/codeph ">true</codeph>), or locked to the point where the user first clicked the
- sprite (<codeph class="+ topic/ph pr-d/codeph ">false</codeph>).
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">bounds</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Rectangle</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Value relative to the coordinates of the Sprite's parent that specify a constraint
- rectangle for the Sprite.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Lets the user drag the specified sprite. The sprite remains draggable until explicitly
- stopped through a call to the <codeph class="+ topic/ph pr-d/codeph ">Sprite.stopDrag()</codeph> method, or until
- another sprite is made draggable. Only one sprite is draggable at a time.
- <p class="- topic/p ">Three-dimensional display objects follow the pointer and
- <codeph class="+ topic/ph pr-d/codeph ">Sprite.startDrag()</codeph> moves the object within
- the three-dimensional plane defined by the display object. Or, if the display object is a two-dimensional object
- and the child of a three-dimensional object, the two-dimensional object
- moves within the three dimensional plane defined by the three-dimensional parent object.</p>
-
- </apiDesc><example conref="examples\Sprite.dropTarget.1.as" class="- topic/example "> The following example creates a <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> sprite and two <codeph class="+ topic/ph pr-d/codeph ">target</codeph>
- sprites. The <codeph class="+ topic/ph pr-d/codeph ">startDrag()</codeph> method is called on the <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> sprite when the user
- positions the cursor over the sprite and presses the mouse button, and the <codeph class="+ topic/ph pr-d/codeph ">stopDrag()</codeph> method
- is called when the user releases the mouse button. This lets the user drag the sprite. On release of the mouse
- button, the <codeph class="+ topic/ph pr-d/codeph ">mouseRelease()</codeph> method is called, which in turn traces the <codeph class="+ topic/ph pr-d/codeph ">name</codeph>
- of the <codeph class="+ topic/ph pr-d/codeph ">dropTarget</codeph> object — the one to which the user dragged the
- <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> sprite:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var circle:Sprite = new Sprite();
- circle.graphics.beginFill(0xFFCC00);
- circle.graphics.drawCircle(0, 0, 40);
- var target1:Sprite = new Sprite();
- target1.graphics.beginFill(0xCCFF00);
- target1.graphics.drawRect(0, 0, 100, 100);
- target1.name = "target1";
- var target2:Sprite = new Sprite();
- target2.graphics.beginFill(0xCCFF00);
- target2.graphics.drawRect(0, 200, 100, 100);
- target2.name = "target2";
- addChild(target1);
- addChild(target2);
- addChild(circle);
- circle.addEventListener(MouseEvent.MOUSE_DOWN, mouseDown)
- function mouseDown(event:MouseEvent):void {
- circle.startDrag();
- }
- circle.addEventListener(MouseEvent.MOUSE_UP, mouseReleased);
- function mouseReleased(event:MouseEvent):void {
- circle.stopDrag();
- trace(circle.dropTarget.name);
- }
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Sprite/dropTarget" class="- topic/link "><linktext class="- topic/linktext ">dropTarget</linktext></link><link href="flash.display.xml#Sprite/stopDrag()" class="- topic/link "><linktext class="- topic/linktext ">stopDrag()</linktext></link></related-links></apiOperation><apiOperation id="flash.display:Sprite:startTouchDrag" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">startTouchDrag</apiName><shortdesc class="- topic/shortdesc ">
- Lets the user drag the specified sprite on a touch-enabled device.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">touchPointID</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">An integer to assign to the touch point.
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">lockCenter</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">false</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Specifies whether the draggable sprite is locked to the center of
- the pointer position (<codeph class="+ topic/ph pr-d/codeph ">true</codeph>), or locked to the point where the user first clicked the
- sprite (<codeph class="+ topic/ph pr-d/codeph ">false</codeph>).
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">bounds</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Rectangle</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">Value relative to the coordinates of the Sprite's parent that specify a constraint
- rectangle for the Sprite.
-
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Lets the user drag the specified sprite on a touch-enabled device. The sprite remains draggable until explicitly
- stopped through a call to the <codeph class="+ topic/ph pr-d/codeph ">Sprite.stopTouchDrag()</codeph> method, or until
- another sprite is made draggable. Only one sprite is draggable at a time.
- <p class="- topic/p ">Three-dimensional display objects follow the pointer and
- <codeph class="+ topic/ph pr-d/codeph ">Sprite.startTouchDrag()</codeph> moves the object within
- the three-dimensional plane defined by the display object. Or, if the display object is a two-dimensional object
- and the child of a three-dimensional object, the two-dimensional object
- moves within the three dimensional plane defined by the three-dimensional parent object.</p>
-
- </apiDesc><example conref="examples\Sprite.startTouchDrag.as" class="- topic/example "> The following example shows functions using startTouchDrag and stopTouchDrag to handle the touchBegin and touchEnd events.
- The value for touchPointID is the value assigned to the event object. The bounds parameter is the rectangle defining the boundaries of
- the parent display object (bg is a display object containing MySprite).
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- MySprite.addEventListener(TouchEvent.TOUCH_BEGIN, onTouchBegin);
- MySprite.addEventListener(TouchEvent.TOUCH_END, onTouchEnd);
- function onTouchBegin(e:TouchEvent) {
- e.target.startTouchDrag(e.touchPointID, false, bg.getRect(this));
- trace("touch begin");
-
- }
- function onTouchEnd(e:TouchEvent) {
- e.target.stopTouchDrag(e.touchPointID);
- trace("touch end");
- }
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Sprite/dropTarget" class="- topic/link "><linktext class="- topic/linktext ">dropTarget</linktext></link><link href="flash.display.xml#Sprite/stopTouchDrag()" class="- topic/link "><linktext class="- topic/linktext ">stopTouchDrag()</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link><link href="flash.events.xml#TouchEvent" class="- topic/link "><linktext class="- topic/linktext ">flash.events.TouchEvent</linktext></link></related-links></apiOperation><apiOperation id="flash.display:Sprite:stopDrag" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">stopDrag</apiName><shortdesc class="- topic/shortdesc ">
- Ends the startDrag() method.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata><asCustoms class="+ topic/metadata adobe-api-d/asCustoms "><keyword class="- topic/keyword ">sprite, movieclip.stopDrag, stopDrag
-
- </keyword></asCustoms></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Ends the <codeph class="+ topic/ph pr-d/codeph ">startDrag()</codeph> method. A sprite that was made draggable with the
- <codeph class="+ topic/ph pr-d/codeph ">startDrag()</codeph> method remains draggable until a
- <codeph class="+ topic/ph pr-d/codeph ">stopDrag()</codeph> method is added, or until another
- sprite becomes draggable. Only one sprite is draggable at a time.
-
- </apiDesc><example conref="examples\Sprite.dropTarget.1.as" class="- topic/example "> The following example creates a <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> sprite and two <codeph class="+ topic/ph pr-d/codeph ">target</codeph>
- sprites. The <codeph class="+ topic/ph pr-d/codeph ">startDrag()</codeph> method is called on the <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> sprite when the user
- positions the cursor over the sprite and presses the mouse button, and the <codeph class="+ topic/ph pr-d/codeph ">stopDrag()</codeph> method
- is called when the user releases the mouse button. This lets the user drag the sprite. On release of the mouse
- button, the <codeph class="+ topic/ph pr-d/codeph ">mouseRelease()</codeph> method is called, which in turn traces the <codeph class="+ topic/ph pr-d/codeph ">name</codeph>
- of the <codeph class="+ topic/ph pr-d/codeph ">dropTarget</codeph> object — the one to which the user dragged the
- <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> sprite:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var circle:Sprite = new Sprite();
- circle.graphics.beginFill(0xFFCC00);
- circle.graphics.drawCircle(0, 0, 40);
- var target1:Sprite = new Sprite();
- target1.graphics.beginFill(0xCCFF00);
- target1.graphics.drawRect(0, 0, 100, 100);
- target1.name = "target1";
- var target2:Sprite = new Sprite();
- target2.graphics.beginFill(0xCCFF00);
- target2.graphics.drawRect(0, 200, 100, 100);
- target2.name = "target2";
- addChild(target1);
- addChild(target2);
- addChild(circle);
- circle.addEventListener(MouseEvent.MOUSE_DOWN, mouseDown)
- function mouseDown(event:MouseEvent):void {
- circle.startDrag();
- }
- circle.addEventListener(MouseEvent.MOUSE_UP, mouseReleased);
- function mouseReleased(event:MouseEvent):void {
- circle.stopDrag();
- trace(circle.dropTarget.name);
- }
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Sprite/dropTarget" class="- topic/link "><linktext class="- topic/linktext ">dropTarget</linktext></link><link href="flash.display.xml#Sprite/startDrag()" class="- topic/link "><linktext class="- topic/linktext ">startDrag()</linktext></link></related-links></apiOperation><apiOperation id="flash.display:Sprite:stopTouchDrag" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation "><apiName class="- topic/title reference/title apiRef/apiName ">stopTouchDrag</apiName><shortdesc class="- topic/shortdesc ">
- Ends the startTouchDrag() method, for use with touch-enabled devices.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10.1" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="2" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiOperationDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail "><apiOperationDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiOperationDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiReturn class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiReturn "><apiType value="void" name="type" class="- topic/state reference/state apiRef/apiType "/></apiReturn><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">touchPointID</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">int</apiOperationClassifier><apiDesc class="- topic/section reference/section apiRef/apiDesc ">The integer assigned to the touch point in the <codeph class="+ topic/ph pr-d/codeph ">startTouchDrag</codeph> method.
- </apiDesc></apiParam></apiOperationDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Ends the <codeph class="+ topic/ph pr-d/codeph ">startTouchDrag()</codeph> method, for use with touch-enabled devices. A sprite that was made draggable with the
- <codeph class="+ topic/ph pr-d/codeph ">startTouchDrag()</codeph> method remains draggable until a
- <codeph class="+ topic/ph pr-d/codeph ">stopTouchDrag()</codeph> method is added, or until another
- sprite becomes draggable. Only one sprite is draggable at a time.
- </apiDesc><example conref="examples\Sprite.startTouchDrag.as" class="- topic/example "> The following example shows functions using startTouchDrag and stopTouchDrag to handle the touchBegin and touchEnd events.
- The value for touchPointID is the value assigned to the event object. The bounds parameter is the rectangle defining the boundaries of
- the parent display object (bg is a display object containing MySprite).
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- MySprite.addEventListener(TouchEvent.TOUCH_BEGIN, onTouchBegin);
- MySprite.addEventListener(TouchEvent.TOUCH_END, onTouchEnd);
- function onTouchBegin(e:TouchEvent) {
- e.target.startTouchDrag(e.touchPointID, false, bg.getRect(this));
- trace("touch begin");
-
- }
- function onTouchEnd(e:TouchEvent) {
- e.target.stopTouchDrag(e.touchPointID);
- trace("touch end");
- }
- </codeblock></example></apiOperationDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Sprite/dropTarget" class="- topic/link "><linktext class="- topic/linktext ">dropTarget</linktext></link><link href="flash.display.xml#Sprite/startTouchDrag()" class="- topic/link "><linktext class="- topic/linktext ">startTouchDrag()</linktext></link><link href="flash.ui.xml#Multitouch" class="- topic/link "><linktext class="- topic/linktext ">flash.ui.Multitouch</linktext></link><link href="flash.events.xml#TouchEvent" class="- topic/link "><linktext class="- topic/linktext ">flash.events.TouchEvent</linktext></link></related-links></apiOperation><apiValue id="flash.display:Sprite:buttonMode:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">buttonMode</apiName><shortdesc class="- topic/shortdesc ">
- Specifies the button mode of this sprite.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Specifies the button mode of this sprite.
-
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies the button mode of this sprite. If <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, this
- sprite behaves as a button, which means that it triggers the display
- of the hand cursor when the pointer passes over the sprite and can
- receive a <codeph class="+ topic/ph pr-d/codeph ">click</codeph> event if the enter or space keys are pressed
- when the sprite has focus. You can suppress the display of the hand cursor
- by setting the <codeph class="+ topic/ph pr-d/codeph ">useHandCursor</codeph> property to <codeph class="+ topic/ph pr-d/codeph ">false</codeph>,
- in which case the pointer is displayed.
-
- <p class="- topic/p ">Although it is better to use the SimpleButton class to create buttons,
- you can use the <codeph class="+ topic/ph pr-d/codeph ">buttonMode</codeph> property to give a sprite
- some button-like functionality. To include a sprite in the tab order,
- set the <codeph class="+ topic/ph pr-d/codeph ">tabEnabled</codeph> property (inherited from the
- InteractiveObject class and <codeph class="+ topic/ph pr-d/codeph ">false</codeph> by default) to
- <codeph class="+ topic/ph pr-d/codeph ">true</codeph>. Additionally, consider whether you want
- the children of your sprite to be user input enabled. Most buttons
- do not enable user input interactivity for their child objects because
- it confuses the event flow. To disable user input interactivity for all child
- objects, you must set the <codeph class="+ topic/ph pr-d/codeph ">mouseChildren</codeph> property (inherited
- from the DisplayObjectContainer class) to <codeph class="+ topic/ph pr-d/codeph ">false</codeph>.</p>
-
- <p class="- topic/p ">If you use the <codeph class="+ topic/ph pr-d/codeph ">buttonMode</codeph> property with the MovieClip class (which is a
- subclass of the Sprite class), your button might have some added
- functionality. If you include frames labeled _up, _over, and _down,
- Flash Player provides automatic state changes (functionality
- similar to that provided in previous versions of ActionScript for movie
- clips used as buttons). These automatic state changes are
- not available for sprites, which have no timeline, and thus no frames
- to label. </p>
-
- </apiDesc><example conref="examples\Sprite.buttonMode.1.as" class="- topic/example "> The following example creates two sprites and sets the <codeph class="+ topic/ph pr-d/codeph ">buttonMode</codeph>
- property to <codeph class="+ topic/ph pr-d/codeph ">true</codeph> for one and <codeph class="+ topic/ph pr-d/codeph ">false</codeph> for the other. When you compile
- and run the application, both sprites respond to mouse events, but only the one in which
- <codeph class="+ topic/ph pr-d/codeph ">buttonMode</codeph> is set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph> uses the hand cursor and is included
- in the tab order:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var circle1:Sprite = new Sprite();
- circle1.graphics.beginFill(0xFFCC00);
- circle1.graphics.drawCircle(40, 40, 40);
- circle1.buttonMode = true;
- circle1.addEventListener(MouseEvent.CLICK, clicked);
- var circle2:Sprite = new Sprite();
- circle2.graphics.beginFill(0xFFCC00);
- circle2.graphics.drawCircle(120, 40, 40);
- circle2.buttonMode = false;
- circle2.addEventListener(MouseEvent.CLICK, clicked);
- function clicked(event:MouseEvent):void {
- trace ("Click!");
- }
- addChild(circle1);
- addChild(circle2);
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#SimpleButton" class="- topic/link "><linktext class="- topic/linktext ">SimpleButton</linktext></link><link href="flash.display.xml#Sprite/useHandCursor" class="- topic/link "><linktext class="- topic/linktext ">Sprite.useHandCursor</linktext></link><link href="flash.display.xml#InteractiveObject/tabEnabled" class="- topic/link "><linktext class="- topic/linktext ">InteractiveObject.tabEnabled</linktext></link><link href="flash.display.xml#DisplayObjectContainer/mouseChildren" class="- topic/link "><linktext class="- topic/linktext ">DisplayObjectContainer.mouseChildren</linktext></link></related-links></apiValue><apiValue id="flash.display:Sprite:dropTarget:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">dropTarget</apiName><shortdesc class="- topic/shortdesc ">
- Specifies the display object over which the sprite is being dragged, or on
- which the sprite was dropped.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata><asCustoms class="+ topic/metadata adobe-api-d/asCustoms "><keyword class="- topic/keyword ">Sprite, Sprite.dropTarget, dropTarget
-
- </keyword></asCustoms></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:DisplayObject</apiValueClassifier><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Specifies the DisplayObject over which the sprite is being dragged, or on which the
- sprite was dropped.
-
-
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies the display object over which the sprite is being dragged, or on
- which the sprite was dropped.
-
- </apiDesc><example conref="examples\Sprite.dropTarget.1.as" class="- topic/example "> The following example creates a <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> sprite and two <codeph class="+ topic/ph pr-d/codeph ">target</codeph>
- sprites. The <codeph class="+ topic/ph pr-d/codeph ">startDrag()</codeph> method is called on the <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> sprite when the user
- positions the cursor over the sprite and presses the mouse button, and the <codeph class="+ topic/ph pr-d/codeph ">stopDrag()</codeph> method
- is called when the user releases the mouse button. This lets the user drag the sprite. On release of the mouse
- button, the <codeph class="+ topic/ph pr-d/codeph ">mouseRelease()</codeph> method is called, which in turn traces the <codeph class="+ topic/ph pr-d/codeph ">name</codeph>
- of the <codeph class="+ topic/ph pr-d/codeph ">dropTarget</codeph> object — the one to which the user dragged the
- <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> sprite:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var circle:Sprite = new Sprite();
- circle.graphics.beginFill(0xFFCC00);
- circle.graphics.drawCircle(0, 0, 40);
- var target1:Sprite = new Sprite();
- target1.graphics.beginFill(0xCCFF00);
- target1.graphics.drawRect(0, 0, 100, 100);
- target1.name = "target1";
- var target2:Sprite = new Sprite();
- target2.graphics.beginFill(0xCCFF00);
- target2.graphics.drawRect(0, 200, 100, 100);
- target2.name = "target2";
- addChild(target1);
- addChild(target2);
- addChild(circle);
- circle.addEventListener(MouseEvent.MOUSE_DOWN, mouseDown)
- function mouseDown(event:MouseEvent):void {
- circle.startDrag();
- }
- circle.addEventListener(MouseEvent.MOUSE_UP, mouseReleased);
- function mouseReleased(event:MouseEvent):void {
- circle.stopDrag();
- trace(circle.dropTarget.name);
- }
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Sprite/startDrag()" class="- topic/link "><linktext class="- topic/linktext ">startDrag()</linktext></link><link href="flash.display.xml#Sprite/stopDrag()" class="- topic/link "><linktext class="- topic/linktext ">stopDrag()</linktext></link></related-links></apiValue><apiValue id="flash.display:Sprite:graphics:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">graphics</apiName><shortdesc class="- topic/shortdesc ">
- Specifies the Graphics object that belongs to this sprite where vector
- drawing commands can occur.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="read" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:Graphics</apiValueClassifier><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">Specifies a Graphics object.
-
-
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies the Graphics object that belongs to this sprite where vector
- drawing commands can occur.
-
- </apiDesc><example conref="examples\Sprite.graphics.1.as" class="- topic/example "> The following example creates a <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> sprite and uses its
- <codeph class="+ topic/ph pr-d/codeph ">graphics</codeph> property to draw a circle with a yellow (0xFFCC00) fill:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- var circle:Sprite = new Sprite();
- circle.graphics.beginFill(0xFFCC00);
- circle.graphics.drawCircle(40, 40, 40);
- addChild(circle);
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:Sprite:hitArea:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">hitArea</apiName><shortdesc class="- topic/shortdesc ">
- Designates another sprite to serve as the hit area for a sprite.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:Sprite</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Designates another sprite to serve as the hit area for a sprite. If the <codeph class="+ topic/ph pr-d/codeph ">hitArea</codeph>
- property does not exist or the value is <codeph class="+ topic/ph pr-d/codeph ">null</codeph> or <codeph class="+ topic/ph pr-d/codeph ">undefined</codeph>, the
- sprite itself is used as the hit area. The value of the <codeph class="+ topic/ph pr-d/codeph ">hitArea</codeph> property can
- be a reference to a Sprite object.
-
- <p class="- topic/p ">You can change the <codeph class="+ topic/ph pr-d/codeph ">hitArea</codeph> property at any time; the modified sprite immediately
- uses the new hit area behavior. The sprite designated as the hit area does not need to be
- visible; its graphical shape, although not visible, is still detected as the hit area.</p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> You must set to <codeph class="+ topic/ph pr-d/codeph ">false</codeph> the <codeph class="+ topic/ph pr-d/codeph ">mouseEnabled</codeph>
- property of the sprite designated as the hit area. Otherwise, your sprite button might
- not work because the sprite designated as the hit area receives the user input events instead
- of your sprite button.</p>
-
- </apiDesc><example conref="examples\Sprite.hitArea.1.as" class="- topic/example "> The following example creates a <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> sprite and a <codeph class="+ topic/ph pr-d/codeph ">square</codeph>
- sprite. The <codeph class="+ topic/ph pr-d/codeph ">square</codeph> sprite is the <codeph class="+ topic/ph pr-d/codeph ">hitArea</codeph> for the <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> sprite.
- So when the user clicks the <codeph class="+ topic/ph pr-d/codeph ">square</codeph> sprite, the <codeph class="+ topic/ph pr-d/codeph ">circle</codeph> sprite dispatches
- a <codeph class="+ topic/ph pr-d/codeph ">click</codeph> event:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var circle:Sprite = new Sprite();
- circle.graphics.beginFill(0xFFCC00);
- circle.graphics.drawCircle(0, 0, 40);
- var square:Sprite = new Sprite();
- square.graphics.beginFill(0xCCFF00);
- square.graphics.drawRect(200, 0, 100, 100);
- circle.hitArea = square;
- square.mouseEnabled = false;
- circle.addEventListener(MouseEvent.CLICK, clicked);
- function clicked(event:MouseEvent):void{
- trace(event.target == circle); // true
- trace(event.target == square); // false
- }
- addChild(circle);
- addChild(square);
- </codeblock></example></apiValueDetail></apiValue><apiValue id="flash.display:Sprite:soundTransform:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">soundTransform</apiName><shortdesc class="- topic/shortdesc ">
- Controls sound within this sprite.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.media:SoundTransform</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Controls sound within this sprite.
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> This property does not affect HTML content in an HTMLControl object (in Adobe AIR).</p>
-
- </apiDesc><example conref="examples\Sprite.soundTransform.1.as" class="- topic/example "> The following example creates a sprite named <codeph class="+ topic/ph pr-d/codeph ">container</codeph>
- and adds a Loader object to its child list. The Loader object loads a SWF file.
- When the user clicks the link in the <codeph class="+ topic/ph pr-d/codeph ">tf</codeph> text field <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, the
- <codeph class="+ topic/ph pr-d/codeph ">mute()</codeph> method sets the <codeph class="+ topic/ph pr-d/codeph ">volume</codeph> property of the
- <codeph class="+ topic/ph pr-d/codeph ">soundTransform</codeph> property of the <codeph class="+ topic/ph pr-d/codeph ">container</codeph> sprite:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.display.Loader;
- import flash.events.IOErrorEvent;
- import flash.events.MouseEvent;
- import flash.net.URLRequest;
- import flash.text.TextField;
- import flash.media.SoundTransform;
- var container:Sprite = new Sprite();
- addChild(container);
- var ldr:Loader = new Loader;
- var urlReq:URLRequest = new URLRequest("SoundPlayer.swf");
- ldr.load(urlReq);
- container.addChild(ldr);
- ldr.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, urlNotFound);
-
- var tf:TextField = new TextField();
- tf.htmlText = "<a href = 'event:Mute'>Mute / Unmute</a>";
- addChild(tf);
- var mySoundTransform:SoundTransform = new SoundTransform();
- mySoundTransform.volume = 1;
- tf.addEventListener(MouseEvent.CLICK, mute);
- function mute(event:MouseEvent):void {
- if (mySoundTransform.volume == 0) {
- mySoundTransform.volume = 1;
- } else {
- mySoundTransform.volume = 0;
- }
- container.soundTransform = mySoundTransform;
- }
- function urlNotFound(event:IOErrorEvent):void {
- trace("The URL was not found.");
- }
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.media.xml#SoundTransform" class="- topic/link "><linktext class="- topic/linktext ">flash.media.SoundTransform</linktext></link></related-links></apiValue><apiValue id="flash.display:Sprite:useHandCursor:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">useHandCursor</apiName><shortdesc class="- topic/shortdesc ">
- A Boolean value that indicates whether the pointing hand (hand cursor) appears when the pointer rolls
- over a sprite in which the buttonMode property is set to true.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.0" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier><apiTipTexts><apiTipText class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiTipText ">A Boolean value that indicates whether the pointing hand (hand cursor) appears when the
- pointer rolls over a sprite in which the buttonMode property is set to true.
-
- </apiTipText></apiTipTexts></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- A Boolean value that indicates whether the pointing hand (hand cursor) appears when the pointer rolls
- over a sprite in which the <codeph class="+ topic/ph pr-d/codeph ">buttonMode</codeph> property is set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.
- The default value of the <codeph class="+ topic/ph pr-d/codeph ">useHandCursor</codeph> property is <codeph class="+ topic/ph pr-d/codeph ">true</codeph>.
- If <codeph class="+ topic/ph pr-d/codeph ">useHandCursor</codeph> is set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, the pointing hand used for buttons
- appears when the pointer rolls over a button sprite. If <codeph class="+ topic/ph pr-d/codeph ">useHandCursor</codeph> is
- <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, the arrow pointer is used instead.
-
- <p class="- topic/p ">You can change the <codeph class="+ topic/ph pr-d/codeph ">useHandCursor</codeph> property at any time; the modified sprite
- immediately takes on the new cursor appearance. </p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> In Flex or Flash Builder, if your sprite has child sprites, you might want to
- set the <codeph class="+ topic/ph pr-d/codeph ">mouseChildren</codeph> property to <codeph class="+ topic/ph pr-d/codeph ">false</codeph>. For example, if you want a hand
- cursor to appear over a Flex <mx:Label> control, set the <codeph class="+ topic/ph pr-d/codeph ">useHandCursor</codeph> and
- <codeph class="+ topic/ph pr-d/codeph ">buttonMode</codeph> properties to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, and the <codeph class="+ topic/ph pr-d/codeph ">mouseChildren</codeph> property
- to <codeph class="+ topic/ph pr-d/codeph ">false</codeph>.</p>
-
- </apiDesc><example conref="examples\Sprite.useHandCursor.1.as" class="- topic/example "> The following example creates two sprites and sets the <codeph class="+ topic/ph pr-d/codeph ">buttonMode</codeph>
- property to <codeph class="+ topic/ph pr-d/codeph ">true</codeph> for both, yet it sets the <codeph class="+ topic/ph pr-d/codeph ">useHandCursor</codeph>
- property to <codeph class="+ topic/ph pr-d/codeph ">true</codeph> for one and <codeph class="+ topic/ph pr-d/codeph ">false</codeph> for the other. When you compile
- and run the application, both sprites respond as buttons (and are included in the tab order), but
- only the one in which <codeph class="+ topic/ph pr-d/codeph ">useHandCursor</codeph> is set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph> uses the hand cursor:
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- import flash.display.Sprite;
- import flash.events.MouseEvent;
- var circle1:Sprite = new Sprite();
- circle1.graphics.beginFill(0xFFCC00);
- circle1.graphics.drawCircle(40, 40, 40);
- circle1.buttonMode = true;
- circle1.useHandCursor = true;
- circle1.addEventListener(MouseEvent.CLICK, clicked);
- var circle2:Sprite = new Sprite();
- circle2.graphics.beginFill(0xFFCC00);
- circle2.graphics.drawCircle(120, 40, 40);
- circle2.buttonMode = true;
- circle2.useHandCursor = false;
- circle2.addEventListener(MouseEvent.CLICK, clicked);
- function clicked(event:MouseEvent):void {
- trace ("Click!");
- }
- addChild(circle1);
- addChild(circle2);
- </codeblock></example></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Sprite/buttonMode" class="- topic/link "><linktext class="- topic/linktext ">buttonMode</linktext></link><link href="flash.display.xml#DisplayObjectContainer/mouseChildren" class="- topic/link "><linktext class="- topic/linktext ">DisplayObjectContainer.mouseChildren</linktext></link></related-links></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:GraphicsBitmapFill" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">GraphicsBitmapFill</apiName><shortdesc class="- topic/shortdesc ">
- Defines a bitmap fill.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiFinal class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiFinal "/><apiBaseInterface>flash.display:IGraphicsFill</apiBaseInterface><apiBaseInterface>flash.display:IGraphicsData</apiBaseInterface><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">Object</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Defines a bitmap fill. The bitmap can be smoothed, repeated or tiled to fill
- the area; or manipulated using a transformation matrix.
- <p class="- topic/p ">
- Use a GraphicsBitmapFill object with the <codeph class="+ topic/ph pr-d/codeph ">Graphics.drawGraphicsData()</codeph> method.
- Drawing a GraphicsBitmapFill object is the equivalent of calling the <codeph class="+ topic/ph pr-d/codeph ">Graphics.beginBitmapFill()</codeph> method.
- </p>
-
- </apiDesc></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Graphics/drawGraphicsData()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.drawGraphicsData()</linktext></link><link href="flash.display.xml#Graphics/beginBitmapFill()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.beginBitmapFill()</linktext></link></related-links><apiConstructor id="flash.display:GraphicsBitmapFill:GraphicsBitmapFill" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation apiOperation/apiConstructor"><apiName class="- topic/title reference/title apiRef/apiName ">GraphicsBitmapFill</apiName><shortdesc class="- topic/shortdesc ">
- Creates a new GraphicsBitmapFill object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiConstructorDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail apiOperation/apiConstructorDetail"><apiConstructorDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiConstructorDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">bitmapData</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:BitmapData</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A transparent or opaque bitmap image that contains the bits to display.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">matrix</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.geom:Matrix</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A matrix object (of the flash.geom.Matrix class), which you use to
- define transformations on the bitmap.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">repeat</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">true</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, the bitmap image repeats in a tiled pattern. If
- <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, the bitmap image does not repeat, and the edges of the bitmap are
- used for any fill area that extends beyond the bitmap.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">smooth</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">false</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">If <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, upscaled bitmap images are rendered using a
- nearest-neighbor algorithm and appear pixelated. If <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, upscaled
- bitmap images are rendered using a bilinear algorithm. Rendering that uses the nearest-neighbor
- algorithm is usually faster.
-
- </apiDesc></apiParam></apiConstructorDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Creates a new GraphicsBitmapFill object.
-
- </apiDesc></apiConstructorDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Graphics/beginBitmapFill()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.beginBitmapFill()</linktext></link></related-links></apiConstructor><apiValue id="flash.display:GraphicsBitmapFill:bitmapData" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">bitmapData</apiName><shortdesc class="- topic/shortdesc ">
- A transparent or opaque bitmap image.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:BitmapData</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- A transparent or opaque bitmap image.
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#BitmapData" class="- topic/link "><linktext class="- topic/linktext ">flash.display.BitmapData</linktext></link></related-links></apiValue><apiValue id="flash.display:GraphicsBitmapFill:matrix" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">matrix</apiName><shortdesc class="- topic/shortdesc ">
- A matrix object (of the flash.geom.Matrix class) that
- defines transformations on the bitmap.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.geom:Matrix</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- A matrix object (of the flash.geom.Matrix class) that
- defines transformations on the bitmap. For example, the following matrix
- rotates a bitmap by 45 degrees (pi/4 radians):
-
- <codeblock xml:space="preserve" class="+ topic/pre pr-d/codeblock ">
- matrix = new flash.geom.Matrix();
- matrix.rotate(Math.PI / 4);
- </codeblock>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.geom.xml#Matrix" class="- topic/link "><linktext class="- topic/linktext ">flash.geom.Matrix</linktext></link></related-links></apiValue><apiValue id="flash.display:GraphicsBitmapFill:repeat" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">repeat</apiName><shortdesc class="- topic/shortdesc ">
- Specifies whether to repeat the bitmap image in a tiled pattern.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies whether to repeat the bitmap image in a tiled pattern.
-
- <p class="- topic/p ">
- If <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, the bitmap image repeats in a tiled pattern. If
- <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, the bitmap image does not repeat, and the outermost pixels along
- the edges of the bitmap are used for any fill area that extends beyond the bounds of the bitmap.</p>
-
- <p class="- topic/p ">For example, consider the following bitmap (a 20 x 20-pixel checkerboard pattern):</p>
-
- <p class="- topic/p "><adobeimage alt="20 by 20 pixel checkerboard" href="../../images/movieClip_beginBitmapFill_repeat_1.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- <p class="- topic/p ">When <codeph class="+ topic/ph pr-d/codeph ">repeat</codeph> is set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph> (as in the following example), the bitmap fill
- repeats the bitmap:</p>
-
- <p class="- topic/p "><adobeimage alt="60 by 60 pixel checkerboard" href="../../images/movieClip_beginBitmapFill_repeat_2.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- <p class="- topic/p ">When <codeph class="+ topic/ph pr-d/codeph ">repeat</codeph> is set to <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, the bitmap fill uses the edge
- pixels for the fill area outside the bitmap:</p>
-
- <p class="- topic/p "><adobeimage alt="60 by 60 pixel image with no repeating" href="../../images/movieClip_beginBitmapFill_repeat_3.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:GraphicsBitmapFill:smooth" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">smooth</apiName><shortdesc class="- topic/shortdesc ">
- Specifies whether to apply a smoothing algorithm to the bitmap image.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies whether to apply a smoothing algorithm to the bitmap image.
- <p class="- topic/p ">
- If <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, upscaled bitmap images are rendered by using a
- nearest-neighbor algorithm and look pixelated. If <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, upscaled
- bitmap images are rendered by using a bilinear algorithm. Rendering by using the nearest
- neighbor algorithm is usually faster.
- </p>
- </apiDesc></apiValueDetail></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:GraphicsStroke" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">GraphicsStroke</apiName><shortdesc class="- topic/shortdesc ">
- Defines a line style or stroke.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiFinal class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiFinal "/><apiBaseInterface>flash.display:IGraphicsStroke</apiBaseInterface><apiBaseInterface>flash.display:IGraphicsData</apiBaseInterface><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">Object</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Defines a line style or stroke.
-
- <p class="- topic/p ">
- Use a GraphicsStroke object with the <codeph class="+ topic/ph pr-d/codeph ">Graphics.drawGraphicsData()</codeph> method.
- Drawing a GraphicsStroke object is the equivalent of calling one of the methods of the Graphics
- class that sets the line style, such as the <codeph class="+ topic/ph pr-d/codeph ">Graphics.lineStyle()</codeph> method, the
- <codeph class="+ topic/ph pr-d/codeph ">Graphics.lineBitmapStyle()</codeph> method, or the <codeph class="+ topic/ph pr-d/codeph ">Graphics.lineGradientStyle()</codeph>
- method.
- </p>
-
- </apiDesc></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Graphics/lineStyle()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.lineStyle()</linktext></link><link href="flash.display.xml#Graphics/lineBitmapStyle()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.lineBitmapStyle()</linktext></link><link href="flash.display.xml#Graphics/lineGradientStyle()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.lineGradientStyle()</linktext></link><link href="flash.display.xml#Graphics/drawGraphicsData()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.drawGraphicsData()</linktext></link></related-links><apiConstructor id="flash.display:GraphicsStroke:GraphicsStroke" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation apiOperation/apiConstructor"><apiName class="- topic/title reference/title apiRef/apiName ">GraphicsStroke</apiName><shortdesc class="- topic/shortdesc ">
- Creates a new GraphicsStroke object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiConstructorDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail apiOperation/apiConstructorDetail"><apiConstructorDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiConstructorDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">thickness</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Number</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">unknown</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">An integer that indicates the thickness of the line in
- points; valid values are 0-255. If a number is not specified, or if the
- parameter is undefined, a line is not drawn. If a value of less than 0 is passed,
- the default is 0. The value 0 indicates hairline thickness; the maximum thickness
- is 255. If a value greater than 255 is passed, the default is 255.
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">pixelHinting</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Boolean</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">false</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A Boolean value that specifies whether to hint strokes
- to full pixels. This affects both the position of anchors of a curve and the line stroke size
- itself. With <codeph class="+ topic/ph pr-d/codeph ">pixelHinting</codeph> set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, Flash Player hints line widths
- to full pixel widths. With <codeph class="+ topic/ph pr-d/codeph ">pixelHinting</codeph> set to <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, disjoints can
- appear for curves and straight lines. For example, the following illustrations show how
- Flash Player renders two rounded rectangles that are identical, except that the
- <codeph class="+ topic/ph pr-d/codeph ">pixelHinting</codeph> parameter used in the <codeph class="+ topic/ph pr-d/codeph ">lineStyle()</codeph> method is set
- differently (the images are scaled by 200%, to emphasize the difference):
-
- <p class="- topic/p "><adobeimage alt="pixelHinting false and pixelHinting true" href="../../images/lineStyle_pixelHinting.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- <p class="- topic/p ">If a value is not supplied, the line does not use pixel hinting.</p>
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">scaleMode</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">String</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">normal</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A value from the LineScaleMode class that
- specifies which scale mode to use:
-
- <ul class="- topic/ul "><li class="- topic/li ">
- <codeph class="+ topic/ph pr-d/codeph ">LineScaleMode.NORMAL</codeph>—Always scale the line thickness when the object is scaled
- (the default).
- </li><li class="- topic/li ">
- <codeph class="+ topic/ph pr-d/codeph ">LineScaleMode.NONE</codeph>—Never scale the line thickness.
- </li><li class="- topic/li ">
- <codeph class="+ topic/ph pr-d/codeph ">LineScaleMode.VERTICAL</codeph>—Do not scale the line thickness if the object is scaled vertically
- <i class="+ topic/ph hi-d/i ">only</i>. For example, consider the following circles, drawn with a one-pixel line, and each with the
- <codeph class="+ topic/ph pr-d/codeph ">scaleMode</codeph> parameter set to <codeph class="+ topic/ph pr-d/codeph ">LineScaleMode.VERTICAL</codeph>. The circle on the left
- is scaled vertically only, and the circle on the right is scaled both vertically and horizontally:
-
- <p class="- topic/p "><adobeimage alt="A circle scaled vertically, and a circle scaled both vertically and horizontally." href="../../images/LineScaleMode_VERTICAL.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- </li><li class="- topic/li ">
- <codeph class="+ topic/ph pr-d/codeph ">LineScaleMode.HORIZONTAL</codeph>—Do not scale the line thickness if the object is scaled horizontally
- <i class="+ topic/ph hi-d/i ">only</i>. For example, consider the following circles, drawn with a one-pixel line, and each with the
- <codeph class="+ topic/ph pr-d/codeph ">scaleMode</codeph> parameter set to <codeph class="+ topic/ph pr-d/codeph ">LineScaleMode.HORIZONTAL</codeph>. The circle on the left
- is scaled horizontally only, and the circle on the right is scaled both vertically and horizontally:
-
- <p class="- topic/p "><adobeimage alt="A circle scaled horizontally, and a circle scaled both vertically and horizontally." href="../../images/LineScaleMode_HORIZONTAL.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- </li></ul>
-
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">caps</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">String</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">none</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A value from the CapsStyle class that specifies the type of caps at the end
- of lines. Valid values are: <codeph class="+ topic/ph pr-d/codeph ">CapsStyle.NONE</codeph>, <codeph class="+ topic/ph pr-d/codeph ">CapsStyle.ROUND</codeph>, and <codeph class="+ topic/ph pr-d/codeph ">CapsStyle.SQUARE</codeph>.
- If a value is not indicated, Flash uses round caps.
- <p class="- topic/p ">For example, the following illustrations show the different <codeph class="+ topic/ph pr-d/codeph ">capsStyle</codeph>
- settings. For each setting, the illustration shows a blue line with a thickness of 30 (for
- which the <codeph class="+ topic/ph pr-d/codeph ">capsStyle</codeph> applies), and a superimposed black line with a thickness of 1
- (for which no <codeph class="+ topic/ph pr-d/codeph ">capsStyle</codeph> applies):
- </p>
- <p class="- topic/p "><adobeimage alt="NONE, ROUND, and SQUARE" href="../../images/linecap.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">joints</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">String</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">round</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A value from the JointStyle class that specifies the type of joint appearance
- used at angles. Valid
- values are: <codeph class="+ topic/ph pr-d/codeph ">JointStyle.BEVEL</codeph>, <codeph class="+ topic/ph pr-d/codeph ">JointStyle.MITER</codeph>, and <codeph class="+ topic/ph pr-d/codeph ">JointStyle.ROUND</codeph>.
- If a value is not indicated, Flash uses round joints.
-
- <p class="- topic/p ">For example, the following illustrations show the different <codeph class="+ topic/ph pr-d/codeph ">joints</codeph>
- settings. For each setting, the illustration shows an angled blue line with a thickness of
- 30 (for which the <codeph class="+ topic/ph pr-d/codeph ">jointStyle</codeph> applies), and a superimposed angled black line with a
- thickness of 1 (for which no <codeph class="+ topic/ph pr-d/codeph ">jointStyle</codeph> applies):
- </p>
-
- <p class="- topic/p "><adobeimage alt="MITER, ROUND, and BEVEL" href="../../images/linejoin.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> For <codeph class="+ topic/ph pr-d/codeph ">joints</codeph> set to <codeph class="+ topic/ph pr-d/codeph ">JointStyle.MITER</codeph>,
- you can use the <codeph class="+ topic/ph pr-d/codeph ">miterLimit</codeph> parameter to limit the length of the miter.</p>
-
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">miterLimit</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">Number</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">3.0</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">A number that indicates the limit at which a miter is cut off.
- Valid values range from 1 to 255 (and values outside that range are rounded to 1 or 255).
- This value is only used if the <codeph class="+ topic/ph pr-d/codeph ">jointStyle</codeph>
- is set to <codeph class="+ topic/ph pr-d/codeph ">"miter"</codeph>. The
- <codeph class="+ topic/ph pr-d/codeph ">miterLimit</codeph> value represents the length that a miter can extend beyond the point
- at which the lines meet to form a joint. The value expresses a factor of the line
- <codeph class="+ topic/ph pr-d/codeph ">thickness</codeph>. For example, with a <codeph class="+ topic/ph pr-d/codeph ">miterLimit</codeph> factor of 2.5 and a
- <codeph class="+ topic/ph pr-d/codeph ">thickness</codeph> of 10 pixels, the miter is cut off at 25 pixels.
-
- <p class="- topic/p ">For example, consider the following angled lines, each drawn with a <codeph class="+ topic/ph pr-d/codeph ">thickness</codeph>
- of 20, but with <codeph class="+ topic/ph pr-d/codeph ">miterLimit</codeph> set to 1, 2, and 4. Superimposed are black reference
- lines showing the meeting points of the joints:</p>
-
- <p class="- topic/p "><adobeimage alt="lines with miterLimit set to 1, 2, and 4" href="../../images/miterLimit.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- <p class="- topic/p ">Notice that a given <codeph class="+ topic/ph pr-d/codeph ">miterLimit</codeph> value has a specific maximum angle
- for which the miter is cut off. The following table lists some examples:</p>
-
- <adobetable class="innertable"><tgroup cols="2" class="- topic/tgroup "><thead class="- topic/thead "><row class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">miterLimit</codeph> value:</entry><entry class="- topic/entry ">Angles smaller than this are cut off:</entry></row></thead><tbody class="- topic/tbody "><row class="- topic/row "><entry class="- topic/entry ">1.414</entry><entry class="- topic/entry ">90 degrees</entry></row><row class="- topic/row "><entry class="- topic/entry ">2</entry><entry class="- topic/entry ">60 degrees</entry></row><row class="- topic/row "><entry class="- topic/entry ">4</entry><entry class="- topic/entry ">30 degrees</entry></row><row class="- topic/row "><entry class="- topic/entry ">8</entry><entry class="- topic/entry ">15 degrees</entry></row></tbody></tgroup></adobetable>
- </apiDesc></apiParam><apiParam class="- topic/ph reference/ph apiRef/apiDefItem apiOperation/apiParam "><apiItemName class="- topic/keyword reference/keyword apiRef/apiItemName ">fill</apiItemName><apiOperationClassifier class="- topic/xref reference/xref apiRef/apiRelation apiOperation/apiOperationClassifier ">flash.display:IGraphicsFill</apiOperationClassifier><apiData class="- topic/ph reference/ph apiRef/apiData ">null</apiData><apiDesc class="- topic/section reference/section apiRef/apiDesc ">An IGraphicsFill instance containing data for filling a stroke. An IGraphicsFill
- instance can represent a series of fill commands.
-
- </apiDesc></apiParam></apiConstructorDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Creates a new GraphicsStroke object.
- </apiDesc></apiConstructorDetail><related-links class="- topic/related-links "><link href="flash.display.xml#LineScaleMode" class="- topic/link "><linktext class="- topic/linktext ">flash.display.LineScaleMode</linktext></link><link href="flash.display.xml#CapsStyle" class="- topic/link "><linktext class="- topic/linktext ">flash.display.CapsStyle</linktext></link><link href="flash.display.xml#JointStyle" class="- topic/link "><linktext class="- topic/linktext ">flash.display.JointStyle</linktext></link><link href="flash.display.xml#IGraphicsFill" class="- topic/link "><linktext class="- topic/linktext ">flash.display.IGraphicsFill</linktext></link></related-links></apiConstructor><apiValue id="flash.display:GraphicsStroke:fill" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">fill</apiName><shortdesc class="- topic/shortdesc ">
- Specifies the instance containing data for filling a stroke.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">flash.display:IGraphicsFill</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies the instance containing data for filling a stroke. An IGraphicsFill
- instance can represent a series of fill commands.
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#IGraphicsFill" class="- topic/link "><linktext class="- topic/linktext ">flash.display.IGraphicsFill</linktext></link></related-links></apiValue><apiValue id="flash.display:GraphicsStroke:miterLimit" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">miterLimit</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the limit at which a miter is cut off.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the limit at which a miter is cut off.
- Valid values range from 1 to 255 (and values outside that range are rounded to 1 or 255).
- This value is only used if the <codeph class="+ topic/ph pr-d/codeph ">jointStyle</codeph>
- is set to <codeph class="+ topic/ph pr-d/codeph ">"miter"</codeph>. The
- <codeph class="+ topic/ph pr-d/codeph ">miterLimit</codeph> value represents the length that a miter can extend beyond the point
- at which the lines meet to form a joint. The value expresses a factor of the line
- <codeph class="+ topic/ph pr-d/codeph ">thickness</codeph>. For example, with a <codeph class="+ topic/ph pr-d/codeph ">miterLimit</codeph> factor of 2.5 and a
- <codeph class="+ topic/ph pr-d/codeph ">thickness</codeph> of 10 pixels, the miter is cut off at 25 pixels.
-
- <p class="- topic/p ">For example, consider the following angled lines, each drawn with a <codeph class="+ topic/ph pr-d/codeph ">thickness</codeph>
- of 20, but with <codeph class="+ topic/ph pr-d/codeph ">miterLimit</codeph> set to 1, 2, and 4. Superimposed are black reference
- lines showing the meeting points of the joints:</p>
-
- <p class="- topic/p "><adobeimage alt="lines with miterLimit set to 1, 2, and 4" href="../../images/miterLimit.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- <p class="- topic/p ">Notice that a given <codeph class="+ topic/ph pr-d/codeph ">miterLimit</codeph> value has a specific maximum angle
- for which the miter is cut off. The following table lists some examples:</p>
-
- <adobetable class="innertable"><tgroup cols="2" class="- topic/tgroup "><thead class="- topic/thead "><row class="- topic/row "><entry class="- topic/entry "><codeph class="+ topic/ph pr-d/codeph ">miterLimit</codeph> value:</entry><entry class="- topic/entry ">Angles smaller than this are cut off:</entry></row></thead><tbody class="- topic/tbody "><row class="- topic/row "><entry class="- topic/entry ">1.414</entry><entry class="- topic/entry ">90 degrees</entry></row><row class="- topic/row "><entry class="- topic/entry ">2</entry><entry class="- topic/entry ">60 degrees</entry></row><row class="- topic/row "><entry class="- topic/entry ">4</entry><entry class="- topic/entry ">30 degrees</entry></row><row class="- topic/row "><entry class="- topic/entry ">8</entry><entry class="- topic/entry ">15 degrees</entry></row></tbody></tgroup></adobetable>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:GraphicsStroke:pixelHinting" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">pixelHinting</apiName><shortdesc class="- topic/shortdesc ">
- Specifies whether to hint strokes
- to full pixels.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Boolean</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies whether to hint strokes
- to full pixels. This affects both the position of anchors of a curve and the line stroke size
- itself. With <codeph class="+ topic/ph pr-d/codeph ">pixelHinting</codeph> set to <codeph class="+ topic/ph pr-d/codeph ">true</codeph>, Flash Player hints line widths
- to full pixel widths. With <codeph class="+ topic/ph pr-d/codeph ">pixelHinting</codeph> set to <codeph class="+ topic/ph pr-d/codeph ">false</codeph>, disjoints can
- appear for curves and straight lines. For example, the following illustrations show how
- Flash Player renders two rounded rectangles that are identical, except that the
- <codeph class="+ topic/ph pr-d/codeph ">pixelHinting</codeph> parameter used in the <codeph class="+ topic/ph pr-d/codeph ">lineStyle()</codeph> method is set
- differently (the images are scaled by 200%, to emphasize the difference):
-
- <p class="- topic/p "><adobeimage alt="pixelHinting false and pixelHinting true" href="../../images/lineStyle_pixelHinting.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:GraphicsStroke:thickness" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">thickness</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the thickness of the line in
- points; valid values are 0-255.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">Number</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the thickness of the line in
- points; valid values are 0-255. If a number is not specified, or if the
- parameter is undefined, a line is not drawn. If a value of less than 0 is passed,
- the default is 0. The value 0 indicates hairline thickness; the maximum thickness
- is 255. If a value greater than 255 is passed, the default is 255.
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:GraphicsStroke:caps:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">caps</apiName><shortdesc class="- topic/shortdesc ">
- Specifies the type of caps at the end
- of lines.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies the type of caps at the end
- of lines. Valid values are: <codeph class="+ topic/ph pr-d/codeph ">CapsStyle.NONE</codeph>, <codeph class="+ topic/ph pr-d/codeph ">CapsStyle.ROUND</codeph>, and <codeph class="+ topic/ph pr-d/codeph ">CapsStyle.SQUARE</codeph>.
- If a value is not indicated, Flash uses round caps.
- <p class="- topic/p ">For example, the following illustrations show the different <codeph class="+ topic/ph pr-d/codeph ">capsStyle</codeph>
- settings. For each setting, the illustration shows a blue line with a thickness of 30 (for
- which the <codeph class="+ topic/ph pr-d/codeph ">capsStyle</codeph> applies), and a superimposed black line with a thickness of 1
- (for which no <codeph class="+ topic/ph pr-d/codeph ">capsStyle</codeph> applies):
- </p>
- <p class="- topic/p "><adobeimage alt="NONE, ROUND, and SQUARE" href="../../images/linecap.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#CapsStyle" class="- topic/link "><linktext class="- topic/linktext ">flash.display.CapsStyle</linktext></link></related-links></apiValue><apiValue id="flash.display:GraphicsStroke:joints:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">joints</apiName><shortdesc class="- topic/shortdesc ">
- Specifies the type of joint appearance
- used at angles.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies the type of joint appearance
- used at angles. Valid
- values are: <codeph class="+ topic/ph pr-d/codeph ">JointStyle.BEVEL</codeph>, <codeph class="+ topic/ph pr-d/codeph ">JointStyle.MITER</codeph>, and <codeph class="+ topic/ph pr-d/codeph ">JointStyle.ROUND</codeph>.
- If a value is not indicated, Flash uses round joints.
-
- <p class="- topic/p ">For example, the following illustrations show the different <codeph class="+ topic/ph pr-d/codeph ">joints</codeph>
- settings. For each setting, the illustration shows an angled blue line with a thickness of
- 30 (for which the <codeph class="+ topic/ph pr-d/codeph ">jointStyle</codeph> applies), and a superimposed angled black line with a
- thickness of 1 (for which no <codeph class="+ topic/ph pr-d/codeph ">jointStyle</codeph> applies):
- </p>
-
- <p class="- topic/p "><adobeimage alt="MITER, ROUND, and BEVEL" href="../../images/linejoin.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- <p class="- topic/p "><b class="+ topic/ph hi-d/b ">Note:</b> For <codeph class="+ topic/ph pr-d/codeph ">joints</codeph> set to <codeph class="+ topic/ph pr-d/codeph ">JointStyle.MITER</codeph>,
- you can use the <codeph class="+ topic/ph pr-d/codeph ">miterLimit</codeph> parameter to limit the length of the miter.</p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#JointStyle" class="- topic/link "><linktext class="- topic/linktext ">flash.display.JointStyle</linktext></link></related-links></apiValue><apiValue id="flash.display:GraphicsStroke:scaleMode:get" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">scaleMode</apiName><shortdesc class="- topic/shortdesc ">
- Specifies the stroke thickness scaling.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiProperty class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiProperty "/><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiDynamic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiDynamic "/><apiValueAccess value="readwrite" class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiValueAccess "/><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Specifies the stroke thickness scaling. Valid values are:
-
- <ul class="- topic/ul "><li class="- topic/li ">
- <codeph class="+ topic/ph pr-d/codeph ">LineScaleMode.NORMAL</codeph>—Always scale the line thickness when the object is scaled
- (the default).
- </li><li class="- topic/li ">
- <codeph class="+ topic/ph pr-d/codeph ">LineScaleMode.NONE</codeph>—Never scale the line thickness.
- </li><li class="- topic/li ">
- <codeph class="+ topic/ph pr-d/codeph ">LineScaleMode.VERTICAL</codeph>—Do not scale the line thickness if the object is scaled vertically
- <i class="+ topic/ph hi-d/i ">only</i>. For example, consider the following circles, drawn with a one-pixel line, and each with the
- <codeph class="+ topic/ph pr-d/codeph ">scaleMode</codeph> parameter set to <codeph class="+ topic/ph pr-d/codeph ">LineScaleMode.VERTICAL</codeph>. The circle on the left
- is scaled vertically only, and the circle on the right is scaled both vertically and horizontally:
-
- <p class="- topic/p "><adobeimage alt="A circle scaled vertically, and a circle scaled both vertically and horizontally." href="../../images/LineScaleMode_VERTICAL.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- </li><li class="- topic/li ">
- <codeph class="+ topic/ph pr-d/codeph ">LineScaleMode.HORIZONTAL</codeph>—Do not scale the line thickness if the object is scaled horizontally
- <i class="+ topic/ph hi-d/i ">only</i>. For example, consider the following circles, drawn with a one-pixel line, and each with the
- <codeph class="+ topic/ph pr-d/codeph ">scaleMode</codeph> parameter set to <codeph class="+ topic/ph pr-d/codeph ">LineScaleMode.HORIZONTAL</codeph>. The circle on the left
- is scaled horizontally only, and the circle on the right is scaled both vertically and horizontally:
-
- <p class="- topic/p "><adobeimage alt="A circle scaled horizontally, and a circle scaled both vertically and horizontally." href="../../images/LineScaleMode_HORIZONTAL.jpg" placement="inline" class="+ topic/image adobe-d/adobeimage "/></p>
-
- </li></ul>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#LineScaleMode" class="- topic/link "><linktext class="- topic/linktext ">flash.display.LineScaleMode</linktext></link></related-links></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:GraphicsEndFill" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">GraphicsEndFill</apiName><shortdesc class="- topic/shortdesc ">
- Indicates the end of a graphics fill.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiFinal class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiFinal "/><apiBaseInterface>flash.display:IGraphicsFill</apiBaseInterface><apiBaseInterface>flash.display:IGraphicsData</apiBaseInterface><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">Object</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Indicates the end of a graphics fill. Use a GraphicsEndFill object with the <codeph class="+ topic/ph pr-d/codeph ">Graphics.drawGraphicsData()</codeph> method.
-
- <p class="- topic/p ">
- Drawing a GraphicsEndFill object is the equivalent of calling the <codeph class="+ topic/ph pr-d/codeph ">Graphics.endFill()</codeph> method.
- </p>
-
- </apiDesc></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Graphics/drawGraphicsData()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.drawGraphicsData()</linktext></link><link href="flash.display.xml#Graphics/endFill()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.endFill()</linktext></link></related-links><apiConstructor id="flash.display:GraphicsEndFill:GraphicsEndFill" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiOperation/apiOperation apiOperation/apiConstructor"><apiName class="- topic/title reference/title apiRef/apiName ">GraphicsEndFill</apiName><shortdesc class="- topic/shortdesc ">
- Creates an object to use with the Graphics.drawGraphicsData() method to end
- the fill, explicitly.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiConstructorDetail class="- topic/body reference/refbody apiRef/apiDetail apiOperation/apiOperationDetail apiOperation/apiConstructorDetail"><apiConstructorDef class="- topic/section reference/section apiRef/apiDef apiOperation/apiConstructorDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/></apiConstructorDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Creates an object to use with the <codeph class="+ topic/ph pr-d/codeph ">Graphics.drawGraphicsData()</codeph> method to end
- the fill, explicitly.
-
-
- </apiDesc></apiConstructorDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Graphics/drawGraphicsData()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.drawGraphicsData()</linktext></link><link href="flash.display.xml#Graphics/endFill()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Graphics.endFill()</linktext></link></related-links></apiConstructor></apiClassifier><apiClassifier languages="" id="flash.display:ShaderPrecision" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">ShaderPrecision</apiName><shortdesc class="- topic/shortdesc ">
- This class defines the constants that represent the possible values for
- the Shader class's precisionHint property.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiFinal class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiFinal "/><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">Object</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- This class defines the constants that represent the possible values for
- the Shader class's <codeph class="+ topic/ph pr-d/codeph ">precisionHint</codeph> property. Each constant
- represents one of the precision modes for executing shader operations.
-
- <p class="- topic/p ">The precision mode selection affects the following shader operations.
- These operations are faster on an Intel processor
- with the SSE instruction set:</p>
-
- <ul class="- topic/ul "><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">sin(x)</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">cos(x)</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">tan(x)</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">asin(x)</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">acos(x)</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">atan(x)</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">atan(x, y)</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">exp(x)</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">exp2(x)</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">log(x)</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">log2(x)</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">pow(x, y)</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">reciprocal(x)</codeph></li><li class="- topic/li "><codeph class="+ topic/ph pr-d/codeph ">sqrt(x)</codeph></li></ul>
-
- </apiDesc></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Shader/precisionHint" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Shader.precisionHint</linktext></link></related-links><apiValue id="flash.display:ShaderPrecision:FAST" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">FAST</apiName><shortdesc class="- topic/shortdesc ">
- Represents fast precision mode.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">fast</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Represents fast precision mode.
-
- <p class="- topic/p ">Fast precision mode is designed for
- maximum performance but does not work consistently on different platforms
- and individual CPU configurations. In many cases, this level of precision
- is sufficient to create graphic effects without visible artifacts.</p>
-
- <p class="- topic/p ">It is usually faster to use fast precision mode than to use lookup tables.</p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Shader/precisionHint" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Shader.precisionHint</linktext></link></related-links></apiValue><apiValue id="flash.display:ShaderPrecision:FULL" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">FULL</apiName><shortdesc class="- topic/shortdesc ">
- Represents full precision mode.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">full</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Represents full precision mode.
-
- <p class="- topic/p ">In full precision mode, the shader computes all math
- operations to the full width of the IEEE 32-bit floating standard. This mode provides
- consistent behavior on all platforms. In this mode, some math operations such
- as trigonometric and exponential functions can be slow.</p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#Shader/precisionHint" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Shader.precisionHint</linktext></link></related-links></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:BlendMode" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">BlendMode</apiName><shortdesc class="- topic/shortdesc ">
- A class that provides constant values for visual blend mode effects.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiFinal class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiFinal "/><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">Object</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- A class that provides constant values for visual blend mode effects. These constants are used in the following:
- <ul class="- topic/ul "><li class="- topic/li "> The <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property of the flash.display.DisplayObject class.</li><li class="- topic/li "> The <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> parameter of the <codeph class="+ topic/ph pr-d/codeph ">draw()</codeph> method of the
- flash.display.BitmapData class</li></ul>
- </apiDesc></apiClassifierDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject/blendMode" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObject.blendMode</linktext></link><link href="flash.display.xml#BitmapData/draw()" class="- topic/link "><linktext class="- topic/linktext ">flash.display.BitmapData.draw()</linktext></link></related-links><apiValue id="flash.display:BlendMode:ADD" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">ADD</apiName><shortdesc class="- topic/shortdesc ">
- Adds the values of the constituent colors of the display object to the colors of its background, applying a
- ceiling of 0xFF.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">add</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Adds the values of the constituent colors of the display object to the colors of its background, applying a
- ceiling of 0xFF. This setting is commonly used for animating a lightening dissolve between
- two objects.
- <p class="- topic/p ">For example, if the display object has a pixel with an RGB value of 0xAAA633, and the background
- pixel has an RGB value of 0xDD2200, the resulting RGB value for the displayed pixel is
- 0xFFC833 (because 0xAA + 0xDD > 0xFF, 0xA6 + 0x22 = 0xC8, and 0x33 + 0x00 = 0x33).</p>
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:BlendMode:ALPHA" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">ALPHA</apiName><shortdesc class="- topic/shortdesc ">
- Applies the alpha value of each pixel of the display object to the background.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">alpha</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Applies the alpha value of each pixel of the display object to the background.
- This requires the <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property of the parent display object be set to
- <codeph class="+ topic/ph pr-d/codeph ">flash.display.BlendMode.LAYER</codeph>.
- <p class="- topic/p ">Not supported under GPU rendering.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:BlendMode:DARKEN" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">DARKEN</apiName><shortdesc class="- topic/shortdesc ">
- Selects the darker of the constituent colors of the display object and the colors of the background (the
- colors with the smaller values).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">darken</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Selects the darker of the constituent colors of the display object and the colors of the background (the
- colors with the smaller values). This setting is commonly used for superimposing type.
- <p class="- topic/p ">For example, if the display object has a pixel with an RGB value of 0xFFCC33, and the background
- pixel has an RGB value of 0xDDF800, the resulting RGB value for the displayed pixel is
- 0xDDCC00 (because 0xFF > 0xDD, 0xCC < 0xF8, and 0x33 > 0x00 = 33).</p>
- <p class="- topic/p ">Not supported under GPU rendering.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:BlendMode:DIFFERENCE" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">DIFFERENCE</apiName><shortdesc class="- topic/shortdesc ">
- Compares the constituent colors of the display object with the colors of its background, and subtracts
- the darker of the values of the two constituent colors from the lighter value.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">difference</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Compares the constituent colors of the display object with the colors of its background, and subtracts
- the darker of the values of the two constituent colors from the lighter value. This setting is commonly
- used for more vibrant colors.
- <p class="- topic/p ">For example, if the display object has a pixel with an RGB value of 0xFFCC33, and the background
- pixel has an RGB value of 0xDDF800, the resulting RGB value for the displayed pixel is
- 0x222C33 (because 0xFF - 0xDD = 0x22, 0xF8 - 0xCC = 0x2C, and 0x33 - 0x00 = 0x33).</p>
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:BlendMode:ERASE" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">ERASE</apiName><shortdesc class="- topic/shortdesc ">
- Erases the background based on the alpha value of the display object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">erase</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Erases the background based on the alpha value of the display object. This process requires
- that the <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property of the parent display object be set to
- <codeph class="+ topic/ph pr-d/codeph ">flash.display.BlendMode.LAYER</codeph>.
- <p class="- topic/p ">Not supported under GPU rendering.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:BlendMode:HARDLIGHT" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">HARDLIGHT</apiName><shortdesc class="- topic/shortdesc ">
- Adjusts the color of each pixel based on the darkness of the display object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">hardlight</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Adjusts the color of each pixel based on the darkness of the display object.
- If the display object is lighter than 50% gray, the display object and background colors are
- screened, which results in a lighter color. If the display object is darker than 50% gray,
- the colors are multiplied, which results in a darker color.
- This setting is commonly used for shading effects.
- <p class="- topic/p ">Not supported under GPU rendering.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:BlendMode:INVERT" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">INVERT</apiName><shortdesc class="- topic/shortdesc ">
- Inverts the background.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">invert</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Inverts the background.
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:BlendMode:LAYER" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">LAYER</apiName><shortdesc class="- topic/shortdesc ">
- Forces the creation of a transparency group for the display object.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">layer</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Forces the creation of a transparency group for the display object. This means that the display
- object is precomposed in a temporary buffer before it is processed further. The precomposition is done
- automatically if the display object is precached by means of bitmap caching or if the display object is
- a display object container that has at least one child object with a <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph>
- setting other than <codeph class="+ topic/ph pr-d/codeph ">"normal"</codeph>.
- <p class="- topic/p ">Not supported under GPU rendering.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:BlendMode:LIGHTEN" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">LIGHTEN</apiName><shortdesc class="- topic/shortdesc ">
- Selects the lighter of the constituent colors of the display object and the colors of the background (the
- colors with the larger values).</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">lighten</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Selects the lighter of the constituent colors of the display object and the colors of the background (the
- colors with the larger values). This setting is commonly used for superimposing type.
- <p class="- topic/p ">For example, if the display object has a pixel with an RGB value of 0xFFCC33, and the background
- pixel has an RGB value of 0xDDF800, the resulting RGB value for the displayed pixel is
- 0xFFF833 (because 0xFF > 0xDD, 0xCC < 0xF8, and 0x33 > 0x00 = 33).</p>
- <p class="- topic/p ">Not supported under GPU rendering.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:BlendMode:MULTIPLY" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">MULTIPLY</apiName><shortdesc class="- topic/shortdesc ">
- Multiplies the values of the display object constituent colors by the constituent colors of
- the background color, and normalizes by dividing by 0xFF,
- resulting in darker colors.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">multiply</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Multiplies the values of the display object constituent colors by the constituent colors of
- the background color, and normalizes by dividing by 0xFF,
- resulting in darker colors. This setting is commonly used for shadows and depth effects.
- <p class="- topic/p ">For example, if a constituent color (such as red) of one pixel in the display object and the
- corresponding color of the pixel in the background both have the value 0x88, the multiplied
- result is 0x4840. Dividing by 0xFF yields a value of 0x48 for that constituent color,
- which is a darker shade than the color of the display object or the color of the background.</p>
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:BlendMode:NORMAL" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">NORMAL</apiName><shortdesc class="- topic/shortdesc ">
- The display object appears in front of the background.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">normal</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The display object appears in front of the background. Pixel values of the display object
- override the pixel values of the background. Where the display object is transparent, the
- background is visible.
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:BlendMode:OVERLAY" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">OVERLAY</apiName><shortdesc class="- topic/shortdesc ">
- Adjusts the color of each pixel based on the darkness of the background.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">overlay</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Adjusts the color of each pixel based on the darkness of the background.
- If the background is lighter than 50% gray, the display object and background colors are
- screened, which results in a lighter color. If the background is darker than 50% gray,
- the colors are multiplied, which results in a darker color.
- This setting is commonly used for shading effects.
- <p class="- topic/p ">Not supported under GPU rendering.</p>
-
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:BlendMode:SCREEN" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">SCREEN</apiName><shortdesc class="- topic/shortdesc ">
- Multiplies the complement (inverse) of the display object color by the complement of the background
- color, resulting in a bleaching effect.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">screen</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Multiplies the complement (inverse) of the display object color by the complement of the background
- color, resulting in a bleaching effect. This setting is commonly used for highlights or to remove black
- areas of the display object.
- </apiDesc></apiValueDetail></apiValue><apiValue id="flash.display:BlendMode:SHADER" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">SHADER</apiName><shortdesc class="- topic/shortdesc ">
- Uses a shader to define the blend between objects.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="10" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="AIR" version="1.5" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">shader</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Uses a shader to define the blend between objects.
- <p class="- topic/p ">Setting the <codeph class="+ topic/ph pr-d/codeph ">blendShader</codeph> property to a Shader instance
- automatically sets the display object's <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property to
- <codeph class="+ topic/ph pr-d/codeph ">BlendMode.SHADER</codeph>. If the <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property is set to
- <codeph class="+ topic/ph pr-d/codeph ">BlendMode.SHADER</codeph> without first setting the <codeph class="+ topic/ph pr-d/codeph ">blendShader</codeph> property,
- the <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property is set to <codeph class="+ topic/ph pr-d/codeph ">BlendMode.NORMAL</codeph> instead.
- If the <codeph class="+ topic/ph pr-d/codeph ">blendShader</codeph> property is set (which sets the
- <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property to <codeph class="+ topic/ph pr-d/codeph ">BlendMode.SHADER</codeph>), then later the value of the
- <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property is changed, the blend mode can be reset to use the blend
- shader simply by setting the <codeph class="+ topic/ph pr-d/codeph ">blendMode</codeph> property to <codeph class="+ topic/ph pr-d/codeph ">BlendMode.SHADER</codeph>.
- The <codeph class="+ topic/ph pr-d/codeph ">blendShader</codeph> property does not need to be set again except to change the
- shader that's used to define the blend mode.</p>
- <p class="- topic/p ">Not supported under GPU rendering.</p>
-
- </apiDesc></apiValueDetail><related-links class="- topic/related-links "><link href="flash.display.xml#DisplayObject/blendMode" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObject.blendMode</linktext></link><link href="flash.display.xml#DisplayObject/blendShader" class="- topic/link "><linktext class="- topic/linktext ">flash.display.DisplayObject.blendShader</linktext></link><link href="flash.display.xml#Shader" class="- topic/link "><linktext class="- topic/linktext ">flash.display.Shader</linktext></link></related-links></apiValue><apiValue id="flash.display:BlendMode:SUBTRACT" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiValue/apiValue "><apiName class="- topic/title reference/title apiRef/apiName ">SUBTRACT</apiName><shortdesc class="- topic/shortdesc ">
- Subtracts the values of the constituent colors in the display object from the values of the background
- color, applying a floor of 0.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiValueDetail class="- topic/body reference/refbody apiRef/apiDetail apiValue/apiValueDetail "><apiValueDef class="- topic/section reference/section apiRef/apiDef apiValue/apiValueDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiData class="- topic/ph reference/ph apiRef/apiData ">subtract</apiData><apiValueClassifier class="- topic/xref reference/xref apiRef/apiRelation apiValue/apiValueClassifier ">String</apiValueClassifier></apiValueDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- Subtracts the values of the constituent colors in the display object from the values of the background
- color, applying a floor of 0. This setting is commonly used for animating a darkening dissolve between
- two objects.
- <p class="- topic/p ">For example, if the display object has a pixel with an RGB value of 0xAA2233, and the background
- pixel has an RGB value of 0xDDA600, the resulting RGB value for the displayed pixel is
- 0x338400 (because 0xDD - 0xAA = 0x33, 0xA6 - 0x22 = 0x84, and 0x00 - 0x33 < 0x00).</p>
- </apiDesc></apiValueDetail></apiValue></apiClassifier><apiClassifier languages="" id="flash.display:Graphics" ditaarch:DITAArchVersion="1.0" domains="(topic ui-d) (topic hi-d) (topic pr-d) (topic sw-d) (topic ut-d) (topic pr-d api-d)" class="- topic/topic reference/reference apiRef/apiRef apiClassifier/apiClassifier "><apiName class="- topic/title reference/title apiRef/apiName ">Graphics</apiName><shortdesc class="- topic/shortdesc ">
- The Graphics class contains a set of methods that you can use to create a vector shape.</shortdesc><prolog class="- topic/prolog "><asMetadata class="+ topic/metadata adobe-api-d/asMetadata "><apiVersion class="+ topic/ph adobe-api-d/apiVersion "><apiLanguage version="3.0" class="+ topic/ph adobe-api-d/apiLanguage "/><apiPlatform description="" name="Flash" version="9" class="+ topic/ph adobe-api-d/apiPlatform "/><apiPlatform description="" name="Lite" version="4" class="+ topic/ph adobe-api-d/apiPlatform "/></apiVersion></asMetadata></prolog><apiClassifierDetail class="- topic/body reference/refbody apiRef/apiDetail apiClassifier/apiClassifierDetail "><apiClassifierDef class="- topic/section reference/section apiRef/apiDef apiClassifier/apiClassifierDef "><apiAccess value="public" class="- topic/state reference/state apiRef/apiQualifier adobe-api-d/apiAccess "/><apiStatic class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiStatic "/><apiFinal class="+ topic/state reference/state apiRef/apiQualifier adobe-api-d/apiFinal "/><apiBaseClassifier class="- topic/xref reference/xref apiRef/apiRelation apiClassifier/apiBaseClassifier ">Object</apiBaseClassifier></apiClassifierDef><apiDesc class="- topic/section reference/section apiRef/apiDesc ">
- The Graphics class contains a set of methods that you can use to create a vector shape.
- Display objects that support drawing include Sprite and Shape objects.
- Each of these classes includes a <codeph class="+ topic/ph pr-d/codeph ">graphics</codeph> property that is a Graphics object.
- The following are among those helper functions provided for ease of use:
- <codeph class="+ topic/ph pr-d/codeph ">drawRect()</codeph>, <codeph class="+ topic/ph pr-d/codeph ">drawRoundRect()</codeph>,
- <codeph class="+ topic/ph pr-d/codeph ">drawCircle()</codeph>, and <codeph class="+ topic/ph pr-d/codeph ">drawEllipse()</codeph>.
-
- <p class="- topic/p ">You cannot create a Graphics object directly from ActionScript code.
- If you call <codeph class="+ topic/ph pr-d/codeph ">new Graphics()</codeph>, an exception is thrown.</p>
-
- <p class="- topic/p ">The Graphics class is final; it cannot be subclassed.</p>
-
-
- </apiDesc><example conref="examples\GraphicsExample.as" class="- topic/example "> The following example uses the GraphicsExample class to draw a circle,
- a rounded rectangle, and a square. This task is accomplished by using the following steps:
- <ol class="- topic/ol "><li class="- topic/li ">Declare a <codeph class="+ topic/ph pr-d/codeph ">size</codeph> property for later use in determining the size of each shape.</li><li class="- topic/li ">Declare properties that set the background color to orange, the border color to
- dark gray, the border size to 0 pixels, the corner radius to 9 pixels, and set the space
- between the stage edge and the other objects to be 5 pixels.</li><li class="- topic/li ">Use the properties declared in the preceding steps along with the built in methods of the
- Graphics class to draw the circle, rounded rectangle, and square at coordinates x = 0, y = 0.</li><li class="- topic/li ">Redraw each of the shapes along the top of the stage, start