SDA-3761 prevent setting the menu on Windows for the whole app (#1451)

This commit is contained in:
Salah Benmoussati 2022-07-11 09:57:45 +02:00 committed by GitHub
parent ef67053ad2
commit b94712685c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 8 additions and 6 deletions

View File

@ -165,7 +165,6 @@ export class AppMenu {
public buildMenu(): void {
// updates the global variables
this.updateGlobals();
this.menuList = menuItemsArray.reduce(
(map: Electron.MenuItemConstructorOptions, key: string) => {
map[key] = this.buildMenuKey(key);
@ -180,8 +179,6 @@ export class AppMenu {
this.menu = Menu.buildFromTemplate(template);
logger.info(`app-menu: built menu from the provided template`);
Menu.setApplicationMenu(this.menu);
logger.info(`app-menu: set application menu`);
// Remove the default menu for window
// as we use custom popup menu
@ -190,6 +187,9 @@ export class AppMenu {
if (mainWindow && windowExists(mainWindow)) {
mainWindow.setMenuBarVisibility(false);
}
} else {
logger.info(`app-menu: set application menu`);
Menu.setApplicationMenu(this.menu);
}
}

View File

@ -1,10 +1,14 @@
@import "theme";
@import 'theme';
@white: rgb(255, 255, 255, 1);
@version-text-color: rgb(47, 47, 47, 1);
@copyright-text-color: rgb(127, 127, 127, 1);
@text-padding: 10px;
::-webkit-scrollbar {
display: none;
}
body {
background-color: white;
margin: 0;
@ -25,7 +29,6 @@ body {
}
.AboutApp:lang(fr-FR) {
.AboutApp-symphony-section {
padding-left: 10px;
}
@ -134,4 +137,3 @@ body {
}
}
}