SDA-3440 - Disable Zoom for notification windows (#1313)

This commit is contained in:
Kiran Niranjan 2022-01-06 10:15:40 +05:30 committed by GitHub
parent f63c61b50d
commit 1f68c69cf4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -784,6 +784,15 @@ export const zoomIn = () => {
return;
}
// Disable Zoom for notification windows
if (
(focusedWindow as ICustomBrowserWindow).winName &&
(focusedWindow as ICustomBrowserWindow).winName ===
apiName.notificationWindowName
) {
return;
}
let { webContents } = focusedWindow;
// If the focused window is mainWindow we should use mainWebContents
@ -835,6 +844,15 @@ export const zoomOut = () => {
return;
}
// Disable Zoom for notification windows
if (
(focusedWindow as ICustomBrowserWindow).winName &&
(focusedWindow as ICustomBrowserWindow).winName ===
apiName.notificationWindowName
) {
return;
}
let { webContents } = focusedWindow;
// If the focused window is mainWindow we should use mainWebContents
@ -881,6 +899,14 @@ export const resetZoomLevel = () => {
if (!focusedWindow || !windowExists(focusedWindow)) {
return;
}
// Disable Zoom for notification windows
if (
(focusedWindow as ICustomBrowserWindow).winName &&
(focusedWindow as ICustomBrowserWindow).winName ===
apiName.notificationWindowName
) {
return;
}
let { webContents } = focusedWindow;
// If the focused window is mainWindow we should use mainWebContents
if (