Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Define MediaDevices.CaptureHandle #163

Closed
wants to merge 6 commits into from
Closed

Define MediaDevices.CaptureHandle #163

wants to merge 6 commits into from

Conversation

eladalon1983
Copy link
Member

@eladalon1983 eladalon1983 commented Apr 6, 2021

Define a mechanism to allow an application to inform the user agent of what a meaningful label would be for the tracks that would result if the tab in which the application is running gets captured. Resolves #159.


Preview | Diff

index.html Outdated Show resolved Hide resolved
index.html Outdated
agent of a meaningful {{MediaStreamTrack/label}} to apply to the
tracks that would result if the tab in which the application is
running is captured.<p>
<p>Only the top-level document may set or read this value. Attempts
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you know if there are other ways for a doc to know if it's a top-level doc?
Anyway, I think saying that only the preferredLabel of the top-level document can be used as label would be enough. WDYT?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think window === window.top is an easier way for a document to check whether it's the top-level document, so we'd not be exposing that bit of information for the first time.

Your suggestion makes sense to me; I will enact the change.

@eladalon1983 eladalon1983 changed the title Define preferredLabel Define MediaDevices.DisplayMediaCaptureHandle Apr 8, 2021
@eladalon1983 eladalon1983 changed the title Define MediaDevices.DisplayMediaCaptureHandle Define MediaDevices.CaptureHandle Apr 15, 2021
@eladalon1983
Copy link
Member Author

This PR is out of date. I will produce a standalone document that more accurately reflects the direction this ended up taking. In the meantime, please see this explainer for what is currently in origin trial in Chrome.

@eladalon1983 eladalon1983 deleted the preferred_label branch June 11, 2021 17:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow screen-captured applications to self-declare a capture handle
2 participants