]> git.0d.be Git - empathy.git/commitdiff
Make incoming file chooser dialog's title more informative
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>
Tue, 6 Jul 2010 10:33:11 +0000 (12:33 +0200)
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>
Wed, 7 Jul 2010 08:45:04 +0000 (10:45 +0200)
This gives a bit more context when the dialog is displayed right away.

libempathy-gtk/empathy-ui-utils.c

index 6339a891dac9aaacd37ad7caabaa4294df213aa8..ee48fa995fe6704e91e950d32157517aa59b3a68 100644 (file)
@@ -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);
 }
-