Skip to content

Commit

Permalink
fix mac build
Browse files Browse the repository at this point in the history
  • Loading branch information
anthonyraymond committed Nov 2, 2023
1 parent 34e1e9c commit 4698a4f
Show file tree
Hide file tree
Showing 4 changed files with 7,856 additions and 5,475 deletions.
53 changes: 0 additions & 53 deletions app/electron/StateManager.js

This file was deleted.

18 changes: 5 additions & 13 deletions app/electron/WindowManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import {
dialog
} from 'electron';
import waitOn from 'wait-on';
import StateManager from './StateManager';
import MenuBuilder from './MenuBuilder';
import DependencyUpdater from './updaters/DependencyUpdater';
import Joal from './runner/Joal';
Expand All @@ -19,8 +18,6 @@ export default class WindowManager {

isUpdateInProgress = false;

stateManager = new StateManager();

joal = new Joal();

window = undefined;
Expand Down Expand Up @@ -51,8 +48,6 @@ export default class WindowManager {
window.on('close', e => {
WindowManager.saveWindowState(window, descriptor);

this.stateManager.save();

if (this.isUpdateInProgress) {
const pressedButton = dialog.showMessageBox(window, {
type: 'question',
Expand Down Expand Up @@ -97,9 +92,7 @@ export default class WindowManager {
const uiConfig = this.joal.start();
const configAsUrlParam = encodeURIComponent(JSON.stringify(uiConfig));

const uiUrl = `http://${uiConfig.host}:${uiConfig.port}/${
uiConfig.pathPrefix
}/ui?ui_credentials=${configAsUrlParam}`;
const uiUrl = `http://${uiConfig.host}:${uiConfig.port}/${uiConfig.pathPrefix}/ui?ui_credentials=${configAsUrlParam}`;
waitOn(
{
resources: [uiUrl],
Expand All @@ -123,11 +116,10 @@ export default class WindowManager {
}

openWindow() {
let descriptor = this.stateManager.getWindow();
if (descriptor === null || descriptor === undefined) {
this.stateManager.restoreWindow();
descriptor = this.stateManager.getWindow();
}
const descriptor = {
width: 1024,
height: 728
};

const options = {
// to avoid visible maximizing
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@
"css-loader": "^1.0.1",
"detect-port": "^1.3.0",
"electron": "^3.0.10",
"electron-builder": "22.11.7",
"electron-builder": "^24.6.4",
"electron-devtools-installer": "^2.2.4",
"electron-is-dev": "^1.0.1",
"enzyme": "^3.7.0",
Expand Down Expand Up @@ -248,7 +248,7 @@
"devtron": "^1.4.0",
"electron-debug": "^2.0.0",
"electron-log": "^2.2.17",
"electron-updater": "^5.3.0",
"electron-updater": "^6.1.4",
"gunzip-maybe": "^1.4.2",
"history": "^4.7.2",
"immutability-helper": "^3.0.0",
Expand Down
Loading

0 comments on commit 4698a4f

Please sign in to comment.