Page 1 of 1

addEventListener doesnt worjk anymore in AE CC??

Posted: July 30th, 2014, 1:25 am
by bkan
Hello,
I have migrated my own script from CS6 to CC, and all scripts work, except those with an "addEventListener" function.
Here is my code (after building th UI, which works well) :

myPanel.grp.myTabbedPanel.myTab1.myTabContent1.addEventListener('click', multiWiggle);

function multiWiggle(ev){

var b = ev.target;
var modState = ScriptUI.environment.keyboardState;

if (!(b instanceof Button)) {
return;
}

if (modState.shiftKey){
wiggleController_fonction();
}

else{
wiggleSimple_fonction();
}
};

Even if I write an alert in the "function multiWiggle" function, after effects doesn't pop up any message, so I think it's the addEventListener which doesn't work : any idea?

Thanks in advance,

(sorry for my english!)

Re: addEventListener doesnt worjk anymore in AE CC??

Posted: August 4th, 2014, 4:01 pm
by chriskelley
Hi bkan -

You might find this discussion at the Adobe scripting forum useful:
https://forums.adobe.com/thread/1251722

Click events specifically are having problems with eventListeners, dig through that thread and see if any of the answers apply to your case.

Good luck!
Chris