From 32ea1c129259b67d020944b3092a410f8b84908a Mon Sep 17 00:00:00 2001 From: Guillaume Desmottes Date: Tue, 6 Jul 2010 12:33:11 +0200 Subject: Make incoming file chooser dialog's title more informative This gives a bit more context when the dialog is displayed right away. --- libempathy-gtk/empathy-ui-utils.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'libempathy-gtk') diff --git a/libempathy-gtk/empathy-ui-utils.c b/libempathy-gtk/empathy-ui-utils.c index 6339a891d..ee48fa995 100644 --- a/libempathy-gtk/empathy-ui-utils.c +++ b/libempathy-gtk/empathy-ui-utils.c @@ -1670,8 +1670,16 @@ empathy_receive_file_with_file_chooser (EmpathyFTHandler *handler) { GtkWidget *widget; const gchar *dir; + EmpathyContact *contact; + gchar *title; - widget = gtk_file_chooser_dialog_new (_("Select a destination"), + contact = empathy_ft_handler_get_contact (handler); + g_assert (contact != NULL); + + title = g_strdup_printf (_("Incoming file from %s"), + empathy_contact_get_name (contact)); + + widget = gtk_file_chooser_dialog_new (title, NULL, GTK_FILE_CHOOSER_ACTION_SAVE, GTK_STOCK_CANCEL, @@ -1695,5 +1703,5 @@ empathy_receive_file_with_file_chooser (EmpathyFTHandler *handler) G_CALLBACK (file_manager_receive_file_response_cb), handler); gtk_widget_show (widget); + g_free (title); } - -- cgit v1.2.3