pidgin/pidgin

Use GtkUriLauncher directly in Pidgin

3 weeks ago, Gary Kramlich
bd2da74b9201
Parents b45add2a840c
Children 801025bad2e1
Use GtkUriLauncher directly in Pidgin

There's no need to call purple_notify_uri in Pidgin when we can just use a
GtkUriLauncher directly.

Testing Done:
Had the turtles do their thing and then opened both uris from pidgin.

Reviewed at https://reviews.imfreedom.org/r/3147/
--- a/pidgin/pidginapplication.c Thu Apr 25 21:10:37 2024 -0500
+++ b/pidgin/pidginapplication.c Sat Apr 27 22:31:37 2024 -0500
@@ -336,7 +336,11 @@
G_GNUC_UNUSED GVariant *parameter,
G_GNUC_UNUSED gpointer data)
{
- purple_notify_uri(NULL, "https://www.imfreedom.org/donate/");
+ GtkUriLauncher *launcher = NULL;
+
+ launcher = gtk_uri_launcher_new("https://www.imfreedom.org/donate/");
+ gtk_uri_launcher_launch(launcher, NULL, NULL, NULL, NULL);
+ g_clear_object(&launcher);
}
static void
@@ -427,7 +431,11 @@
G_GNUC_UNUSED GVariant *parameter,
G_GNUC_UNUSED gpointer data)
{
- purple_notify_uri(NULL, PURPLE_WEBSITE "help");
+ GtkUriLauncher *launcher = NULL;
+
+ launcher = gtk_uri_launcher_new(PURPLE_WEBSITE "help");
+ gtk_uri_launcher_launch(launcher, NULL, NULL, NULL, NULL);
+ g_clear_object(&launcher);
}
static void