[Xfce4-commits] [apps/parole] 01/01: Use infobar in preferences dialog for backend

noreply at xfce.org noreply at xfce.org
Fri Jul 4 13:14:11 CEST 2014


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

bluesabre pushed a commit to branch master
in repository apps/parole.

commit 26d1f6a5f1cdcc003b316137f9f9379e123aab38
Author: Sean Davis <smd.seandavis at gmail.com>
Date:   Fri Jul 4 07:14:05 2014 -0400

    Use infobar in preferences dialog for backend
---
 data/interfaces/parole-settings.ui |   76 ++++++++++++++++++++++++++++++++----
 src/parole-conf-dialog.c           |    4 ++
 2 files changed, 73 insertions(+), 7 deletions(-)

diff --git a/data/interfaces/parole-settings.ui b/data/interfaces/parole-settings.ui
index acf3891..a26a6ed 100644
--- a/data/interfaces/parole-settings.ui
+++ b/data/interfaces/parole-settings.ui
@@ -364,9 +364,9 @@
                       <object class="GtkAlignment" id="alignment7">
                         <property name="visible">True</property>
                         <property name="can_focus">False</property>
-                        <property name="left_padding">12</property>
                         <property name="margin_top">6</property>
                         <property name="margin_bottom">6</property>
+                        <property name="left_padding">12</property>
                         <child>
                           <object class="GtkBox" id="box11">
                             <property name="visible">True</property>
@@ -394,15 +394,77 @@
                               </packing>
                             </child>
                             <child>
-                              <object class="GtkLabel" id="label19">
-                                <property name="visible">True</property>
+                              <object class="GtkInfoBar" id="backend-infobar">
+                                <property name="app_paintable">True</property>
                                 <property name="can_focus">False</property>
-                                <property name="xalign">0</property>
-                                <property name="label" translatable="yes"><i>Changes to this field require Parole to be restarted.</i></property>
-                                <property name="use_markup">True</property>
+                                <property name="no_show_all">True</property>
+                                <child internal-child="action_area">
+                                  <object class="GtkButtonBox" id="infobar-action_area1">
+                                    <property name="can_focus">False</property>
+                                    <property name="spacing">6</property>
+                                    <property name="layout_style">end</property>
+                                    <child>
+                                      <placeholder/>
+                                    </child>
+                                    <child>
+                                      <placeholder/>
+                                    </child>
+                                    <child>
+                                      <placeholder/>
+                                    </child>
+                                  </object>
+                                  <packing>
+                                    <property name="expand">False</property>
+                                    <property name="fill">False</property>
+                                    <property name="position">0</property>
+                                  </packing>
+                                </child>
+                                <child internal-child="content_area">
+                                  <object class="GtkBox" id="infobar-content_area1">
+                                    <property name="can_focus">False</property>
+                                    <property name="spacing">16</property>
+                                    <child>
+                                      <object class="GtkImage" id="image1">
+                                        <property name="visible">True</property>
+                                        <property name="can_focus">False</property>
+                                        <property name="icon_name">info</property>
+                                        <property name="use_fallback">True</property>
+                                      </object>
+                                      <packing>
+                                        <property name="expand">False</property>
+                                        <property name="fill">True</property>
+                                        <property name="position">0</property>
+                                      </packing>
+                                    </child>
+                                    <child>
+                                      <object class="GtkLabel" id="label19">
+                                        <property name="visible">True</property>
+                                        <property name="can_focus">False</property>
+                                        <property name="xalign">0</property>
+                                        <property name="label" translatable="yes">Please restart Parole for this change to take effect.</property>
+                                      </object>
+                                      <packing>
+                                        <property name="expand">False</property>
+                                        <property name="fill">True</property>
+                                        <property name="position">1</property>
+                                      </packing>
+                                    </child>
+                                    <child>
+                                      <placeholder/>
+                                    </child>
+                                  </object>
+                                  <packing>
+                                    <property name="expand">False</property>
+                                    <property name="fill">False</property>
+                                    <property name="position">0</property>
+                                  </packing>
+                                </child>
+                                <child>
+                                  <placeholder/>
+                                </child>
                               </object>
                               <packing>
-                                <property name="expand">False</property>
+                                <property name="expand">True</property>
                                 <property name="fill">True</property>
                                 <property name="position">1</property>
                               </packing>
diff --git a/src/parole-conf-dialog.c b/src/parole-conf-dialog.c
index 2733bfc..de08abc 100644
--- a/src/parole-conf-dialog.c
+++ b/src/parole-conf-dialog.c
@@ -96,6 +96,7 @@ struct ParoleConfDialogPrivate
 
     GtkWidget  *vis_combox;
     GtkWidget  *sink_combox;
+    GtkWidget  *backend_infobar;
     GtkWidget  *toggle_vis;
     GtkWidget  *toggle_subtitle;
     GtkWidget  *font_button;
@@ -239,6 +240,8 @@ void parole_conf_dialog_sink_plugin_changed_cb (GtkComboBox *widget,  ParoleConf
                       NULL);
     }
 
+    gtk_widget_show (self->priv->backend_infobar);
+
     g_free (active);
 }
 
@@ -458,6 +461,7 @@ void parole_conf_dialog_open (ParoleConfDialog *self, GtkWidget *parent)
     #ifdef HAVE_CLUTTER
         parole_conf_dialog_add_clutter_sink (self, GTK_COMBO_BOX(self->priv->sink_combox));
     #endif
+    self->priv->backend_infobar = GTK_WIDGET (gtk_builder_get_object (builder, "backend-infobar"));
 
     parole_conf_dialog_set_defaults (self);
 

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


More information about the Xfce4-commits mailing list