[Xfce4-commits] [panel-plugins/xfce4-time-out-plugin] 13/15: Use xfce_titled_dialog_new_with_mixed_buttons if possible

noreply at xfce.org noreply at xfce.org
Fri Oct 4 05:13:48 CEST 2019


This is an automated email from the git hooks/post-receive script.

a   n   d   r   e       p   u   s   h   e   d       a       c   o   m   m   i   t       t   o       b   r   a   n   c   h       m   a   s   t   e   r   
   in repository panel-plugins/xfce4-time-out-plugin.

commit 8424ae73c6e9824190b359088772a03c4d55fd4b
Author: Andre Miranda <andreldm at xfce.org>
Date:   Sat Sep 28 19:34:44 2019 -0300

    Use xfce_titled_dialog_new_with_mixed_buttons if possible
---
 panel-plugin/time-out.c | 14 ++++++++++----
 1 file changed, 10 insertions(+), 4 deletions(-)

diff --git a/panel-plugin/time-out.c b/panel-plugin/time-out.c
index a24bd54..e16aadf 100644
--- a/panel-plugin/time-out.c
+++ b/panel-plugin/time-out.c
@@ -471,11 +471,17 @@ time_out_configure (XfcePanelPlugin *plugin,
   xfce_panel_plugin_block_menu (plugin);
 
   /* Create properties dialog */
+#if LIBXFCE4UI_CHECK_VERSION (4,14,0)
+  dialog = xfce_titled_dialog_new_with_mixed_buttons (_("Time Out"),
+    NULL, GTK_DIALOG_DESTROY_WITH_PARENT,
+    "window-close", _("_Close"), GTK_RESPONSE_OK,
+    NULL);
+#else
   dialog = xfce_titled_dialog_new_with_buttons (_("Time Out"),
-                                                GTK_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (plugin))),
-                                                GTK_DIALOG_DESTROY_WITH_PARENT | GTK_DIALOG_NO_SEPARATOR,
-                                                GTK_STOCK_CLOSE, GTK_RESPONSE_OK,
-                                                NULL);
+    NULL, GTK_DIALOG_DESTROY_WITH_PARENT,
+    "gtk-close", GTK_RESPONSE_OK,
+    NULL);
+#endif
 
   /* Set dialog property */
   g_object_set_data (G_OBJECT (plugin), "dialog", dialog);

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Xfce4-commits mailing list