Wayland: Skip our screenshare screen picker

This commit is contained in:
V 2023-08-07 00:39:29 +02:00
parent 3108de7c79
commit b87bcaefe9
No known key found for this signature in database
GPG key ID: A1DC0CFB5615D905

View file

@ -29,6 +29,16 @@ export function registerScreenShareHandler() {
}
});
const isWayland =
process.platform === "linux" &&
(process.env.XDG_SESSION_TYPE === "wayland" || !!process.env.WAYLAND_DISPLAY);
if (isWayland) {
const video = sources[0];
callback(video ? { video } : {});
return;
}
const data = sources.map(({ id, name, thumbnail }) => ({
id,
name,