Closed
Bug 821306
Opened 13 years ago
Closed 12 years ago
Expose nsIMediaDevice.id to script
Categories
(Core :: WebRTC, defect)
Core
WebRTC
Tracking
()
RESOLVED
FIXED
mozilla20
People
(Reporter: ted, Assigned: ted)
Details
(Whiteboard: [qa-])
Attachments
(1 file)
2.60 KB,
patch
|
jst
:
review+
|
Details | Diff | Splinter Review |
Not sure if this actually belongs in the DOM component. Currently MediaDevices have an ID attached, but it's not script-exposed. I'd like to be able to get at this from code with chrome privileges so that we can usefully select the correct device for unit tests.
Assignee | ||
Comment 1•13 years ago
|
||
Attachment #691813 -
Flags: review?(jst)
Comment 2•13 years ago
|
||
Jesup, is this something we want to expose to webpages, and thus spec etc? If not, we should find a way to expose this only to chrome. That'll be easy down the road, but a bit tricky as of right now given how the media stuff is exposed to JS.
Assignee | ||
Comment 3•13 years ago
|
||
I didn't know it was possible for content to get a hold of these at all, honestly. I don't see anywhere that they're exposed, and there's no classinfo for it.
Comment 4•13 years ago
|
||
jst: I don't think the spec speaks to this directly. However, it's possible that as part of the 'constraints' that are given to getUserMedia it could include the 'id' of a device it was using last time as the preferred default device. The WG has talked about this only in generalities so far (no real attention), saying they'd be selected by asking for front, back, etc. But we realize on many systems there's no such labeling available. This would allow an app to adjust to the household.
Assignee | ||
Comment 5•13 years ago
|
||
Can anyone answer my question in comment 3? Is it possible for content script to get to these objects? I don't see any interfaces that expose them, and they're not in domclassinfo.
Comment 6•13 years ago
|
||
Comment on attachment 691813 [details] [diff] [review]
Expose nsIMediaDevice.id to script
Ted's right, there's no way to reach these from content code, the only way that I know of is to call mozGetUserMediaDevices() passing in a callback and once the callback is called, it will be handed references to media device objects. But mozGetUserMediaDevices() is only callable from chrome...
Attachment #691813 -
Flags: review?(jst) → review+
Assignee | ||
Comment 7•12 years ago
|
||
Comment 8•12 years ago
|
||
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla20
Updated•12 years ago
|
Whiteboard: [qa-]
You need to log in
before you can comment on or make changes to this bug.
Description
•