W3C home > Mailing lists > Public > public-device-apis@w3.org > June 2012

Re: [Vibration API] Confusing list indexing in spec

From: Anssi Kostiainen <anssi.kostiainen@nokia.com>
Date: Mon, 18 Jun 2012 09:55:14 +0300
Cc: <public-device-apis@w3.org>
Message-Id: <CFA0018E-5810-47F5-9BDA-4DDA0E79ACA8@nokia.com>
To: ext Justin Lebar <justin.lebar@gmail.com>
Hi Justin,

On 16.6.2012, at 0.41, ext Justin Lebar wrote:

> If you want something less verbose, how about:
> 
> "A list of numbers representing a vibration pattern.  For example, the
> pattern [5, 10, 15] will cause the device to vibrate for 5ms, be still
> for 10ms, and then vibrate for 15ms."

Good catch. The algorithm is right (the earliest even entry has index 0), and the description was wrong.

To address the issue, I changed the description of the |pattern| simply to "A vibration pattern represented by a list of time entries." and added your example to the non-normative Examples section where it fits better. The algorithm is the normative part.

The Editor's Draft [ED] has been updated. A new release [TR] with this fix will be tagged later as per the W3C process. Meanwhile, I encourage you to refer to the ED for the latest.

Let us know if this addresses your concern, and thanks for reporting the bug! 

-Anssi

> [1] https://github.com/mozilla-b2g/gaia/pull/1704/files#r995646

[ED] http://dev.w3.org/2009/dap/vibration/
[TR] http://www.w3.org/TR/vibration/
Received on Monday, 18 June 2012 06:55:47 UTC

This archive was generated by hypermail 2.3.1 : Monday, 23 October 2017 14:53:54 UTC