fix: correctly handle config updates
fix: synchronise updates to config with preload fix: send config on web contents load fix: hide menu when custom frame is off chore: add workarounds for developing on Nix chore: bump version to 1.1.10
This commit is contained in:
@@ -40,8 +40,8 @@ export function createMainWindow() {
|
||||
mainWindow = new BrowserWindow({
|
||||
minWidth: 300,
|
||||
minHeight: 300,
|
||||
width: 1100,
|
||||
height: 600,
|
||||
width: 1280,
|
||||
height: 720,
|
||||
backgroundColor: "#191919",
|
||||
frame: !config.customFrame,
|
||||
icon: windowIcon,
|
||||
@@ -54,6 +54,9 @@ export function createMainWindow() {
|
||||
},
|
||||
});
|
||||
|
||||
// hide the options
|
||||
mainWindow.setMenu(null);
|
||||
|
||||
// maximise the window if it was maximised before
|
||||
if (config.windowState.isMaximised) {
|
||||
mainWindow.maximize();
|
||||
@@ -101,6 +104,9 @@ export function createMainWindow() {
|
||||
}
|
||||
});
|
||||
|
||||
// send the config
|
||||
mainWindow.webContents.on("did-finish-load", () => config.sync());
|
||||
|
||||
// configure spellchecker context menu
|
||||
mainWindow.webContents.on("context-menu", (_, params) => {
|
||||
const menu = new Menu();
|
||||
|
||||
Reference in New Issue
Block a user