Skip to content

Commit

Permalink
Merge pull request #12 from pomerium/macWorkaround
Browse files Browse the repository at this point in the history
fix white space dropdown mac
  • Loading branch information
nhayfield committed Mar 8, 2021
2 parents af81fce + 38937e0 commit 420d26d
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 1 addition & 3 deletions src/main.dev.ts
Original file line number Diff line number Diff line change
Expand Up @@ -60,17 +60,15 @@ app.on('ready', async () => {
.then((name: string) => console.log(`Added Extension: ${name}`))
.catch((err: Error) => console.log('An error occurred: ', err));
mainWindow = createWindow();
mainWindow?.loadURL(`file:https://${__dirname}/index.html`);
const connections = new Connections();
const trayMenuHelper = new TrayMenuHelper(connections, mainWindow, null);
const tray = trayMenuHelper.createTray();
const menu = menubar({
tray,
preloadWindow: true,
browserWindow: { width: 0, height: 0 },
tray,
});
trayMenuHelper.setMenu(menu);

menu.on('ready', async () => {
menu.tray.setContextMenu(trayMenuHelper.createContextMenu(connections));
ipcMain.on(CONNECT, (evt, args: ConnectionData) => {
Expand Down
2 changes: 2 additions & 0 deletions src/utils/mainWindow.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ const createWindow = () => {
return false;
});

mainWindow?.loadURL(`file:https://${__dirname}/index.html`);

const menuBuilder = new MenuBuilder(mainWindow);
menuBuilder.buildMenu();

Expand Down

0 comments on commit 420d26d

Please sign in to comment.