feat: add taskbar flashing on new notifications (#1209)

Co-authored-by: V <vendicated@riseup.net>
This commit is contained in:
futamebore
2025-12-12 22:23:13 +01:00
committed by GitHub
parent 98b0ba85a3
commit da8e8f52ab
7 changed files with 48 additions and 1 deletions

View File

@@ -124,7 +124,15 @@ const SettingsOptions: Record<string, Array<BooleanSetting | SettingsComponent>>
defaultValue: false
}
],
Notifications: [NotificationBadgeToggle],
Notifications: [
NotificationBadgeToggle,
{
key: "enableTaskbarFlashing",
title: "Enable Taskbar Flashing",
description: "Flashes the app in your taskbar when you have new notifications.",
defaultValue: false
}
],
Miscellaneous: [
{
key: "arRPC",

View File

@@ -0,0 +1,27 @@
/*
* Vesktop, a desktop app aiming to give you a snappier Discord Experience
* Copyright (c) 2025 Vendicated and Vesktop contributors
* SPDX-License-Identifier: GPL-3.0-or-later
*/
import { Settings } from "renderer/settings";
import { addPatch } from "./shared";
addPatch({
patches: [
{
find: ".flashFrame(!0)",
replacement: {
match: /(\i)&&\i\.\i\.taskbarFlash&&\i\.\i\.flashFrame\(!0\)/,
replace: "$self.flashFrame()"
}
}
],
flashFrame() {
if (Settings.store.enableTaskbarFlashing) {
VesktopNative.win.flashFrame(true);
}
}
});