Revert "xdg-desktop-portal-gtk: build without support for notifications"

This reverts commit c9e02bfd8a.

disable notifications at this level did not cause fractal (gtk app) to
send its notifications to swaync. instead, it still tried to deliver to
the Portal, where the Portal wasn't expecting anything and just returned
an error to fractal.

setting `GNOTIFICATION_BACKEND = "freedesktop"` seems to be the correct
way to get gtk apps to behave as desired with their notifications.
This commit is contained in:
2024-02-14 11:09:37 +00:00
parent 67fe8d4666
commit 5907d9fa42
2 changed files with 0 additions and 17 deletions

View File

@@ -93,7 +93,6 @@
./wob
./xarchiver.nix
./xdg-desktop-portal.nix
./xdg-desktop-portal-gtk.nix
./xdg-utils.nix
./zeal.nix
./zecwallet-lite.nix

View File

@@ -1,16 +0,0 @@
{ pkgs, ... }:
{
sane.programs.xdg-desktop-portal-gtk = {
packageUnwrapped = pkgs.xdg-desktop-portal-gtk.overrideAttrs (upstream: {
postPatch = (upstream.postPatch or "") + ''
# configure to not advertise the Notification portal.
# this can be patched at source level, or after building, at `$out/share/xdg-desktop-portals/portals/gtk.portal`.
# by removing this, xdg-desktop-portal won't advertise `org.freedesktop.portal.Notification`,
# and so portal-capable applications will prefer the non-portal `org.freedesktop.Notifications`,
# which is what most notification daemons (swaync, mako, ...) speak.
substituteInPlace data/gtk.portal.in \
--replace-fail 'org.freedesktop.impl.portal.Notification;' ""
'';
});
};
}