Bug 253170 - ShareWindow option does not work correctly
Summary: ShareWindow option does not work correctly
Status: RESOLVED MOVED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebRTC (show other bugs)
Version: Safari 16
Hardware: Mac (Intel) macOS 13
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2023-03-01 10:25 PST by rajesh.vaidya
Modified: 2023-06-26 03:54 PDT (History)
8 users (show)

See Also:


Attachments
Screen Recording of the issue with getDisplayMedia (57.90 MB, video/quicktime)
2023-04-05 03:52 PDT, vinayak.kulkarni
no flags Details
Broken window selection controls for “Share Window" (13.81 MB, image/png)
2023-05-17 02:30 PDT, Ilja Smorgun
no flags Details
Broken “Share Window” (133.31 MB, video/quicktime)
2023-05-17 02:34 PDT, Ilja Smorgun
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description rajesh.vaidya 2023-03-01 10:25:09 PST
Safari recently added support for "Share Window" in Safari 16.x / MacOS 13 (in addition to the existing "Share Screen").
However, the "Share Window" option does not work correctly - specifically the dialog that allows you to select the window to share does not always appear in the foreground.

To test this, run the following webRTC sample from github:
1) open  https://webrtc.github.io/samples/src/content/getusermedia/getdisplaymedia/ in Safari
2) click the "start button on the page.This will launch a pop-up
3) select "Allow to Share Window" option from the pop-up
4) The "Share this window" option is not visible - often it is behind other app windows.
Comment 1 Radar WebKit Bug Importer 2023-03-01 10:38:31 PST
<rdar://problem/106094452>
Comment 2 Eric Carlson 2023-03-02 12:51:03 PST
The "Share the window" button appears in whichever window the mouse is over when the picker is active, but you need to bring the window to the foreground if you want to click the button to share the window.
Comment 3 vinayak.kulkarni 2023-04-05 03:52:56 PDT
Created attachment 465770 [details]
Screen Recording of the issue with getDisplayMedia

Faced a similar problem with getDisplayMedia
I am on Ventura 13.2.1 and Safari 16.3
1. When I choose to "Share the Window", the "Share this Window" Pop up from Safari comes immediately and selecting which, screen share starts fine.
2. When I choose to "Share the Screen", the "Share this Screen" Pop up from Safari comes only after I hover my mouse on the screen. If I don't hover my mouse over the screen and wait for a minute, the "Share this Screen" pop up doesn't appear but it appears as soon as I hover my mouse.

It would be a better experience if the popup appears as soon as the permission is provided and user can then select which Screen to share by hovering over a different screen.

Sharing the screen recording as an attached. Please share if there is any work around for this.
Comment 4 Brown Zhang 2023-04-19 20:29:48 PDT
This issue can also be reproduced on Safari 16.4 running on OS 13.3.0 with an Intel chip. 
In another machine with OS 13.3.1, even though the "Share the Window" button is visible, clicking on it will result in a black video source (but you can see the mouse cursor).
Comment 5 vinayak.kulkarni 2023-04-21 07:08:33 PDT
Team please let us know if there is any update on this and/or if you need any more information on this to proceed. Thanks!
Comment 6 youenn fablet 2023-05-16 07:36:43 PDT
FWIW, I am able to reproduce on a recent 16.x Safari build, contrary to https://bugs.webkit.org/show_bug.cgi?id=255080.
Comment 7 Ilja Smorgun 2023-05-17 02:30:19 PDT
Created attachment 466381 [details]
Broken window selection controls for “Share Window"

I began experiencing issues with sharing windows after updating to Ventura 13.3.1 and Safari 16.4. Before the update everything worked fine. Now when attempting to share a window the sharing controls are shown in the top right corner of the screen and only a top thin part of the selected window is shared.
Comment 8 Ilja Smorgun 2023-05-17 02:31:25 PDT
Just to clarify. Sharing the entire screen works just fine. The issue is only with the “Share Window” option.
Comment 9 Ilja Smorgun 2023-05-17 02:34:37 PDT
Created attachment 466382 [details]
Broken “Share Window”
Comment 10 Brent Fulgham 2023-06-08 13:22:12 PDT
This was investigated under:
<rdar://109515021>
Comment 11 Brent Fulgham 2023-06-08 13:23:09 PDT
The fix for this issue needs to be made outside of WebKit. Consequently, resolving this as MOVED.

The actual fix is being tracked in rdar://109515021.