[Xfce4-commits] [xfce/xfce4-panel] 01/01: Fix "Primary" option appearing twice in prefs dialog

noreply at xfce.org noreply at xfce.org
Wed Apr 12 00:59:13 CEST 2017


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

ochosi pushed a commit to branch master
in repository xfce/xfce4-panel.

commit c2c3736addbb1c851a1e11863d994f6ff7d2db2d
Author: Simon Steinbeiss <simon.steinbeiss at elfenbeinturm.at>
Date:   Wed Apr 12 00:58:33 2017 +0200

    Fix "Primary" option appearing twice in prefs dialog
---
 panel/panel-preferences-dialog.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/panel/panel-preferences-dialog.c b/panel/panel-preferences-dialog.c
index f700b18..92ed352 100644
--- a/panel/panel-preferences-dialog.c
+++ b/panel/panel-preferences-dialog.c
@@ -492,12 +492,18 @@ panel_preferences_dialog_bindings_update (PanelPreferencesDialog *dialog)
       gtk_list_store_insert_with_values (GTK_LIST_STORE (store), &iter, n++,
                                          OUTPUT_NAME, "Automatic",
                                          OUTPUT_TITLE, _("Automatic"), -1);
+      if (g_strcmp0 (output_name, "Automatic") == 0) {
+        gtk_combo_box_set_active_iter (GTK_COMBO_BOX (object), &iter);
+        output_selected = TRUE;
+        span_monitors_sensitive = TRUE;
+      }
       gtk_list_store_insert_with_values (GTK_LIST_STORE (store), &iter, n++,
                                          OUTPUT_NAME, "Primary",
                                          OUTPUT_TITLE, _("Primary"), -1);
-      if (panel_str_is_empty (output_name))
+      if (panel_str_is_empty (output_name) ||
+          g_strcmp0 (output_name, "Primary") == 0)
         {
-          gtk_combo_box_set_active_iter  (GTK_COMBO_BOX (object), &iter);
+          gtk_combo_box_set_active_iter (GTK_COMBO_BOX (object), &iter);
           output_selected = TRUE;
           span_monitors_sensitive = TRUE;
         }

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


More information about the Xfce4-commits mailing list