Re: Busy indicator API

2015-07-13 Thread Adam Roach
On 7/13/15 10:36, smaug wrote: On 07/13/2015 01:50 PM, Richard Barnes wrote: Obligatory: Will this be restricted to secure contexts? But given that web pages can already achieve something like this using document.open()/close(), at least on Gecko, perhaps exposing the API to certainly-not-sec

Re: Busy indicator API

2015-07-13 Thread smaug
On 07/13/2015 01:50 PM, Richard Barnes wrote: On Sun, Jul 5, 2015 at 5:11 PM, Anne van Kesteren wrote: A while back there have been some requests from developers (seconded by those working on GitHub) to have an API to indicate whether a site is busy with one thing or another (e.g. networking).

Re: Busy indicator API

2015-07-13 Thread Richard Barnes
On Sun, Jul 5, 2015 at 5:11 PM, Anne van Kesteren wrote: > A while back there have been some requests from developers (seconded > by those working on GitHub) to have an API to indicate whether a site > is busy with one thing or another (e.g. networking). > > They'd like to use this to avoid havin

Re: Busy indicator API

2015-07-09 Thread Eric Shepherd
Jonas Sicking wrote: > window.navigator.addBusyTask(promise); > > would be great. The API can be called any time and any number of > times. The API would run the spinner until all provided promises are > resolved. So if it's called twice with different promises, the spinner > doesn't stop when one

Re: Busy indicator API

2015-07-06 Thread Jonas Sicking
I think an API like: window.navigator.addBusyTask(promise); would be great. The API can be called any time and any number of times. The API would run the spinner until all provided promises are resolved. So if it's called twice with different promises, the spinner doesn't stop when one of the pro

Re: Busy indicator API

2015-07-06 Thread Anne van Kesteren
On Mon, Jul 6, 2015 at 3:22 AM, Mike Connor wrote: > Anne, I assume the point is not to draw attention to background tabs. There > are much more useful ways to do that, if they're going to ask for a new > API/UI. Instead, my read is that they're looking for a hopefully-not-janky > busy indicator

Re: Busy indicator API

2015-07-06 Thread Robin Berjon
On 06/07/2015 03:22 , Mike Connor wrote: Does it need to be an API, or would dispatching an event be sufficient? Something like "busy" and "idle" events would be easy to send from JS, and UAs would be free to honour or ignore based on context. On the face of it it's certainly useful: writing yo

Re: Busy indicator API

2015-07-05 Thread Mike Connor
On 5 July 2015 at 11:53, Dirkjan Ochtman wrote: > On Sun, Jul 5, 2015 at 5:11 PM, Anne van Kesteren > wrote: > > Is there a reason we shouldn't expose a hook for this? > > On the one hand, this seems really useful. On the other hand, I'm > pretty worried about the UX implications here. I wouldn'

Re: Busy indicator API

2015-07-05 Thread smaug
On 07/05/2015 06:11 PM, Anne van Kesteren wrote: A while back there have been some requests from developers (seconded by those working on GitHub) to have an API to indicate whether a site is busy with one thing or another (e.g. networking). They'd like to use this to avoid having to create their

Re: Busy indicator API

2015-07-05 Thread Anne van Kesteren
On Sun, Jul 5, 2015 at 6:21 PM, fantasai wrote: > On 07/05/2015 11:11 AM, Anne van Kesteren wrote: >> A while back there have been some requests from developers (seconded >> by those working on GitHub) to have an API to indicate whether a site >> is busy with one thing or another (e.g. networking)

Re: Busy indicator API

2015-07-05 Thread fantasai
On 07/05/2015 11:11 AM, Anne van Kesteren wrote: A while back there have been some requests from developers (seconded by those working on GitHub) to have an API to indicate whether a site is busy with one thing or another (e.g. networking). They'd like to use this to avoid having to create their

Re: Busy indicator API

2015-07-05 Thread Dirkjan Ochtman
On Sun, Jul 5, 2015 at 5:11 PM, Anne van Kesteren wrote: > Is there a reason we shouldn't expose a hook for this? On the one hand, this seems really useful. On the other hand, I'm pretty worried about the UX implications here. I wouldn't want a dozen flashing/spinning/moving things in my tab bar.