Agora-Flutter-SDK icon indicating copy to clipboard operation
Agora-Flutter-SDK copied to clipboard

Don't know when user cancelled the browser screen sharing

Open tp opened this issue 3 years ago • 3 comments

Describe the bug When we initiate a screen share in the browser, we can't detect when the user presses "Cancel".

Instead startScreenCaptureByWindowId stays in pending state forever and I also didn't see any event handler firing.

To Reproduce Our application code is pretty much like the example here:

https://github.com/AgoraIO/Agora-Flutter-SDK/blob/dev/flutter2/example/lib/examples/advanced/screen_sharing.dart#L129

To reproduce, initiate the screensharing in the browser and then cancel (in the browser UI)

image

Expected behavior

Would be great to be able to find out when the user cancelled the screenshare in the browser (an exception from startScreenCaptureByWindowId would work just fine).

Our use-case is showing a loading spinner while the screen share is being set up, and I didn't see a way to make that disappear if the flow fails.

Desktop (please complete the following information):

  • OS: macOS
  • Browser: Chrome
  • Version: 97.0.4692.99 (Official Build) (arm64)

tp avatar Feb 03 '22 10:02 tp

Sorry for the late reply, any error when you cancel the screen sharing?

LichKing-2234 avatar Mar 09 '22 11:03 LichKing-2234

Sorry for the late reply, any error when you cancel the screen sharing?

LichKing-2234 avatar Mar 09 '22 11:03 LichKing-2234

Sorry for the late reply, any error when you cancel the screen sharing?

No, I don't see anything. The await just stalls forever, but no exception or status callback is coming in notifying me of that.

I think ideally the screenshare Future would just throw so it can be caught right then and there.

tp avatar Mar 09 '22 15:03 tp

Hi, any luck with this issue? i am stuck with same issue

Allamprabhu1058 avatar Oct 04 '23 09:10 Allamprabhu1058

The web support for agora_rtc_engine 6.x has landed in the main branch, If you still face issues, please try the latest code in main branch to see if it works or not.

littleGnAl avatar Nov 14 '23 08:11 littleGnAl

Without additional information, we are unfortunately not sure how to resolve this issue. We are therefore reluctantly going to close this bug for now. If you find this problem please file a new issue with the same description, what happens, logs and the output. All system setups can be slightly different so it's always better to open new issues and reference the related ones. Thanks for your contribution.

github-actions[bot] avatar Nov 28 '23 09:11 github-actions[bot]

This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please raise a new issue.

github-actions[bot] avatar Dec 05 '23 10:12 github-actions[bot]