mirror of
https://github.com/SchildiChat/element-web.git
synced 2024-10-01 01:26:12 -04:00
Merge pull request #2909 from vector-im/dbkr/enable_screen_sharing
Enable screen sharing easter-egg in desktop app
This commit is contained in:
commit
278de1398b
@ -148,6 +148,8 @@ process.on('uncaughtException', function (error) {
|
|||||||
|
|
||||||
electron.ipcMain.on('install_update', installUpdate);
|
electron.ipcMain.on('install_update', installUpdate);
|
||||||
|
|
||||||
|
electron.app.commandLine.appendSwitch('--enable-usermedia-screen-capturing');
|
||||||
|
|
||||||
electron.app.on('ready', () => {
|
electron.app.on('ready', () => {
|
||||||
if (vectorConfig.update_base_url) {
|
if (vectorConfig.update_base_url) {
|
||||||
console.log("Starting auto update with base URL: " + vectorConfig.update_base_url);
|
console.log("Starting auto update with base URL: " + vectorConfig.update_base_url);
|
||||||
|
@ -127,4 +127,8 @@ export default class ElectronPlatform extends VectorBasePlatform {
|
|||||||
getDefaultDeviceDisplayName() {
|
getDefaultDeviceDisplayName() {
|
||||||
return "Riot Desktop on " + platformFriendlyName();
|
return "Riot Desktop on " + platformFriendlyName();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
screenCaptureErrorString() {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -196,4 +196,12 @@ export default class WebPlatform extends VectorBasePlatform {
|
|||||||
return app_name + " via " + ua.getBrowser().name +
|
return app_name + " via " + ua.getBrowser().name +
|
||||||
" on " + ua.getOS().name;
|
" on " + ua.getOS().name;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
screenCaptureErrorString() {
|
||||||
|
// it won't work at all if you're not on HTTPS so whine whine whine
|
||||||
|
if (!global.window || global.window.location.protocol !== "https:") {
|
||||||
|
return "You need to be using HTTPS to place a screen-sharing call.";
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user