mirror of
https://github.com/finos/SymphonyElectron.git
synced 2025-02-25 18:55:29 -06:00
npm fix for optionnal dependency
This commit is contained in:
parent
452b84499d
commit
a5eb41f55a
12777
package-lock.json
generated
12777
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -233,7 +233,7 @@
|
||||
},
|
||||
"optionalDependencies": {
|
||||
"@symphony/symphony-c9-shell": "3.30.0-37.176",
|
||||
"screen-share-indicator-frame": "git+https://github.com/finos/ScreenShareIndicatorFrame.git#v1.5.0",
|
||||
"screen-share-indicator-frame": "github:finos/ScreenShareIndicatorFrame#v1.5.0",
|
||||
"screen-snippet": "git+https://github.com/finos/ScreenSnippet2.git#9.2.2",
|
||||
"symphony-native-window-handle-helper": "github:finos/SymphonyWindowsHwndHelper#1.0.1",
|
||||
"winreg": "^1.2.4"
|
||||
|
@ -1569,9 +1569,22 @@ export class WindowHandler {
|
||||
logger.info(
|
||||
'window-handler: source.display_id: ' + source.display_id,
|
||||
);
|
||||
const [sharedScreen] = displays.filter(
|
||||
(display) => display.id.toString() === source.display_id.toString(),
|
||||
);
|
||||
let displayId = source.display_id;
|
||||
let sharedScreen;
|
||||
if (displayId) {
|
||||
[sharedScreen] = displays.filter(
|
||||
(display) => display.id.toString() === displayId.toString(),
|
||||
);
|
||||
} else {
|
||||
logger.warn(
|
||||
'window-handler: no display id found - trying to find correct display',
|
||||
);
|
||||
const dispId = source.id.split(':')[1];
|
||||
displayId = Math.min(dispId, displays.length - 1);
|
||||
logger.info('window-handler: dispId: ' + dispId);
|
||||
logger.info('window-handler: clampedDispId: ' + displayId);
|
||||
sharedScreen = displays[displayId];
|
||||
}
|
||||
if (sharedScreen) {
|
||||
const left =
|
||||
sharedScreen.nativeOrigin.x * (sharedScreen.scaleFactor || 1);
|
||||
@ -1591,7 +1604,7 @@ export class WindowHandler {
|
||||
]);
|
||||
} else {
|
||||
logger.error(
|
||||
`window-handler: no screen found with id ${source.display_id}`,
|
||||
`window-handler: no screen found with id ${source.display_id} or ${displayId}`,
|
||||
);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user