creationComplete="addListeners()">
private function customLogEvent(e:MouseEvent):void {
ta1.text = e.currentTarget.id + ":" + e.type + ":" + e.shiftKey;
e.currentTarget.removeEventListener("doubleClick",customLogEvent);
}
private function handleEvent(e:MouseEvent):void {
e.currentTarget.addEventListener("doubleClick",customLogEvent);
var mev:MouseEvent = new MouseEvent("doubleClick");
mev.shiftKey = true;
e.currentTarget.dispatchEvent(mev);
}
private function addListeners():void {
b1.addEventListener("click",handleEvent);
b2.addEventListener("click",handleEvent);
}