aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy-gtk
diff options
context:
space:
mode:
authorJonny Lamb <jonny.lamb@collabora.co.uk>2008-11-22 00:20:08 +0800
committerXavier Claessens <xclaesse@src.gnome.org>2008-11-22 00:20:08 +0800
commit1bfcaed673317c3ea7e34903ad224e28a7a6a5ed (patch)
tree9e08776c82fc51232768e8c136cf20688e2b3c26 /libempathy-gtk
parentf16740fbe979cf1c99c327befc01e97db54ae26e (diff)
downloadgsoc2013-empathy-1bfcaed673317c3ea7e34903ad224e28a7a6a5ed.tar
gsoc2013-empathy-1bfcaed673317c3ea7e34903ad224e28a7a6a5ed.tar.gz
gsoc2013-empathy-1bfcaed673317c3ea7e34903ad224e28a7a6a5ed.tar.bz2
gsoc2013-empathy-1bfcaed673317c3ea7e34903ad224e28a7a6a5ed.tar.lz
gsoc2013-empathy-1bfcaed673317c3ea7e34903ad224e28a7a6a5ed.tar.xz
gsoc2013-empathy-1bfcaed673317c3ea7e34903ad224e28a7a6a5ed.tar.zst
gsoc2013-empathy-1bfcaed673317c3ea7e34903ad224e28a7a6a5ed.zip
Don't expose streams in EmpathyTpFile, but use the GFile. (Jonny Lamb)
Signed-off-by: Jonny Lamb <jonny.lamb@collabora.co.uk> svn path=/trunk/; revision=1837
Diffstat (limited to 'libempathy-gtk')
-rw-r--r--libempathy-gtk/empathy-ft-manager.c13
1 files changed, 1 insertions, 12 deletions
diff --git a/libempathy-gtk/empathy-ft-manager.c b/libempathy-gtk/empathy-ft-manager.c
index 5814d14fe..53b69fb48 100644
--- a/libempathy-gtk/empathy-ft-manager.c
+++ b/libempathy-gtk/empathy-ft-manager.c
@@ -764,13 +764,10 @@ ft_manager_save_dialog_response_cb (GtkDialog *widget,
if (uri)
{
GFile *file;
- GOutputStream *out_stream;
- gchar *filename;
GError *error = NULL;
file = g_file_new_for_uri (uri);
- out_stream = G_OUTPUT_STREAM (g_file_replace (file, NULL,
- FALSE, 0, NULL, &error));
+ empathy_tp_file_set_gfile (response_data->tp_file, file, &error);
if (error)
{
@@ -780,23 +777,15 @@ ft_manager_save_dialog_response_cb (GtkDialog *widget,
return;
}
- empathy_tp_file_set_output_stream (response_data->tp_file, out_stream);
-
g_object_set_data_full (G_OBJECT (response_data->tp_file),
"uri", uri, g_free);
- filename = g_file_get_basename (file);
- empathy_tp_file_set_filename (response_data->tp_file, filename);
-
empathy_tp_file_accept (response_data->tp_file, 0);
ft_manager_add_tp_file_to_list (response_data->ft_manager,
response_data->tp_file);
- g_free (filename);
g_object_unref (file);
- if (out_stream)
- g_object_unref (out_stream);
}
folder = gtk_file_chooser_get_current_folder (GTK_FILE_CHOOSER (widget));