Flex4には、SkinClassAを備えたButtonAとSkinClassBを備えたButtonBがあります。ButtonBのクリックをSkinClassAで聞くことは可能ですか?
<Components:IconToggleClass id="ButtonA" skinClass="SkinClassA">
<s:Button id="ButtonB" skinClass="SkinClassB" click="ButtonB_clickHandler(event)" />
// the SkinClassA class
<s:SparkSkin currentStateChanging="onCurrentStateChanging(event)"
added="onAddedHandler(event)" >
<!-- host component -->
<fx:Metadata>
<![CDATA[
[HostComponent("Components.IconToggleClass")]
]]>
</fx:Metadata>
<fx:Script >
<![CDATA[
import mx.events.StateChangeEvent;
private function onAddedHandler(event:Event):void
{
setIcon("iconDefault");
}
//I want something like this:
private function onButtonBClick():void
{
//do something
}
]]>
</fx:Script>