Re: Vibration API - but the correct api is Notifications

Felipe wrote:
> Is there(or there will be) a way I can find out if the device is in silent mode?

> I mean, I could perform a "bip" sound in my webapp when something happens...
> but if the user has put his device in "meeting mode", I will just vibrate it instead...is this(or will it be) possible somehow?

Thank you for your interest, however, from the Introduction [1]:
>> the API is not meant to be used as a generic notification mechanism.
>> Use cases requiring notifying the user may be met by another specification, Web Notifications [notifications] [2].

Further, you should note that if you write your application using the Vibration API, then it will probably not vibrate if the application isn't focused [3]: (step 6 of processing vibration patterns) If the hidden attribute [PAGE-VISIBILITY] is set to true, then return false and terminate these steps.

[1] http://dev.w3.org/2009/dap/vibration/#introduction
[2] http://www.w3.org/TR/notifications/
[3] http://dev.w3.org/2009/dap/vibration/#dfn-processing-vibration-patterns

---------------------------------------------------------------------
This transmission (including any attachments) may contain confidential information, privileged material (including material protected by the solicitor-client or other applicable privileges), or constitute non-public information. Any use of this information by anyone other than the intended recipient is prohibited. If you have received this transmission in error, please immediately reply to the sender and delete this information from your system. Use, dissemination, distribution, or reproduction of this transmission by unintended recipients is not authorized and may be unlawful.

Received on Wednesday, 29 May 2013 16:26:39 UTC