PDA

View Full Version : Do you have to restart Flash everytime you make a .jsfl change?


abeall
02-21-2007, 04:16 PM
It seems that my PC is loading the .jsfl into memory when Flash first loads. This means that if I make a change to the .jsfl, I have to restart Flash completely. This makes developing .jsfl extremely hard. Is there any easier way to reload the command and re-test so I don't have to restart Flash?

senocular
02-21-2007, 04:28 PM
I dont remember flash needing to restart for commands. Are you saving them into your user directory?

If its still an issue, your command could be a call to another command which you could edit and have updated without restarting Flash (since the one Flash has is just calling it)

abeall
02-21-2007, 04:49 PM
You're right, I was sticking it in First Run, not the user directory. That explains it. Thanks.

I can't get the xmlPanel to work, though. I'm using the example given in the docs, and it keeps giving me "invalid argument".


var dom = fl.getDocumentDOM();
var xm = fl.configURI+"Commands/LibraryBitmapsOptions.xml";
fl.trace(xm);
var obj = dom.xmlPanel(xm);
for (var prop in obj) {
fl.trace("property " + prop + " = " + obj[prop]);
}

The file exists, and the trace outputs the correct file path. Could the file itself be invalid?

<dialog id = "myID" title="yourTitle" buttons="accept, cancel">
<checkbox id="allowSmoothing" label="allowSmoothing" tabindex="1" checked="true" accesskey="S"/>
</dialog>


[edit]
I lied. The file didn't exist. All is working now. Life is good. Really wish Fireworks had XML panels, this is sweet... although, is it just me, or is there no event system for SWF panels in Flash?

jjbilly
02-23-2007, 09:14 AM
You are right, there is no event system. It's a real frustration.

The only way round it, I think, other than crafty 'update' and 'apply' buttons all over your UI is to poll periodically - which can eventually lead to instability.