diff options
author | Cosimo Cecchi <cosimo.cecchi@collabora.co.uk> | 2009-02-05 22:16:41 +0800 |
---|---|---|
committer | Cosimo Cecchi <cosimoc@gnome.org> | 2009-06-01 23:46:04 +0800 |
commit | 0390c52061551390ea77877700c18e7ae57afc08 (patch) | |
tree | a3278ad97153fee0d12b7892d65458d620c815ba | |
parent | 606bffede10826c02b8e5f14d161701720e94e70 (diff) | |
download | gsoc2013-empathy-0390c52061551390ea77877700c18e7ae57afc08.tar gsoc2013-empathy-0390c52061551390ea77877700c18e7ae57afc08.tar.gz gsoc2013-empathy-0390c52061551390ea77877700c18e7ae57afc08.tar.bz2 gsoc2013-empathy-0390c52061551390ea77877700c18e7ae57afc08.tar.lz gsoc2013-empathy-0390c52061551390ea77877700c18e7ae57afc08.tar.xz gsoc2013-empathy-0390c52061551390ea77877700c18e7ae57afc08.tar.zst gsoc2013-empathy-0390c52061551390ea77877700c18e7ae57afc08.zip |
Set more meaningful names for EmpathyFTHandler public methods.
-rw-r--r-- | libempathy/empathy-ft-handler.c | 15 | ||||
-rw-r--r-- | libempathy/empathy-ft-handler.h | 7 |
2 files changed, 13 insertions, 9 deletions
diff --git a/libempathy/empathy-ft-handler.c b/libempathy/empathy-ft-handler.c index bc5490a0e..292df0dbf 100644 --- a/libempathy/empathy-ft-handler.c +++ b/libempathy/empathy-ft-handler.c @@ -593,23 +593,24 @@ ft_handler_contact_ready_cb (EmpathyContact *contact, /* public methods */ EmpathyFTHandler* -empathy_ft_handler_new (EmpathyContact *contact, - GFile *file) +empathy_ft_handler_new_outgoing (EmpathyContact *contact, + GFile *source) { g_return_val_if_fail (EMPATHY_IS_CONTACT (contact), NULL); g_return_val_if_fail (G_IS_FILE (file), NULL); return g_object_new (EMPATHY_TYPE_FT_HANDLER, - "contact", contact, "gfile", file, NULL); + "contact", contact, "gfile", source, NULL); } EmpathyFTHandler * -empathy_ft_handler_new_for_channel (EmpathyTpFile *file) +empathy_ft_handler_new_incoming (EmpathyTpFile *tp_file, + GFile *destination) { g_return_val_if_fail (EMPATHY_IS_TP_FILE (file), NULL); return g_object_new (EMPATHY_TYPE_FT_HANDLER, - "tp-file", file, NULL); + "tp-file", tp_file, "gfile", destination, NULL); } void @@ -617,6 +618,7 @@ empathy_ft_handler_start_transfer (EmpathyFTHandler *handler) { RequestData *data; EmpathyFTHandlerPriv *priv; + GError *error = NULL; g_return_if_fail (EMPATHY_IS_FT_HANDLER (handler)); @@ -631,6 +633,7 @@ empathy_ft_handler_start_transfer (EmpathyFTHandler *handler) } else { - /* TODO: */ + /* TODO: add support for resume. */ + empathy_tp_file_accept (priv->tpfile, 0, priv->gfile, &error); } } diff --git a/libempathy/empathy-ft-handler.h b/libempathy/empathy-ft-handler.h index a76db1014..57dcc0c89 100644 --- a/libempathy/empathy-ft-handler.h +++ b/libempathy/empathy-ft-handler.h @@ -56,9 +56,10 @@ typedef struct { GType empathy_ft_handler_get_type (void); /* public methods */ -EmpathyFTHandler * empathy_ft_handler_new (EmpathyContact *contact, - GFile *file); -EmpathyFTHandler * empathy_ft_handler_new_for_channel (EmpathyTpFile *file); +EmpathyFTHandler * empathy_ft_handler_new_outgoing (EmpathyContact *contact, + GFile *source); +EmpathyFTHandler * empathy_ft_handler_new_incoming (EmpathyTpFile *tp_file, + GFile *destination); void empathy_ft_handler_start_transfer (EmpathyFTHandler *handler); G_END_DECLS |