[gedit] Move the statusbar buttons in the ui file
- From: Paolo Borelli <pborelli src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gedit] Move the statusbar buttons in the ui file
- Date: Sun, 16 Mar 2014 09:08:13 +0000 (UTC)
commit 1a700f4be865e88c9f3e10a9d011d7ea35e64a51
Author: Paolo Borelli <pborelli gnome org>
Date: Sun Mar 16 10:06:00 2014 +0100
Move the statusbar buttons in the ui file
gedit/gedit-window.c | 17 ++---------------
gedit/gedit-window.ui | 22 ++++++++++++++++++++++
2 files changed, 24 insertions(+), 15 deletions(-)
---
diff --git a/gedit/gedit-window.c b/gedit/gedit-window.c
index 1eb92ea..c691b78 100644
--- a/gedit/gedit-window.c
+++ b/gedit/gedit-window.c
@@ -413,6 +413,8 @@ gedit_window_class_init (GeditWindowClass *klass)
gtk_widget_class_bind_template_child_private (widget_class, GeditWindow, bottom_panel_box);
gtk_widget_class_bind_template_child_private (widget_class, GeditWindow, bottom_panel);
gtk_widget_class_bind_template_child_private (widget_class, GeditWindow, statusbar);
+ gtk_widget_class_bind_template_child_private (widget_class, GeditWindow, language_button);
+ gtk_widget_class_bind_template_child_private (widget_class, GeditWindow, tab_width_combo);
gtk_widget_class_bind_template_child_private (widget_class, GeditWindow, fullscreen_controls);
gtk_widget_class_bind_template_child_private (widget_class, GeditWindow, fullscreen_eventbox);
gtk_widget_class_bind_template_child_private (widget_class, GeditWindow, fullscreen_headerbar);
@@ -832,28 +834,13 @@ setup_statusbar (GeditWindow *window)
G_SETTINGS_BIND_GET);
/* Tab Width button */
- window->priv->tab_width_combo = gedit_status_menu_button_new ();
- gtk_menu_button_set_use_popover (GTK_MENU_BUTTON (window->priv->tab_width_combo), TRUE);
gtk_menu_button_set_menu_model (GTK_MENU_BUTTON (window->priv->tab_width_combo),
_gedit_app_get_tab_width_menu (GEDIT_APP (g_application_get_default
())));
- gtk_widget_show (window->priv->tab_width_combo);
- gtk_box_pack_end (GTK_BOX (window->priv->statusbar),
- window->priv->tab_width_combo,
- FALSE,
- TRUE,
- 0);
/* Language button */
- window->priv->language_button = gedit_status_menu_button_new ();
window->priv->language_popover = gtk_popover_new (window->priv->language_button);
gtk_menu_button_set_popover (GTK_MENU_BUTTON (window->priv->language_button),
window->priv->language_popover);
- gtk_widget_show (window->priv->language_button);
- gtk_box_pack_end (GTK_BOX (window->priv->statusbar),
- window->priv->language_button,
- FALSE,
- TRUE,
- 0);
sel = gedit_highlight_mode_selector_new ();
g_signal_connect (sel,
diff --git a/gedit/gedit-window.ui b/gedit/gedit-window.ui
index e6b6842..5f95b4b 100644
--- a/gedit/gedit-window.ui
+++ b/gedit/gedit-window.ui
@@ -286,6 +286,28 @@
<child>
<object class="GeditStatusbar" id="statusbar">
<property name="visible">True</property>
+ <child>
+ <object class="GeditStatusMenuButton" id="tab_width_combo">
+ <property name="visible">True</property>
+ <property name="use_popover">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="pack_type">end</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GeditStatusMenuButton" id="language_button">
+ <property name="visible">True</property>
+ <property name="use_popover">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="pack_type">end</property>
+ </packing>
+ </child>
</object>
<packing>
<property name="expand">False</property>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]