diff --git a/build/Nexus Polestsar - App Icon.penpot b/build/Nexus Polestsar - App Icon.penpot index ad34a8a..e333a7e 100644 Binary files a/build/Nexus Polestsar - App Icon.penpot and b/build/Nexus Polestsar - App Icon.penpot differ diff --git a/build/icons/macOS/icon.icns b/build/icons/icon.icns similarity index 100% rename from build/icons/macOS/icon.icns rename to build/icons/icon.icns diff --git a/build/icons/Windows/icon.ico b/build/icons/icon.ico similarity index 100% rename from build/icons/Windows/icon.ico rename to build/icons/icon.ico diff --git a/build/icons/Linux/icon.png b/build/icons/icon.png similarity index 100% rename from build/icons/Linux/icon.png rename to build/icons/icon.png diff --git a/electron/index.js b/electron/index.js index a222f51..6210e24 100644 --- a/electron/index.js +++ b/electron/index.js @@ -2,8 +2,14 @@ const {app, BrowserWindow, Menu} = require('electron') const isDev = require('electron-is-dev'); const {TitlebarRespect} = require('electron-titlebar-respect') const glasstron = require('glasstron-clarity'); +const path = require('path') + + +// Use the correct icon depending on the operating system +if /* If macOS */ (process.platform == 'darwin') {global.AppIcon = 'public/images/icons/app/icon.icns' } +else if /* If Windows */ (process.platform == 'win32') {global.AppIcon = 'public/images/icons/app/icon.ico' } +else /* If Linux */ {global.AppIcon = 'public/images/icons/app/icon.png' } -let mainWindow; function createWindow () { const mainWindow = new glasstron.BrowserWindow({ @@ -17,6 +23,7 @@ function createWindow () { blur: true, frame: global.frame, titleBarStyle: global.titleBarStyle, + icon: path.join(global.AppIcon), trafficLightPosition: { x: 25, y: 25 }, // Position of Traffic Light buttons on macOS titleBarOverlay: { // Background and Height of Windows titlebar buttons color: '#191919', // Background