diff options
author | Emilio Pozuelo Monfort <emilio.pozuelo@collabora.co.uk> | 2011-03-16 21:35:28 +0800 |
---|---|---|
committer | Emilio Pozuelo Monfort <emilio.pozuelo@collabora.co.uk> | 2011-03-16 21:51:19 +0800 |
commit | c81fdc0417476ab122cd3d555095577269c3dd58 (patch) | |
tree | 7b2a4c46012d27554affc6162fd31afdd1ef77fb /libempathy-gtk/empathy-log-window.c | |
parent | 3245172e9de4d7eada65f0155c0d5039b3e7b0d6 (diff) | |
download | gsoc2013-empathy-c81fdc0417476ab122cd3d555095577269c3dd58.tar gsoc2013-empathy-c81fdc0417476ab122cd3d555095577269c3dd58.tar.gz gsoc2013-empathy-c81fdc0417476ab122cd3d555095577269c3dd58.tar.bz2 gsoc2013-empathy-c81fdc0417476ab122cd3d555095577269c3dd58.tar.lz gsoc2013-empathy-c81fdc0417476ab122cd3d555095577269c3dd58.tar.xz gsoc2013-empathy-c81fdc0417476ab122cd3d555095577269c3dd58.tar.zst gsoc2013-empathy-c81fdc0417476ab122cd3d555095577269c3dd58.zip |
Log window: grey out accounts without logs
Diffstat (limited to 'libempathy-gtk/empathy-log-window.c')
-rw-r--r-- | libempathy-gtk/empathy-log-window.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/libempathy-gtk/empathy-log-window.c b/libempathy-gtk/empathy-log-window.c index 5e1cc4b52..79e14d428 100644 --- a/libempathy-gtk/empathy-log-window.c +++ b/libempathy-gtk/empathy-log-window.c @@ -123,6 +123,12 @@ static void log_window_entry_chats_activate_cb (GtkWidget *en static void log_window_delete_menu_clicked_cb (GtkMenuItem *menuitem, EmpathyLogWindow *window); +static void +empathy_account_chooser_filter_has_logs (TpAccount *account, + EmpathyAccountChooserFilterResultCallback callback, + gpointer callback_data, + gpointer user_data); + enum { COL_FIND_ACCOUNT_ICON, COL_FIND_ACCOUNT_NAME, @@ -299,6 +305,7 @@ empathy_log_window_show (TpAccount *account, /* Account chooser for chats */ window->account_chooser_chats = empathy_account_chooser_new (); account_chooser = EMPATHY_ACCOUNT_CHOOSER (window->account_chooser_chats); + empathy_account_chooser_set_filter (account_chooser, empathy_account_chooser_filter_has_logs, NULL); gtk_box_pack_start (GTK_BOX (window->hbox_chats), window->account_chooser_chats, @@ -1438,6 +1445,10 @@ log_window_logger_clear_account_cb (TpProxy *proxy, * has been deleted */ empathy_chat_view_clear (window->chatview_chats); log_window_chats_populate (window); + + /* Re-filter the account chooser so the accounts without logs get greyed out */ + empathy_account_chooser_set_filter (EMPATHY_ACCOUNT_CHOOSER (window->account_chooser_chats), + empathy_account_chooser_filter_has_logs, NULL); } static void |