I started tomake a fewtestsusinghtml5canvasand founda problemin one process.
I createdan animation of2 framesand at firstframethere is a button.
thenprogrammedforwhen you click thebuttonit opensa newtabin the browser andgo to the nextframeloopinganimation.
so far so good.
butwhen I returnto clickthe buttonit opens2tabsandmakethe loopagain, again I click thenew buttonit opens4tabsandso on.
why this happensand what would bea solution?
Thank you
here is thecodeof the firstframe:
this.stop();
this.button_1.addEventListener("click", fl_ClickToGoToWebPage);
function fl_ClickToGoToWebPage() {
window.open("http://www.adobe.com", "_blank");
}
this.button_1.addEventListener("click", fl_ClickToGoToAndPlayFromFrame.bind(this));
function fl_ClickToGoToAndPlayFromFrame()
{
this.gotoAndPlay(2);
}