From 5191147d1c8e2e97735110dfe78382914d116f7a Mon Sep 17 00:00:00 2001 From: Ovgodd Date: Wed, 7 Oct 2026 15:48:11 +0200 Subject: [PATCH] =?UTF-8?q?fixup!=20=E2=9C=A8(frontend)=20add=20open-in-se?= =?UTF-8?q?parate-window=20control=20for=20screen=20shares?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../features/rooms/livekit/hooks/useScreenSharePopout.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/frontend/src/features/rooms/livekit/hooks/useScreenSharePopout.ts b/src/frontend/src/features/rooms/livekit/hooks/useScreenSharePopout.ts index c7de292a9..8b9314a55 100644 --- a/src/frontend/src/features/rooms/livekit/hooks/useScreenSharePopout.ts +++ b/src/frontend/src/features/rooms/livekit/hooks/useScreenSharePopout.ts @@ -89,7 +89,13 @@ export const useScreenSharePopout = ({ reportError('generic_failure', error, { context: 'screen_share_popout_init', }) - next.close() + // The open may already have cleared the pin and stored the window. + // Closing it alone would leave the meeting unpinned. + if (screenSharePopoutStore.entry) { + closeScreenSharePopout({ restorePin: true }) + } else { + next.close() + } } }, [announce, getVideoElement, release, t, title, trackSid, windowName])