Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>After reading your question, I decided to investigate. I found that the, <em>"Target must be an event emitter"</em> error only occurs when trying to capture the <strong>onEnd</strong> event from a combined animation. It does not occur for chained animations.</p> <p>After some digging around I noticed that combined animations seemed to have a _connects property, which suggested it was using the old depreciated <a href="http://dojotoolkit.org/reference-guide/1.7/dojo/connect.html" rel="nofollow">"dojo/_base/connect"</a> functionality. This is probably a bug in Dojo (or rather code that got missed in the most recent upgrades). Had a look on the <a href="http://bugs.dojotoolkit.org/" rel="nofollow">Dojo Trac</a> but not found anything yet, will probably open a new ticket for this one.</p> <p>There are two work-arounds that I can think of:</p> <ol> <li><p>Use <a href="http://dojotoolkit.org/reference-guide/1.7/dojo/connect.html" rel="nofollow">"dojo/_base/connect"</a></p> <pre><code>connect.connect(animation, "onEnd", function(){ // connect == dojo/base/connect }) </code></pre></li> <li><p>Connect to the onEnd event directly (or use <a href="http://dojotoolkit.org/reference-guide/1.8/dojo/aspect.html#dojo-aspect" rel="nofollow">"dojo/aspect"</a>)</p> <pre><code>animation.onEnd(function(){ }); </code></pre></li> </ol> <p>Neither of these ways are ideal, as you'll probably have to change your code to a <a href="http://dojotoolkit.org/reference-guide/1.8/dojo/on.html" rel="nofollow">dojo/on</a> version at some future date.</p> <p><b>Edit:</b> Looks like someone else has already reported this as a bug, <a href="http://bugs.dojotoolkit.org/ticket/16305" rel="nofollow">see here</a>.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload