I suspect when you mention that move() is not working then you are
trying to invoke this on the Button components from within
createChildren() . This will also not work as child UIObject components
are not fully initialised until the next frame.
UIObject has a doLater() function which will def
You have to wait while the components are initializing themselves.
Usually I place my initialization code accessing the on-stage children
components in the onLoad method of the container movieclip/component.
private function onLoad():Void {
roomShape_btn.toggle = true;
roomShape_btn.addEve
One more note:
If you're using mx.controls.Button instead of the top-level Button
class, then ignore what I said. In that case, you might be calling
addEventListener before the component has run its own constructor. Do
some traces to see if that is the case. Where are the calling
createChildren()
David,
how do you declare your button ?
do you use
var some_btn:Button or
var some_btn:mx.controls.Button ?
You should use the second so that the compiler would load the component class.
David Ham <[EMAIL PROTECTED]> wrote: Hi,
I was having trouble with some components yesterday. I am
I'm assuming this is AS2. You should use mx.utils.Delegate, like so:
roomShape_btn.onRelease = Delegate.create(this, click);
The AS2 Button class is not part of the MX architecture. It doesn't
use the event dispatcher pattern.
On 12/19/06, David Ham <[EMAIL PROTECTED]> wrote:
Hi,
I was having
Hi,
I was having trouble with some components yesterday. I am writing a
NavigatonView class that extends UIObject. I linked it to a symbol in the
library that had four Button components in it. The symbol had no code in it;
the code for the class was entirely in an external .as file.
Here is the t
6 matches
Mail list logo