Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix white space dropdown mac #12

Merged
merged 1 commit into from
Mar 8, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
fix white space mac
  • Loading branch information
nhayfield committed Mar 8, 2021
commit 38937e0f3404d02c1d4cc01dad3096bff91257df
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