I want to develop plugin to listen Flash's (not Flash Player but when using Flash CC making .fla) actions and do something.

I have learnt jsfl can extend Flash,but it's based on running command by user.Now I want to listen some specific actions such as add new Item into library.So what shall I learn? Can AS do this ?

Thanks!

有帮助吗?

解决方案

Have a look at fl.addEventListener() in the JSFL reference You can listen for these events: "documentNew", "documentOpened", "documentClosed", "mouseMove", "documentChanged", "layerChanged", and "frameChanged".

for example:

fl.addEventListener("mouseMove",onMouseMove);
function onMouseMove(){
   fl.trace("mouse moved");
}

You should also check out xJSFL. It's pretty handy when scripting Flash.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top