Coder Social home page Coder Social logo

Comments (5)

mfoltzgoogle avatar mfoltzgoogle commented on June 12, 2024

I believe this step is to handle when the user agent has disabled device discovery in a way that won't change over the lifetime of the call to prompt(), so the user agent would have no reason to show a dialog anyway. I don't think we handle this specifically on Chrome for desktop and always show the dialog.

from remote-playback.

mounirlamouri avatar mounirlamouri commented on June 12, 2024

My understanding of step 8 is that the user agent should reject immediately if it knows that the dialog will show no devices. However, the case you present is different because we need to show the dialog and do the discovery and then realize there is nothing.

Is my understanding correct?

from remote-playback.

avayvod avatar avayvod commented on June 12, 2024

Yes, I'm thinking about the case when the background availability monitoring is not available and we have to show the dialog to start active device discovery. We could argue that there's no timeout in this case as user could turn on a device at any moment.

from remote-playback.

mounirlamouri avatar mounirlamouri commented on June 12, 2024

In the case you describe, prompt() would hang while the dialog is visible and the state will stay disconnected which is all fine, right? If the user picks a device, it would switch the state to connecting and resolve the promise. Otherwise, it would reject the promise with NotAllowedError, right?

from remote-playback.

avayvod avatar avayvod commented on June 12, 2024

Ok, one can argue that in the use case I describe above the UA doesn't know if the "list of available remote playback devices..." "...will remain so [empty] before the request for user permission is completed" which makes the step a no-op.

from remote-playback.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.