SpacingBat3 / WebCord

A Discord and SpaceBar :electron:-based client implemented without Discord API.
MIT License
1.89k stars 94 forks source link

Switch to`setDisplayMediaHandler` API. #353

Closed SpacingBat3 closed 11 months ago

SpacingBat3 commented 1 year ago

Since Electron 22 there's a new API to specifically handle requests send by getDisplayMedia, which sounds to be more appropiate that overwritting built-in functions with multiple scripts under-the-hood. This API also fixes the issue #186 for Windows (Chromium doesn't support other platforms so fixing this is out of the scope for this issue).

This is currently at work-in-progress, the API itself seems to be quite immature to be used and there's both no fallback code for older Electron versions nor Electron has adopted it to all currently supported versions.

SpacingBat3 commented 11 months ago

I'll probably re-attempt moving to it, given there's no reason to make the app backwards compatible with the older version of Electron and this API has been adopted in all currently-maintained Electron major releases.