This page was saved using jaction on 2006-09-04 8:34:00.
Address: http://flexdocs.kr/docs/flex2/langref/mx/states/RemoveChild.html
Title: mx.states.RemoveChild (Flex™ 2 레퍼런스 가이드)  •  Size: 27693
Packagemx.states
Classpublic class RemoveChild
InheritanceRemoveChild Inheritance Object
ImplementsIOverride

RemoveChild 클래스는, 컴퍼넌트등의 아이 표시 object를 뷰스테이트의 일부로서 컨테이너로부터 삭제합니다. 아이는 표시 리스트로부터 제외되는 것만으로, 실제로 삭제되는 것은 아닙니다. 이 클래스는, State 클래스의 overrides property로 사용합니다.

MXML 문장구조법expandedMXML 문장구조법의 비표시

<mx:RemoveChild> 태그에는, 이하의 속성이 있습니다.

 <mx:RemoveChild property target="null" /> 

View the examples

See also

mx.states.State
mx.states.AddChild
mx.states.Transition
mx.effects.RemoveChildAction


Public property
 property정의
 Inheritedconstructor : Object
특정의 object 인스턴스의 클래스 object 또는 constructor    함수에의 참조입니다.
Object
 Inheritedprototype : Object
[static] 클래스 또는 함수 object의 prototype object에의 참조입니다.
Object
  target : DisplayObject
뷰로부터 삭제하는 아이입니다.
RemoveChild
Public Methods
 Methods정의
  RemoveChild (target:DisplayObject = null)
constructor   .
RemoveChild
  apply (parent:UIComponent ):void
재정의(override)를 적용합니다.
RemoveChild
 InheritedhasOwnProperty (name:String ):Boolean
object로 지정된 property가 정의되고 있는지 어떤지를 나타냅니다.
Object
  initialize ():void
IOverride 인터페이스의 Methods. 이 클래스는, 이 인터페이스의 Methods를 empty의 Methods로서 Implements합니다.
RemoveChild
 InheritedisPrototypeOf (theClass:Object ):Boolean
Object 클래스의 인스턴스가, Parameters로서 지정된 object의 prototype 체인내에 있을지 어떨지를 나타냅니다.
Object
 InheritedpropertyIsEnumerable (name:String ):Boolean
지정된 property가 존재해, 열거 가능한가 어떤가를 나타냅니다.
Object
  remove (parent:UIComponent ):void
재정의(override)를 삭제합니다.
RemoveChild
 InheritedsetPropertyIsEnumerable (name:String , isEnum:Boolean = true):void
루프 처리에 대한 다이나믹 property의 가용성을 설정합니다.
Object
 InheritedtoString ():String
지정된 object의 string 표현을 돌려줍니다.
Object
 InheritedvalueOf ():Object
지정된 object의 원시적치를 돌려줍니다.
Object
property의 상세
targetproperty
public var target:DisplayObject

뷰로부터 삭제하는 아이입니다.

constructor    의 상세
RemoveChild()constructor   
public 함수 RemoveChild(target:DisplayObject = null)

constructor   .

Parameters
target:DisplayObject (default = null) — 뷰로부터 삭제하는 아이입니다.
Methods의 상세
apply()Methods
public function apply(parent:UIComponent ):void

재정의(override)를 적용합니다. Flex 에서는 원의 값이 보관 유지되기 (위해)때문에, 다음에 remove() Methods에 원의 값을 복원할 수 있습니다.

그 뷰스테이트로 이행하면, 자동적으로 이 Methods가 불려 갑니다. 이 Methods는 직접 호출하지 말아 주세요.

Parameters
parent:UIComponent — 이 재정의(override)를 포함한 상태 object의 부모입니다. 타겟이 명시적으로 지정되어 있지 않은 경우, 재정의(override)의 타겟으로서 사용됩니다.
initialize()Methods 
public function initialize():void

IOverride 인터페이스의 Methods. 이 클래스는, 이 인터페이스의 Methods를 empty의 Methods로서 Implements합니다.

재정의(override)를 초기화합니다. Flex 에서는 apply() Methods를 최초로 호출하기 전에 이 Methods를 호출하기 (위해)때문에, 이 Methods의 재정의(override)에는, 1 회만 실행하는 초기화 코드를 배치합니다.

그 뷰스테이트로 이행하면, Flex 가 자동적으로 이 Methods를 호출합니다. 이 Methods는 직접 호출하지 말아 주세요.

remove()Methods 
public function remove(parent:UIComponent ):void

재정의(override)를 삭제합니다. apply() Methods에 기억되고 있는 값이 복원됩니다.

그 뷰스테이트로 이행하면, 자동적으로 이 Methods가 불려 갑니다. 이 Methods는 직접 호출하지 말아 주세요.

Parameters
parent:UIComponent — 이 재정의(override)를 포함한 상태 object의 부모입니다. 타겟이 명시적으로 지정되어 있지 않은 경우, 재정의(override)의 타겟으로서 사용됩니다.
Examples
StatesExample
<? xml version="1.0" ? >
<! -- Simple example to demonstrate the States 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>

    <! -- 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>






 

코멘트가 추가되었을 경우, 메일로 받기. | 코멘트 리포트

현재의 페이지: http://flexdocs.kr/docs/flex2/langref/mx/states/RemoveChild.html