- From: Tobie Langel via GitHub <sysbot+gh@w3.org>
- Date: Thu, 21 Jan 2016 22:18:28 +0000
- To: public-device-apis@w3.org
tobie has just created a new issue for https://github.com/w3c/sensors:
== Define behavior when visibilityState != "visible" ==
1. What happens when a sensor is instantiated in a document whose
`visibilityState` isn't `"visible"`. Should we just throw a
`SecurityError` like for secure context violations or should we do
nothing but avoid sensing data until `visibilityState` goes back to
`"visible"`? If the latter, should we have events to describe that?
2. What happens when the visibility state changes:
1. from `"visible"` to something else? Emit an error event? Stop
sending data?
2. from something else to `"visible"`? Do we start sending data?
My feeling is that we should simply not emit data when
`visibilityState` isn't `"visible"` and resume emission when it
switches back to `visible`. Not sure whether we should emit events on
the sensor object itself for this (like `"paused"` and `"resumed"` or
something.
Please view or discuss this issue at
https://github.com/w3c/sensors/issues/81 using your GitHub account
Received on Thursday, 21 January 2016 22:18:33 UTC