Re: SVG12: DOM-based animation

Bjoern Hoehrmann wrote:
>* Andrew Shellshear wrote:
>>>>  <handler type="application/ecmascript" ev:event="timer">
>>>>        if (evt.target == mytimer)
>>>>        {
>>>>        showAndGrowElement();
>>>>        }
>>>>  </handler>
>>>
>>>This is one of the reasons why the example can't work as expected, the
>>>'timer' event is only ever dispatched to the event listeners registered
>>>on the Timer object, not to any node in the document. At least the draft
>>>does not mention that.
>>
>>We have added the following to the description of the Timer event:
>>
>>This event is only applicable to 'svg' elements.
>>The target of the event is the 'svg' element.
>
>That would make sense only with major changes to the 'Timer' interface;
>could you elaborate on these changes? How, for example, with this model,
>would one distinguish between two 'timer' events from different Timer
>objects?

I apologise in advance if I'm not quite getting your point (and I suspect
I'm not), but the example above shows how you would distinguish between two
timer events from different Timer objects.  In particular, the line:

if (evt.target == mytimer)

I hope that this answers your questions.  Please let us know shortly if  
this does not address your concerns.

Andrew.

Received on Tuesday, 9 May 2006 15:13:08 UTC