Re: Can getUserMedia() get called on a callback/event ?

2015-01-09 18:02 GMT+01:00 Martin Thomson <martin.thomson@gmail.com>:
> This is a general web interaction design principle.  If the call to a
> dialog-, consent- or popup-inducing function is not as a result of a
> user action (I think that Dom had a good reference for this in one of
> the documents), then it doesn't fire.  This prevents pages from
> generating these things.

So if a user is invited (via a link) to a call or a video-poker game,
he must "click" somewhere in order to "start" the party, is that? I
strongly disagree with that behavior.
Anyhow, is this behavior specified by the getUserMedia spec? I could
not find it.


> If this is causing you pain though, what specific use
> case is causing the problem?

The exact use case is described with pseudo-code in my previous mail. Basically:

- The user's JS receives a SDP offer.

- The JS first checks whether it is valid or not by creating a PC and
calling setRemoteDescription().

- If it is goes ok (so in the onSuccess callback of
setRemoteDescription), then the JS calls getUserMedia.

=> pain, no prompt.


> (And please don't describe behaviour as "hateful" until you understand
> why it is that way.)

Agreed. Sorry for that.



-- 
Iñaki Baz Castillo
<ibc@aliax.net>

Received on Friday, 9 January 2015 17:13:13 UTC