mirror of
https://github.com/finos/SymphonyElectron.git
synced 2025-02-25 18:55:29 -06:00
Merge pull request #991 from johankwarnmarksymphony/sda-2009
fix: screen share frame stay
This commit is contained in:
commit
03b49240ba
@ -507,14 +507,13 @@ export class WindowHandler {
|
|||||||
|
|
||||||
if (browserWindow && windowExists(browserWindow)) {
|
if (browserWindow && windowExists(browserWindow)) {
|
||||||
browserWindow.destroy();
|
browserWindow.destroy();
|
||||||
|
}
|
||||||
if (isWindowsOS || isMac) {
|
}
|
||||||
this.execCmd(this.screenShareIndicatorFrameUtil, []);
|
if (isWindowsOS || isMac) {
|
||||||
} else {
|
this.execCmd(this.screenShareIndicatorFrameUtil, []);
|
||||||
if (this.screenSharingFrameWindow && windowExists(this.screenSharingFrameWindow)) {
|
} else {
|
||||||
this.screenSharingFrameWindow.close();
|
if (this.screenSharingFrameWindow && windowExists(this.screenSharingFrameWindow)) {
|
||||||
}
|
this.screenSharingFrameWindow.close();
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -719,6 +718,12 @@ export class WindowHandler {
|
|||||||
this.addWindow(opts.winKey, this.screenPickerWindow);
|
this.addWindow(opts.winKey, this.screenPickerWindow);
|
||||||
});
|
});
|
||||||
ipcMain.once('screen-source-selected', (_event, source) => {
|
ipcMain.once('screen-source-selected', (_event, source) => {
|
||||||
|
const displays = electron.screen.getAllDisplays();
|
||||||
|
logger.info('window-utils: displays.length: ' + displays.length);
|
||||||
|
for (let i = 0, len = displays.length; i < len; i++) {
|
||||||
|
logger.info('window-utils: display[' + i + ']: ' + JSON.stringify(displays[ i ]));
|
||||||
|
}
|
||||||
|
|
||||||
if (source != null) {
|
if (source != null) {
|
||||||
logger.info(`window-handler: screen-source-selected`, source, id);
|
logger.info(`window-handler: screen-source-selected`, source, id);
|
||||||
if (isWindowsOS || isMac) {
|
if (isWindowsOS || isMac) {
|
||||||
@ -734,7 +739,13 @@ export class WindowHandler {
|
|||||||
if (source.display_id !== '') {
|
if (source.display_id !== '') {
|
||||||
this.execCmd(this.screenShareIndicatorFrameUtil, [ source.display_id ]);
|
this.execCmd(this.screenShareIndicatorFrameUtil, [ source.display_id ]);
|
||||||
} else {
|
} else {
|
||||||
this.execCmd(this.screenShareIndicatorFrameUtil, [ '0' ]);
|
const dispId = source.id.split(':')[1];
|
||||||
|
const keyId = 'id';
|
||||||
|
|
||||||
|
logger.info('window-utils: dispId: ' + dispId);
|
||||||
|
logger.info('window-utils: displays [' + dispId + '] [id]: ' + displays [dispId] [ keyId ]);
|
||||||
|
|
||||||
|
this.execCmd(this.screenShareIndicatorFrameUtil, [ displays [dispId] [ keyId ].toString() ]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user