Skip to content

Commit

Permalink
SDA-4422 Bug - Workaroud for frameless transparent windows titlebar b…
Browse files Browse the repository at this point in the history
…eing displayed (#2041)
  • Loading branch information
sbenmoussati committed Dec 28, 2023
1 parent c79922f commit 8422af2
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/app/window-utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,16 @@ export const createComponentWindow = (
browserWindow.show();
});
}

// SDA-4422 workaround
if (!options.frame && options.transparent) {
browserWindow.on('blur', () => {
browserWindow.setBackgroundColor('#00000000');
});
browserWindow.on('focus', () => {
browserWindow.setBackgroundColor('#00000000');
});
}
browserWindow.webContents.once('did-finish-load', () => {
if (!browserWindow || !windowExists(browserWindow)) {
return;
Expand Down

0 comments on commit 8422af2

Please sign in to comment.