[gnome-control-center/single-window-shell] [shell] use the window title rather than a separate header label
- From: Thomas Wood <thos src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gnome-control-center/single-window-shell] [shell] use the window title rather than a separate header label
- Date: Thu, 14 Jan 2010 15:35:31 +0000 (UTC)
commit 67619e3bd7880013738304d685d879363dabba73
Author: Thomas Wood <thomas wood intel com>
Date: Thu Jan 14 09:45:29 2010 +0000
[shell] use the window title rather than a separate header label
Remove the header label and use the window title to display the current
capplet's name.
shell/control-center.c | 10 ++++------
shell/shell.ui | 28 +++++++++++++---------------
2 files changed, 17 insertions(+), 21 deletions(-)
---
diff --git a/shell/control-center.c b/shell/control-center.c
index 1736dff..4c30577 100644
--- a/shell/control-center.c
+++ b/shell/control-center.c
@@ -213,7 +213,7 @@ item_activated_cb (GtkIconView *icon_view,
{
GtkTreeModel *model;
GtkTreeIter iter = {0,};
- gchar *name, *exec, *command, *markup;
+ gchar *name, *exec, *command;
GtkWidget *socket, *notebook;
guint socket_id = 0;
static gint index = -1;
@@ -239,10 +239,7 @@ item_activated_cb (GtkIconView *icon_view,
gtk_tree_model_get (model, &iter, 0, &name, 1, &exec, -1);
- markup = g_strdup_printf ("<b>%s</b>", name);
- gtk_label_set_markup (GTK_LABEL (W (builder, "applet-label")),
- markup);
- g_free (markup);
+ gtk_window_set_title (GTK_WINDOW (W (builder, "main-window")), name);
/* start app */
command = g_strdup_printf ("%s --socket=%u", exec, socket_id);
@@ -257,7 +254,8 @@ void
home_button_clicked_cb (GtkButton *button, GtkBuilder *builder)
{
gtk_notebook_set_current_page (GTK_NOTEBOOK (W (builder, "notebook")), 0);
- gtk_label_set_text (GTK_LABEL (W (builder, "applet-label")), "");
+ gtk_window_set_title (GTK_WINDOW (W (builder, "main-window")),
+ "System Settings");
}
int
diff --git a/shell/shell.ui b/shell/shell.ui
index 27b47fc..ee6e2cf 100644
--- a/shell/shell.ui
+++ b/shell/shell.ui
@@ -34,24 +34,22 @@
</packing>
</child>
<child>
- <object class="GtkLabel" id="applet-label">
- <property name="use_markup">True</property>
- </object>
- <packing>
- <property name="position">1</property>
- </packing>
- </child>
- <child>
- <object class="GtkEntry" id="search-entry">
- <property name="width_request">210</property>
+ <object class="GtkAlignment" id="alignment1">
<property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="invisible_char">●</property>
- <property name="text" translatable="yes">Type to search your settings</property>
+ <property name="xalign">1</property>
+ <property name="xscale">0</property>
+ <child>
+ <object class="GtkEntry" id="search-entry">
+ <property name="width_request">210</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="invisible_char">●</property>
+ <property name="text" translatable="yes">Type to search your settings</property>
+ </object>
+ </child>
</object>
<packing>
- <property name="expand">False</property>
- <property name="position">2</property>
+ <property name="position">1</property>
</packing>
</child>
</object>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]