[gnome-logs] Use gtk_show_uri API



commit 509bb76fe67f8de0f77afad03dc653bc5cf939bd
Author: Maximiliano Sandoval R <msandova gnome org>
Date:   Mon Oct 11 00:37:08 2021 +0200

    Use gtk_show_uri API
    
    gtk_show_uri_on_window was replaced by this.

 src/gl-application.c | 11 ++---------
 src/gl-window.c      | 11 ++---------
 2 files changed, 4 insertions(+), 18 deletions(-)
---
diff --git a/src/gl-application.c b/src/gl-application.c
index a89b7af..8d14b62 100644
--- a/src/gl-application.c
+++ b/src/gl-application.c
@@ -75,19 +75,12 @@ on_help (GSimpleAction *action,
 {
     GtkApplication *application;
     GtkWindow *parent;
-    GError *error = NULL;
 
     application = GTK_APPLICATION (user_data);
     parent = gtk_application_get_active_window (application);
 
-    gtk_show_uri_on_window (parent, "help:gnome-logs",
-                            GDK_CURRENT_TIME, &error);
-
-    if (error)
-    {
-        g_debug ("Error while opening help: %s", error->message);
-        g_error_free (error);
-    }
+    gtk_show_uri (parent, "help:gnome-logs",
+                  GDK_CURRENT_TIME);
 }
 
 static void
diff --git a/src/gl-window.c b/src/gl-window.c
index a46c2aa..8458294 100644
--- a/src/gl-window.c
+++ b/src/gl-window.c
@@ -263,19 +263,12 @@ on_help_button_clicked (GlWindow *window,
 {
     GlWindowPrivate *priv;
     GtkWindow *parent;
-    GError *error = NULL;
 
     parent = GTK_WINDOW (window);
     priv = gl_window_get_instance_private (GL_WINDOW (window));
 
-    gtk_show_uri_on_window (parent, "help:gnome-logs/permissions",
-                            GDK_CURRENT_TIME, &error);
-
-    if (error)
-    {
-        g_debug ("Error while opening help: %s", error->message);
-        g_error_free (error);
-    }
+    gtk_show_uri (parent, "help:gnome-logs/permissions",
+                  GDK_CURRENT_TIME);
 
     gtk_widget_hide (priv->info_bar);
 }


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]