element-call/src/room
Robin Townsend f1ee3604de Make Element Call work in Firefox's resist fingerprinting mode
This one is gonna take some explaining:

When in resist fingerprinting mode, Firefox exhibits some funny behavior: when we ask for the the list of media devices, it gives us fake device IDs. But when the js-sdk requests a stream for any of those devices, Firefox associates the stream with the real device ID.

Now, in order to get the names of devices included in their metadata when you query the device list, you need to be holding a stream. For this reason, useMediaHandler was set up to reload the device list whenever matrix-js-sdk got a new local stream. But because of the inconsistency in device IDs, it would enter an infinite cycle telling matrix-js-sdk to request a stream for the fake device ID, but with matrix-js-sdk always responding with the real device ID.

I already wasn't happy with useMediaHandler's use of @ts-ignore comments to inspect private js-sdk fields, and in the meantime we've come up with a simpler function for requesting device names, so I decided to refactor useMediaHandler to use it instead. Importantly, it doesn't break in resist fingerprinting mode.

This created a new UX issue though: now, when on the lobby screen, useMediaHandler would request microphone access so it could get device names, followed immediately by a *second* pop-up for the lobby screen to request camera access. That's 1 pop-up too many, so I changed useMediaHandler to only request device names when a component is mounted that actually wants to show them. Currently, the settings modal is the only such component, and users normally only open it *after* granting full audio/video access, so this solution works out quite nicely.
2023-05-15 23:13:18 -04:00
..
AudioPreview.module.css Fix copyright pt. 2: CSS files 2023-01-03 16:58:38 +00:00
AudioPreview.tsx Fix copyright headers 2023-01-03 16:55:26 +00:00
CallEndedView.module.css Don't center content in call ended screen 2022-01-21 13:30:23 -08:00
CallEndedView.tsx Fix copyright headers 2023-01-03 16:55:26 +00:00
checkForParallelCalls.ts Detect split-brains caused by parallel calls 2023-04-17 16:58:51 -04:00
FeedbackModal.tsx Fix copyright headers 2023-01-03 16:55:26 +00:00
GridLayoutMenu.module.css Add a dropdown to choose between video calls and radio calls 2022-05-26 13:52:06 -04:00
GridLayoutMenu.tsx Fix copyright headers 2023-01-03 16:55:26 +00:00
GroupCallInspector.module.css Fix copyright pt. 2: CSS files 2023-01-03 16:58:38 +00:00
GroupCallInspector.tsx Add more events: 2023-03-30 16:54:10 +01:00
GroupCallLoader.tsx change ... to … unicode for consistency 2023-02-13 09:55:32 +05:30
GroupCallView.tsx Make Element Call work in Firefox's resist fingerprinting mode 2023-05-15 23:13:18 -04:00
InCallView.module.css Keep inspector from covering call buttons 2023-04-19 14:43:37 -04:00
InCallView.tsx Add screenshare tags 2023-04-27 09:42:25 +01:00
InviteModal.module.css Fix copyright pt. 2: CSS files 2023-01-03 16:58:38 +00:00
InviteModal.tsx Test tags for invite links; joining call by UR:; getting call name. 2023-05-11 14:30:32 +01:00
LobbyView.module.css Add URL params to control fonts 2022-12-09 14:31:13 -05:00
LobbyView.tsx Test tags for invite links; joining call by UR:; getting call name. 2023-05-11 14:30:32 +01:00
OverflowMenu.tsx Test tags for invite links; joining call by UR:; getting call name. 2023-05-11 14:30:32 +01:00
PTTButton.module.css Fix copyright pt. 2: CSS files 2023-01-03 16:58:38 +00:00
PTTButton.tsx Avoid duplicate PTT button 'unhold' events 2023-01-23 16:53:24 +00:00
PTTCallView.module.css Fix copyright pt. 2: CSS files 2023-01-03 16:58:38 +00:00
PTTCallView.tsx More work on opentelemetry event reporting 2023-03-16 14:41:55 +00:00
PTTFeed.module.css Fix copyright pt. 2: CSS files 2023-01-03 16:58:38 +00:00
PTTFeed.tsx Revert "Yarn upgrade" 2023-02-02 14:32:44 +00:00
RageshakeRequestModal.tsx Fix copyright headers 2023-01-03 16:55:26 +00:00
RoomAuthView.module.css Fix copyright pt. 2: CSS files 2023-01-03 16:58:38 +00:00
RoomAuthView.tsx Prettier 2023-05-11 15:16:17 +01:00
RoomPage.tsx Opt into analytics by default during the beta 2023-03-13 19:12:47 -04:00
RoomRedirect.tsx Fix copyright headers 2023-01-03 16:55:26 +00:00
Timer.tsx Fix copyright headers 2023-01-03 16:55:26 +00:00
useGroupCall.ts Detect split-brains caused by parallel calls 2023-04-17 16:58:51 -04:00
useJoinRule.ts Split room state hooks out into separate files 2022-10-14 10:50:36 -04:00
useLoadGroupCall.ts change stats interval to 10s (#1038) 2023-05-05 16:14:19 +02:00
usePageUnload.ts Fix copyright headers 2023-01-03 16:55:26 +00:00
usePTT.ts Don't crash if we can't find our own member event 2023-01-20 12:10:58 +00:00
useRoomAvatar.ts Split room state hooks out into separate files 2022-10-14 10:50:36 -04:00
useRoomState.ts Split room state hooks out into separate files 2022-10-14 10:50:36 -04:00
useSentryGroupCallHandler.ts Fix copyright headers 2023-01-03 16:55:26 +00:00
VideoPreview.module.css Fix copyright pt. 2: CSS files 2023-01-03 16:58:38 +00:00
VideoPreview.tsx prettier -w 2023-05-02 17:33:56 +01:00