aboutsummaryrefslogtreecommitdiffstats
path: root/shell/e-shell-window.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@src.gnome.org>2008-09-07 12:02:27 +0800
committerMatthew Barnes <mbarnes@src.gnome.org>2008-09-07 12:02:27 +0800
commit52d683e48cf1103a9806da95c72abce2db3ae1f4 (patch)
treeb6cee16af70a03666a2d7add2e5bff5c6ed8035c /shell/e-shell-window.c
parenteca687589d106ff87cd4fca7bf581cb0532caf96 (diff)
downloadgsoc2013-evolution-52d683e48cf1103a9806da95c72abce2db3ae1f4.tar
gsoc2013-evolution-52d683e48cf1103a9806da95c72abce2db3ae1f4.tar.gz
gsoc2013-evolution-52d683e48cf1103a9806da95c72abce2db3ae1f4.tar.bz2
gsoc2013-evolution-52d683e48cf1103a9806da95c72abce2db3ae1f4.tar.lz
gsoc2013-evolution-52d683e48cf1103a9806da95c72abce2db3ae1f4.tar.xz
gsoc2013-evolution-52d683e48cf1103a9806da95c72abce2db3ae1f4.tar.zst
gsoc2013-evolution-52d683e48cf1103a9806da95c72abce2db3ae1f4.zip
Progress update:
- Contacts module mostly working now. - View and search UI not yet working. - Still refining shell design. svn path=/branches/kill-bonobo/; revision=36268
Diffstat (limited to 'shell/e-shell-window.c')
-rw-r--r--shell/e-shell-window.c26
1 files changed, 26 insertions, 0 deletions
diff --git a/shell/e-shell-window.c b/shell/e-shell-window.c
index c53867b527..8d2e3c1180 100644
--- a/shell/e-shell-window.c
+++ b/shell/e-shell-window.c
@@ -40,6 +40,27 @@ enum {
static gpointer parent_class;
+static void
+shell_window_update_title (EShellWindow *shell_window)
+{
+ EShellView *shell_view;
+ const gchar *view_title;
+ const gchar *view_name;
+ gchar *window_title;
+
+ view_name = e_shell_window_get_current_view (shell_window);
+ shell_view = e_shell_window_get_view (shell_window, view_name);
+ view_title = e_shell_view_get_title (shell_view);
+
+ if (!e_shell_view_is_selected (shell_view))
+ return;
+
+ /* Translators: This is used for the main window title. */
+ window_title = g_strdup_printf (_("%s - Evolution"), view_title);
+ gtk_window_set_title (GTK_WINDOW (shell_window), window_title);
+ g_free (window_title);
+}
+
static EShellView *
shell_window_new_view (EShellWindow *shell_window,
GType shell_view_type,
@@ -78,6 +99,10 @@ shell_window_new_view (EShellWindow *shell_window,
widget = e_shell_view_get_taskbar_widget (shell_view);
gtk_notebook_append_page (notebook, widget, NULL);
+ g_signal_connect_swapped (
+ shell_view, "notify::title",
+ G_CALLBACK (shell_window_update_title), shell_window);
+
return shell_view;
}
@@ -473,6 +498,7 @@ e_shell_window_set_current_view (EShellWindow *shell_window,
shell_window->priv->current_view = view_name;
g_object_notify (G_OBJECT (shell_window), "current-view");
+ shell_window_update_title (shell_window);
e_shell_window_update_gal_view_menu (shell_window);
/* Notify all loaded views. */