パッケージmx.effects
public class AddChildAction
継承AddChildAction Inheritance Effect Inheritance EventDispatcher Inheritance Object

AddChildAction クラスでは、ビューステートを定義する AddChild プロパティに対応したアクションエフェクトを定義します。AddChildAction エフェクトをトランジションの定義範囲で使用することにより、AddChild プロパティで定義されたビューステートの変化がトランジションで発生する時期を制御できます。

MXML シンタックスexpandedMXML シンタックスの非表示

The <mx:AddChildAction> tag inherits all of the tag attributes of its superclass, and adds the following tag attributes:

 <mx:AddChildAction Properties id="ID" index="-1" relativeTo="" position="index" /> 

例の表示

関連項目

mx.effects.effectClasses.AddChildActionInstance
mx.states.AddChild


パブリックプロパティ
 プロパティ定義
 InheritedclassName : String
このエフェクトクラスの名前です。たとえば、"Fade" などがあります。
Effect
 Inheritedconstructor : Object
指定されたオブジェクトインスタンスのクラスオブジェクトまたはコンストラクタ関数への参照です。
Object
 InheritedcustomFilter : EffectTargetFilter
エフェクトを再生するターゲットを特定するために、エフェクトによって使用されるタイプ EffectTargetFilter のカスタムフィルタオブジェクトを指定します。
Effect
 Inheritedfilter : String
エフェクトのターゲットをフィルタリングするアルゴリズムを指定します。
Effect
  index : int = -1
親の中で子が持つインデックスを表します。
AddChildAction
 InheritedinstanceClass : Class
このエフェクトクラスのエフェクトインスタンスクラスを指定する Class 型のオブジェクトを表します。
Effect
 InheritedisPlaying : Boolean
エフェクトのインスタンスのいずれかが現在再生中の場合に true、そうでない場合に false となる読み取り専用フラグです。
Effect
  position : String = "index"
relativeTo プロパティで指定されたオブジェクトを基準にした、表示リスト内での子の位置です。
AddChildAction
 Inheritedprototype : Object
[static] クラスまたは関数オブジェクトのプロトタイプオブジェクトへの参照です。
Object
  relativeTo : DisplayObjectContainer
子コンポーネントが追加される位置です。
AddChildAction
 InheritedrelevantProperties : Array
フィルタリング実行時に使用するプロパティ名の配列を表します。
Effect
 InheritedrelevantStyles : Array
フィルタリング実行時に使用するスタイル名の配列を表します。
Effect
 InheritedrepeatCount : int = 1
エフェクトを繰り返す回数を表します。
Effect
 InheritedrepeatDelay : int = 0
エフェクトを繰り返す前の待機時間を表します (ミリ秒単位)。
Effect
 InheritedstartDelay : int = 0
エフェクトを開始する前の待機時間を表します (ミリ秒単位)。
Effect
 InheritedsuspendBackgroundProcessing : Boolean = false
true の場合、エフェクトの再生中にすべてのバックグラウンド処理をブロックします。
Effect
 Inheritedtarget : Object
このエフェクトが適用される UIComponent オブジェクトを表します。
Effect
 Inheritedtargets : Array
エフェクトのターゲットである UIComponent オブジェクトの配列を表します。
Effect
パブリック Methods
 メソッド定義
  
AddChildAction(target:Object = null)
コンストラクタです。
AddChildAction
 Inherited
addEventListener(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = false):void
リスナーがイベントの通知を受け取るように、イベントリスナーオブジェクトを EventDispatcher オブジェクトに登録します。
EventDispatcher
 Inherited
エフェクトのターゲットにおいて関連するプロパティの現在値をキャプチャします。
Effect
 Inherited
createInstance(target:Object = null):IEffectInstance
1 つのエフェクトインスタンスを作成し、それを初期化します。
Effect
 Inherited
createInstances(targets:Array = null):Array
ターゲットオブジェクトの配列を取得し、各ターゲットで createInstance() メソッドを呼び出します。
Effect
 Inherited
イベントをイベントフローに送出します。
EventDispatcher
 Inherited
end(effectInstance:IEffectInstance = null):void
現在再生中のエフェクトをすべて中断し、直ちにエフェクトの終わりにジャンプします。
Effect
 Inherited
ストリングの配列を返します。各ストリングは、このエフェクトによって変更されるプロパティの名前です。
Effect
 Inherited
EventDispatcher オブジェクトに、特定のイベントタイプに対して登録されたリスナーがあるかどうかを確認します。
EventDispatcher
 Inherited
指定されたプロパティがオブジェクトに定義されているかどうかを示します。
Object
 Inherited
Object クラスのインスタンスが、パラメータとして指定されたオブジェクトのプロトタイプチェーン内にあるかどうかを示します。
Object
 Inherited
resume() メソッドを呼び出すまで、エフェクトを一時停止します。
Effect
 Inherited
play(targets:Array = null, playReversedFromEnd:Boolean = false):Array
エフェクトの再生を開始します。
Effect
 Inherited
指定されたプロパティが存在し、列挙できるかどうかを示します。
Object
 Inherited
removeEventListener(type:String, listener:Function, useCapture:Boolean = false):void
EventDispatcher オブジェクトからリスナーを削除します。
EventDispatcher
 Inherited
pause() メソッドを呼び出し、エフェクトを一時停止した後、再開させます。
Effect
 Inherited
エフェクトが現在再生中の場合に、エフェクトの現在位置から開始して、逆順でエフェクトを再生します。
Effect
 Inherited
ループ処理に対するダイナミックプロパティの可用性を設定します。
Object
 Inherited
指定されたオブジェクトのストリング表現を返します。
Object
 Inherited
