PDA

View Full Version : Passing an event from a class


dto0107
06-22-2005, 09:36 AM
Let's say I created a class called "MyClass" that looks like this:

<class name="MyClass">
<view name="myView" width="100" height="100" bgcolor="0xFF0000"/>
</class>

My objective is to pass the onclick event of myView to the application. How do I do that?

Here is how my lzx tag definition looks like:

<MyClass onclick="debug.write('It got here');"/>

The above doesn't work. I'm suspecting I somehow have to pass the click event of the view within my class to the "outside", and I'm not sure how to do that.

Could anyone advise please?

Thanks.