From: Friedrich Beckmann Date: Sat, 20 Jun 2020 13:48:57 +0000 (+0200) Subject: main.c: set "register-session" property for gtk_application X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f58d1b69c4bbd4072fca4e79ea1e6a527ab09fae;p=pspp main.c: set "register-session" property for gtk_application To open an application by clicking an associated file like grid.sps in the Finder on Macos requires that the property "register-session" is set for gtk_application. I did not find a negative impact on Debian bullseye so I hope this works also on other platforms. The gtk support for this will be in the next gtk-3-24 release. See: https://gitlab.gnome.org/GNOME/gtk/-/merge_requests/2098 --- diff --git a/src/ui/gui/main.c b/src/ui/gui/main.c index f1b525f31c..dee766cbff 100644 --- a/src/ui/gui/main.c +++ b/src/ui/gui/main.c @@ -401,5 +401,6 @@ main (int argc, char *argv[]) g_action_map_add_action (G_ACTION_MAP (app), G_ACTION (act_new_data)); } + g_object_set (G_OBJECT (app), "register-session", TRUE, NULL); return g_application_run (G_APPLICATION (app), argc, argv); }