diff --git a/settings/quickshell.nix b/settings/quickshell.nix index 7dab244..68dfd48 100644 --- a/settings/quickshell.nix +++ b/settings/quickshell.nix @@ -1748,6 +1748,14 @@ in keepOnReload: true onNotification: (notification) => { notification.tracked = true; + // Tracked notifications are never expired, and the list + // renders through a Repeater — every delegate is live, + // no view recycling. Left uncapped, a day's worth of + // notifications is a day's worth of retained image + // textures being repainted, which measurably starves + // games of the GPU. Drop the oldest past the cap. + const kept = [...(_notifServer.trackedNotifications.values)]; + for (let i = 0; i < kept.length - 30; i++) kept[i].dismiss(); root.latestNotification = notification; root.notificationReceived(); }