W3C home > Mailing lists > Public > public-webevents@w3.org > April to June 2011

Re: Use case for the timestamp attribute

From: Doug Schepers <schepers@w3.org>
Date: Tue, 12 Apr 2011 10:50:57 -0400
Message-ID: <4DA466D1.5090009@w3.org>
To: Matt Brubeck <mbrubeck@mozilla.com>
CC: Anders Höckersten <andersh@opera.com>, "public-webevents@w3.org" <public-webevents@w3.org>, Arthur Barstow <art.barstow@nokia.com>
Hi, Matt-

Matt Brubeck wrote (on 4/5/11 11:08 PM):
> On 04/05/2011 12:15 AM, Anders Höckersten wrote:
>> Let's say you have a webpage that for whatever reason wants to know
>> exactly when the user starts touching the screen (some kind of game
>> perhaps?). Now, it's easy to do this by create your own timestamp
>> whenever the handlers for TouchStart is called. However, this only
>> provide measurements of when the call to TouchStart happened. If the
>> system is busy, this call will be delayed compared to when the actual
>> touch event happened, so the calculated timestamp will be off by a few
>> milliseconds (or even more than that).
>
> I think this problem is best solved by the Event.timeStamp attribute
> from DOM Level 2 Events. If Event.timeStamp is not adequate, it should
> be fixed (see discussion at [1]).
>
> http://lists.w3.org/Archives/Public/www-dom/2010OctDec/0069.html

My inclusion of the timestamp was simply to reflect Event.timeStamp, 
which TouchStart inherits from.

If we do intend to provide some generic way for authors to describe a 
"gesture" for a high-level event in terms of characteristics of one or 
more low-level events, having the timestamp there would be a crucial 
aspect.

Regards-
-Doug Schepers
W3C Team Contact, SVG, WebApps, and Web Events WGs
Received on Tuesday, 12 April 2011 14:51:07 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 12 April 2011 14:51:08 GMT