New Vesktop Icon

feedback welcome.

Also cleaned up icons and removed dynamically setting the icon (electron builder handles this)
This commit is contained in:
Kylie C 2024-09-19 19:17:54 -04:00
parent 24fbf35542
commit fc5a3e8a88
12 changed files with 12 additions and 15 deletions

Binary file not shown.

BIN
build/icon.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 364 KiB

1
build/icon.svg Normal file

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 19 KiB

View file

@ -74,7 +74,7 @@
], ],
"beforePack": "scripts/build/sandboxFix.js", "beforePack": "scripts/build/sandboxFix.js",
"linux": { "linux": {
"icon": "build/icon.icns", "icon": "build/icon.svg",
"category": "Network", "category": "Network",
"maintainer": "vendicated+vesktop@riseup.net", "maintainer": "vendicated+vesktop@riseup.net",
"target": [ "target": [
@ -160,6 +160,7 @@
"oneClick": false "oneClick": false
}, },
"win": { "win": {
"icon": "build/icon.ico",
"target": [ "target": [
{ {
"target": "nsis", "target": "nsis",
@ -181,9 +182,9 @@
"provider": "github" "provider": "github"
}, },
"rpm": { "rpm": {
"fpm": [ "fpm": [
"--rpm-rpmbuild-define=_build_id_links none" "--rpm-rpmbuild-define=_build_id_links none"
] ]
} }
}, },
"pnpm": { "pnpm": {
@ -192,4 +193,3 @@
} }
} }
} }

View file

@ -6,7 +6,7 @@
import { BrowserWindow } from "electron"; import { BrowserWindow } from "electron";
import { join } from "path"; import { join } from "path";
import { ICON_PATH, VIEW_DIR } from "shared/paths"; import { VIEW_DIR } from "shared/paths";
import { makeLinksOpenExternally } from "./utils/makeLinksOpenExternally"; import { makeLinksOpenExternally } from "./utils/makeLinksOpenExternally";
@ -14,7 +14,6 @@ export function createAboutWindow() {
const about = new BrowserWindow({ const about = new BrowserWindow({
center: true, center: true,
autoHideMenuBar: true, autoHideMenuBar: true,
icon: ICON_PATH,
webPreferences: { webPreferences: {
preload: join(__dirname, "updaterPreload.js") preload: join(__dirname, "updaterPreload.js")
} }

View file

@ -9,7 +9,7 @@ import { BrowserWindow } from "electron/main";
import { copyFileSync, mkdirSync, readdirSync } from "fs"; import { copyFileSync, mkdirSync, readdirSync } from "fs";
import { join } from "path"; import { join } from "path";
import { SplashProps } from "shared/browserWinProperties"; import { SplashProps } from "shared/browserWinProperties";
import { ICON_PATH, VIEW_DIR } from "shared/paths"; import { VIEW_DIR } from "shared/paths";
import { autoStart } from "./autoStart"; import { autoStart } from "./autoStart";
import { DATA_DIR } from "./constants"; import { DATA_DIR } from "./constants";
@ -31,8 +31,7 @@ export function createFirstLaunchTour() {
frame: true, frame: true,
autoHideMenuBar: true, autoHideMenuBar: true,
height: 470, height: 470,
width: 550, width: 550
icon: ICON_PATH
}); });
makeLinksOpenExternally(win); makeLinksOpenExternally(win);

View file

@ -23,7 +23,7 @@ import { isTruthy } from "shared/utils/guards";
import { once } from "shared/utils/once"; import { once } from "shared/utils/once";
import type { SettingsStore } from "shared/utils/SettingsStore"; import type { SettingsStore } from "shared/utils/SettingsStore";
import { ICON_PATH } from "../shared/paths"; import { TRAY_ICON_PATH } from "../shared/paths";
import { createAboutWindow } from "./about"; import { createAboutWindow } from "./about";
import { initArRPC } from "./arrpc"; import { initArRPC } from "./arrpc";
import { import {
@ -123,7 +123,7 @@ function initTray(win: BrowserWindow) {
} }
]); ]);
tray = new Tray(ICON_PATH); tray = new Tray(TRAY_ICON_PATH);
tray.setToolTip("Vesktop"); tray.setToolTip("Vesktop");
tray.setContextMenu(trayMenu); tray.setContextMenu(trayMenu);
tray.on("click", onTrayClick); tray.on("click", onTrayClick);
@ -407,7 +407,6 @@ function createMainWindow() {
// disable renderer backgrounding to prevent the app from unloading when in the background // disable renderer backgrounding to prevent the app from unloading when in the background
backgroundThrottling: false backgroundThrottling: false
}, },
icon: ICON_PATH,
frame: !noFrame, frame: !noFrame,
...(transparent && { ...(transparent && {
transparent: true, transparent: true,

View file

@ -7,14 +7,13 @@
import { BrowserWindow } from "electron"; import { BrowserWindow } from "electron";
import { join } from "path"; import { join } from "path";
import { SplashProps } from "shared/browserWinProperties"; import { SplashProps } from "shared/browserWinProperties";
import { ICON_PATH, VIEW_DIR } from "shared/paths"; import { VIEW_DIR } from "shared/paths";
import { Settings } from "./settings"; import { Settings } from "./settings";
export function createSplashWindow(startMinimized = false) { export function createSplashWindow(startMinimized = false) {
const splash = new BrowserWindow({ const splash = new BrowserWindow({
...SplashProps, ...SplashProps,
icon: ICON_PATH,
show: !startMinimized show: !startMinimized
}); });

View file

@ -9,4 +9,4 @@ import { join } from "path";
export const STATIC_DIR = /* @__PURE__ */ join(__dirname, "..", "..", "static"); export const STATIC_DIR = /* @__PURE__ */ join(__dirname, "..", "..", "static");
export const VIEW_DIR = /* @__PURE__ */ join(STATIC_DIR, "views"); export const VIEW_DIR = /* @__PURE__ */ join(STATIC_DIR, "views");
export const BADGE_DIR = /* @__PURE__ */ join(STATIC_DIR, "badges"); export const BADGE_DIR = /* @__PURE__ */ join(STATIC_DIR, "badges");
export const ICON_PATH = /* @__PURE__ */ join(STATIC_DIR, "icon.png"); export const TRAY_ICON_PATH = /* @__PURE__ */ join(STATIC_DIR, "tray.png");

Binary file not shown.

Before

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.5 KiB

View file

Before

Width:  |  Height:  |  Size: 9.5 KiB

After

Width:  |  Height:  |  Size: 9.5 KiB