diff options
author | Juan R. Garcia Blanco <jgblanco.mail@gmail.com> | 2011-09-22 15:03:09 +0800 |
---|---|---|
committer | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2011-09-26 18:07:24 +0800 |
commit | 23ecdf691227368b7d914908aeaa6666fd46c890 (patch) | |
tree | f20977919226090684d393a379b11d3efd44fa36 /src/empathy-preferences.c | |
parent | 0a2d4299c996e583867d5028bc247ac86ace4b0b (diff) | |
download | gsoc2013-empathy-23ecdf691227368b7d914908aeaa6666fd46c890.tar gsoc2013-empathy-23ecdf691227368b7d914908aeaa6666fd46c890.tar.gz gsoc2013-empathy-23ecdf691227368b7d914908aeaa6666fd46c890.tar.bz2 gsoc2013-empathy-23ecdf691227368b7d914908aeaa6666fd46c890.tar.lz gsoc2013-empathy-23ecdf691227368b7d914908aeaa6666fd46c890.tar.xz gsoc2013-empathy-23ecdf691227368b7d914908aeaa6666fd46c890.tar.zst gsoc2013-empathy-23ecdf691227368b7d914908aeaa6666fd46c890.zip |
hide notifications options when in Shell
https://bugzilla.gnome.org/show_bug.cgi?id=659207
Diffstat (limited to 'src/empathy-preferences.c')
-rw-r--r-- | src/empathy-preferences.c | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/src/empathy-preferences.c b/src/empathy-preferences.c index 9dc7f58bf..e141aa201 100644 --- a/src/empathy-preferences.c +++ b/src/empathy-preferences.c @@ -1283,9 +1283,12 @@ empathy_preferences_tab_to_string (EmpathyPreferencesTab tab) } GtkWidget * -empathy_preferences_new (GtkWindow *parent) +empathy_preferences_new (GtkWindow *parent, + gboolean shell_running) { - GtkWidget *self; + GtkWidget *self; + EmpathyPreferencesPriv *priv; + GtkWidget *notif_page; g_return_val_if_fail (parent == NULL || GTK_IS_WINDOW (parent), NULL); @@ -1296,6 +1299,19 @@ empathy_preferences_new (GtkWindow *parent) parent); } + /* when running in Gnome Shell we must hide these options since they + * are meaningless in that context: + * - 'Display incoming events in the notification area' (General->Behavior) + * - 'Notifications' tab + */ + priv = GET_PRIV (self); + if (shell_running) { + gtk_widget_hide (priv->checkbutton_events_notif_area); + notif_page = gtk_notebook_get_nth_page (GTK_NOTEBOOK (priv->notebook), + EMPATHY_PREFERENCES_TAB_NOTIFICATIONS); + gtk_widget_hide (notif_page); + } + return self; } |