diff --git a/app/assets/ollama_icon_birhgt_16x16.png b/app/assets/ollama_icon_16x16Template.png similarity index 100% rename from app/assets/ollama_icon_birhgt_16x16.png rename to app/assets/ollama_icon_16x16Template.png diff --git a/app/assets/ollama_icon_bright_16x16@2x.png b/app/assets/ollama_icon_16x16Template@2x.png similarity index 100% rename from app/assets/ollama_icon_bright_16x16@2x.png rename to app/assets/ollama_icon_16x16Template@2x.png diff --git a/app/assets/ollama_icon_dark_16x16.png b/app/assets/ollama_icon_dark_16x16.png deleted file mode 100644 index 804ead03..00000000 Binary files a/app/assets/ollama_icon_dark_16x16.png and /dev/null differ diff --git a/app/assets/ollama_icon_dark_16x16@2x.png b/app/assets/ollama_icon_dark_16x16@2x.png deleted file mode 100644 index 0366c6f3..00000000 Binary files a/app/assets/ollama_icon_dark_16x16@2x.png and /dev/null differ diff --git a/app/forge.config.ts b/app/forge.config.ts index b2b40324..420ecff0 100644 --- a/app/forge.config.ts +++ b/app/forge.config.ts @@ -19,8 +19,8 @@ const config: ForgeConfig = { icon: './assets/icon.icns', extraResource: [ '../ollama', - path.join(__dirname, './assets/ollama_icon_dark_16x16@2x.png'), - path.join(__dirname, './assets/ollama_icon_bright_16x16@2x.png'), + path.join(__dirname, './assets/ollama_icon_16x16Template.png'), + path.join(__dirname, './assets/ollama_icon_16x16Template@2x.png'), ...(process.platform === 'darwin' ? ['../ggml-metal.metal'] : []), ], ...(process.env.SIGN diff --git a/app/src/index.ts b/app/src/index.ts index 2a8cbe8a..268fed29 100644 --- a/app/src/index.ts +++ b/app/src/index.ts @@ -1,5 +1,5 @@ import { spawn, exec } from 'child_process' -import { app, autoUpdater, dialog, Tray, Menu, nativeTheme } from 'electron' +import { app, autoUpdater, dialog, Tray, Menu } from 'electron' import * as path from 'path' import * as fs from 'fs' @@ -15,22 +15,14 @@ if (!SingleInstanceLock) { } const createSystemtray = () => { - let brightModeIconPath = path.join(__dirname, '..', '..', 'assets', 'ollama_icon_dark_16x16.png') - let darkModeIconPath = path.join(__dirname, '..', '..', 'assets', 'ollama_icon_bright_16x16.png') + + let iconPath = path.join(__dirname, '..', '..', 'assets', 'ollama_icon_16x16Template.png') if (app.isPackaged) { - brightModeIconPath = path.join(process.resourcesPath, 'ollama_icon_dark_16x16@2x.png') - darkModeIconPath = path.join(process.resourcesPath, 'ollama_icon_bright_16x16@2x.png') + iconPath = path.join(process.resourcesPath, 'ollama_icon_16x16Template.png') } - tray = new Tray(brightModeIconPath) - - if (process.platform === 'darwin') { - tray.setImage(nativeTheme.shouldUseDarkColors ? darkModeIconPath : brightModeIconPath) - nativeTheme.on('updated', () => { - tray.setImage(nativeTheme.shouldUseDarkColors ? darkModeIconPath : brightModeIconPath) - }) - } + tray = new Tray(iconPath) const contextMenu = Menu.buildFromTemplate([{ role: 'quit', label: 'Quit Ollama', accelerator: 'Command+Q' }])