-
Notifications
You must be signed in to change notification settings - Fork 290
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
fix: Display Media Device labels for Firefox #17562
fix: Display Media Device labels for Firefox #17562
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## dev #17562 +/- ##
==========================================
- Coverage 46.11% 46.11% -0.01%
==========================================
Files 760 760
Lines 25016 25034 +18
Branches 5721 5724 +3
==========================================
+ Hits 11537 11545 +8
- Misses 12036 12043 +7
- Partials 1443 1446 +3 |
does this change anything for chromium browsers? |
thanks for taking the initiative on this! |
@tlebon Thx for your fast response Unfortunately it also has an impact on Chrome. The device lists are created during the initialization process of the app, so that the access popup also appears in Chrome. I see three solutions here:
What do you think? More detail: |
Do we have the possibility to create a custom dialog (that explains better why we are asking for these access rights), or are we bound to the browser default popup? |
@WolfiWire I would use this one. |
- Now the devices are only queried before a call or when the settings are opened.
Quality Gate passedIssues Measures |
@WolfiWire I have rewritten the device list initialization. This means that our app behaves the same for the user as before. Only internally the process is different. |
@tlebon Please, could someone take a look at this? |
I'm still OoO (sick). Maybe @wireapp/web can take a look. Or else I will tomorrow. |
Get well soon!
Thx. sometime this week would be enough |
This reverts commit 97a5c39.
This reverts commit 97a5c39.
Description
In Firefox, the labels of the Media devices can only be read under certain constrains. This means that the device names cannot be displayed in the select menu. This PR is a fix for it
Screenshots/Screencast (for UI changes)
Before this fix, the selection fields are displayed with blank labels or common names:
With this fix, the selection fields are displayed with device names:
Notes
The fix has one disadvantage. I had to change the device list initialization process to avoid asking a user for audio access rights on first login starting page.
In order to display the correct device labels, we need to make an access authorization query when creating the device list. But we should not ask for microphone and camera access when not needed.
To avoid a permission query being displayed when starting the app, I have rewritten the
MediaDeviceHandler
and The device list is no longer created in the constructor. The methodMediaDeviceHandler.initializeMediaDevices
is now integrated into the three points in our app where a call can be accepted or started. In addition, this method is also called in the device settings. So, a device list is only created before the first call or when the settings are called.Checklist
Important details for the reviewers
(Delete this section if unnecessary)