Maybe:

<class ...

  <hander name="onopacity">
    if (inited && opacity == 0) { 
      if ($debug) { Debug.info("opacity: %w => %w.destroy()", opacity, this); }
      this.destroy();
    }
  </handler>



On 2009-12-04, at 08:36, cem sonmez wrote:

> hi
> 
> snippet from the class file :
> 
> <class name="loginWindow" extends="window"  oninit="initLoginWindow">
> 
> <switch>
>            <when property="$as3">
>                <passthrough>
>                    import flash.events.*;
>                </passthrough>
>            </when>
>        </switch>
> 
> <method name="initLoginWindow">
>            this.addEventListener(this.opacity,destroyWindow);
> </method>
> 
> <method name="destroyWindow" args="opacityy">
>            switch (opacityy) {
>                case "0" :
>                    Debug.write("destroyy");
>                    this.destroy();
>                    break;
>            }
>        </method>
> </class>
> 
> for this class i m trying to listen the opacity property and when the
> opacity==0, destroy the loginWindow object
> 
> I am trying this on swf10 runtime. is it possible to use the listener like
> above (this.addEventListener(this.opacity,destroyWindow);)
> 
> or any idea about how to do this for swf10?
> 
> Regards.
> 
> -- 
> Cem SONMEZ


Reply via email to