指定されたオブジェクトのプリミティブな値を返します。
Object
 Inherited
指定されたイベントタイプについて、この EventDispatcher オブジェクトまたはその祖先にイベントリスナーが登録されているかどうかを確認します。
EventDispatcher
Protected Methods
 メソッド定義
 Inherited
applyValueToTarget(target:Object, property:String, value:*, props:Object):void
エフェクトインフラストラクチャによって内部的に使用されます。
Effect
 Inherited
エフェクトインスタンスの再生終了時に呼び出されます。
Effect
 Inherited
このメソッドは、エフェクトインスタンスの再生開始時に呼び出されます。
Effect
 Inherited
filterInstance(propChanges:Array, targ:Object):Boolean
エフェクトインスタンスをフィルタリングするために必要なロジックを決定します。
Effect
 Inherited
getValueFromTarget(target:Object, property:String):*
ターゲットからプロパティの値を取得するために captureStartValues() メソッドによって呼び出されます。
Effect
 Inherited
initInstance(instance:IEffectInstance):void
エフェクトインスタンスにエフェクトのプロパティをコピーします。
Effect
イベント
 イベント一覧定義
 Inherited Flash Player がオペレーティングシステムのフォーカスを取得して、アクティブになったときに送出されます。EventDispatcher
 Inherited Flash Player がオペレーティングシステムのフォーカスを失って、非アクティブになったときに送出されます。EventDispatcher
 Inherited エフェクトの再生停止時 (エフェクトの再生完了時、またはエフェクトが end() メソッドの呼び出しにより中断されたとき) に送出されます。Effect
 Inherited エフェクトの再生開始時に送出されます。Effect
プロパティの詳細
indexプロパティ
public var index:int = -1

親の中で子が持つインデックスを表します。値が -1 の場合、親の最後の子として子が追加されます。

デフォルト値-1.

positionプロパティ 
public var position:String = "index"

relativeTo プロパティで指定されたオブジェクトを基準にした、表示リスト内での子の位置です。有効な値は "before""after""firstChild""lastChild"、および "index" です。"index" を指定した場合は、index プロパティを使用して子の位置が決定されます。

デフォルト値"index".

relativeToプロパティ 
public var relativeTo:DisplayObjectContainer

子コンポーネントが追加される位置です。デフォルトでは、ビューステートを定義したもののうち AddChild プロパティの定義からこの値が決定されます。

コンストラクタの詳細
AddChildAction()コンストラクタ
public 関数 AddChildAction(target:Object = null)

コンストラクタです。

パラメータ
target:Object (default = null) — このエフェクトでアニメーション化するオブジェクトを表します。
TransitionExample
<?xml version="1.0" ?> <!-- Simple example to demonstrate the Transition class. --> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">

    <!-- Define one view state, in addition to the base state.--> <mx:states> <mx:State name="Register"> <mx:AddChild relativeTo="{loginForm}" position="lastChild"> <mx:target> <mx:FormItem id="confirm" label="Confirm:"> <mx:TextInput/> </mx:FormItem> </mx:target> </mx:AddChild> <mx:SetProperty target="{loginPanel}" name="title" value="Register"/> <mx:SetProperty target="{loginButton}" name="label" value="Register"/> <mx:SetStyle target="{loginButton}" name="color" value="blue"/> <mx:RemoveChild target="{registerLink}"/> <mx:AddChild relativeTo="{spacer1}" position="before"> <mx:target> <mx:LinkButton id="loginLink" label="Return to Login" click="currentState=''"/> </mx:target> </mx:AddChild> </mx:State> </mx:states>

    <mx:transitions> <!-- Define the transition from the base state to the Register state.--> <mx:Transition id="toRegister" fromState="*" toState="Register"> <mx:Sequence targets="{[loginPanel, registerLink, confirm, loginLink, spacer1]}"> <mx:RemoveChildAction/> <mx:SetPropertyAction target="{loginPanel}" name="title"/> <mx:SetPropertyAction target="{loginButton}" name="label"/> <mx:SetStyleAction target="{loginButton}" name="color"/> <mx:Resize target="{loginPanel}"/> <mx:AddChildAction/> </mx:Sequence> </mx:Transition>

        <!-- Define the transition from the Register state to the base state.--> <mx:Transition id="toDefault" fromState="Register" toState="*"> <mx:Sequence targets="{[loginPanel, registerLink, confirm, loginLink, spacer1]}"> <mx:RemoveChildAction/> <mx:SetPropertyAction target="{loginPanel}" name="title"/> <mx:SetPropertyAction  target="{loginButton}" name="label"/> <mx:SetStyleAction target="{loginButton}" name="color"/> <mx:Resize target="{loginPanel}"/> <mx:AddChildAction/> </mx:Sequence> </mx:Transition> </mx:transitions>

    <!-- Define a Panel container that defines the login form.--> <mx:Panel title="Login" id="loginPanel" horizontalScrollPolicy="off" verticalScrollPolicy="off" paddingTop="10" paddingLeft="10" paddingRight="10" paddingBottom="10">
    
        <mx:Text width="100%" color="blue" text="Click the 'Need to Register?' link to change state. Click the 'Return to Login' link to return to the base state."/>

        <mx:Form id="loginForm" > <mx:FormItem label="Username:"> <mx:TextInput/> </mx:FormItem> <mx:FormItem label="Password:"> <mx:TextInput/> </mx:FormItem> </mx:Form> <mx:ControlBar> <mx:LinkButton id="registerLink"  label="Need to Register?" click="currentState='Register'"/> <mx:Spacer width="100%" id="spacer1"/> <mx:Button label="Login" id="loginButton"/> </mx:ControlBar> </mx:Panel> </mx:Application>