Skip to content
This repository has been archived by the owner on Mar 11, 2024. It is now read-only.

Commit

Permalink
fix: set the app window icon on Linux
Browse files Browse the repository at this point in the history
Electron should use the executable icon as the default application
window. However this seems broken on Linux. This might be related to
#41

This sets the alephium icon for the application to be displayed by the
wm on the window decoration, on windows switchers, etc.
  • Loading branch information
0xjac committed Nov 5, 2021
1 parent 421bea5 commit 0865ca8
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions public/electron.js
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,10 @@ function createWindow() {
titleBarStyle: process.platform === 'win32' ? 'default' : 'hidden'
})

if (process.platform === 'linux') {
mainWindow.setIcon(path.join(__dirname, "icons/logo-48.png"))
}

mainWindow.loadURL(isDev ? 'http://localhost:3000' : `file://${path.join(__dirname, '../build/index.html')}`)
if (isDev) {
// Open the DevTools.
Expand Down

0 comments on commit 0865ca8

Please sign in to comment.