more tweaks for windoof

master
Michael Ochmann 3 years ago
parent 9b8da8be9e
commit d74650e32e
  1. 2
      package-lock.json
  2. 2
      package.json
  3. 11
      src/WindowManager.js

2
package-lock.json generated

@ -1,6 +1,6 @@
{
"name": "ation",
"version": "0.3.2",
"version": "0.3.3",
"lockfileVersion": 1,
"requires": true,
"dependencies": {

@ -1,6 +1,6 @@
{
"name": "ation",
"version": "0.3.2",
"version": "0.3.3",
"description": "a simple presentation software",
"main": "main.js",
"scripts": {

@ -25,8 +25,7 @@ class WindowManager {
init() {
this.mainWindow = WindowManager._CreateWindow({
fullscreen : false,
fullscreenable : true,
autoHideMenuBar : process.platform === "win32"
fullscreenable : true
});
this.windows.settings = WindowManager._CreateWindow({
height : 300,
@ -40,6 +39,14 @@ class WindowManager {
// window, because it would look odd.
if (["win32", "linux"].includes(process.platform)) {
this.windows.settings.removeMenu();
// we also need to hide the application menu
this.mainWindow.on("enter-full-screen", () => {
this.mainWindow.setAutoHideMenuBar(true);
});
this.mainWindow.on("leave-full-screen", () => {
this.mainWindow.setAutoHideMenuBar(false);
});
}
this.windows.settings.on("close", event => {

Loading…
Cancel
Save