From 0c550497d17a1242dd1a2abbad182b2decb3c8cb Mon Sep 17 00:00:00 2001 From: Maximilian Federle Date: Sun, 24 May 2020 13:01:51 +0200 Subject: [PATCH] snap: Start org.freedesktop.portal.Desktop on launch Open & save dialogs might fail if it is not running. org.freedesktop.portal.Desktop is DBus activated and this doesn't play nicely with AppArmor at the moment. --- build-aux/snap/local/launchers/qelectrotech-launch | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/build-aux/snap/local/launchers/qelectrotech-launch b/build-aux/snap/local/launchers/qelectrotech-launch index 563581d5a..7f18f425d 100755 --- a/build-aux/snap/local/launchers/qelectrotech-launch +++ b/build-aux/snap/local/launchers/qelectrotech-launch @@ -23,4 +23,12 @@ fi mkdir -p "$HOME/.qet" ln -snf "$SNAP/bin/DXFtoQET" "$HOME/.qet/DXFtoQET" +# start desktop portal. Open & save dialogs might fail if it is not running +dbus-send --print-reply \ + --dest=org.freedesktop.DBus \ + /org/freedesktop/DBus \ + org.freedesktop.DBus.StartServiceByName \ + string:org.freedesktop.portal.Desktop \ + uint32:0 + exec "${@}"