GNOME Bugzilla – Bug 641707
Set FileTransfer.URI
Last modified: 2011-08-29 10:12:43 UTC
In order to fix bug #640513 we should set the FileTransfer.URI property when requesting a file. We should also set it when accepting one so observer such as Zeitgeist can know when the file is being saved.
Created attachment 180279 [details] [review] http://git.collabora.co.uk/?p=user/cassidy/empathy;a=shortlog;h=refs/heads/ft-uri-641707 libempathy/empathy-ft-handler.c | 5 ++++ libempathy/empathy-tp-file.c | 49 +++++++++++++++++++++++++++++++-------- 2 files changed, 44 insertions(+), 10 deletions(-)
Note that this need the not yet relased Gabble 0.11.7 and Salut 0.5.0 to work properly (Butterfly has not be patched yet: https://bugs.freedesktop.org/show_bug.cgi?id=33843 ). But that's ok, if the CM doesn't implement the property just doesn't exist but we can still send and receive files.
Comment on attachment 180279 [details] [review] http://git.collabora.co.uk/?p=user/cassidy/empathy;a=shortlog;h=refs/heads/ft-uri-641707 Looks good. Just a couple of comments: >+ TP_PROP_CHANNEL_TYPE_FILE_TRANSFER_URI, G_TYPE_STRING, uri, You need to bump the minimum tp-glib requirement for this. >+ EmpathyTpFile *self = (EmpathyTpFile *) weak_object; >+ EmpathyTpFilePriv *priv = GET_PRIV (self); You can just do self->priv. Otherwise looks good.
(In reply to comment #3) > (From update of attachment 180279 [details] [review]) > Looks good. Just a couple of comments: > > >+ TP_PROP_CHANNEL_TYPE_FILE_TRANSFER_URI, G_TYPE_STRING, uri, > > You need to bump the minimum tp-glib requirement for this. Oh I thought we already depended on that but we didn't. done (I updated the wiki as well, jhbuild was already fine). > >+ EmpathyTpFile *self = (EmpathyTpFile *) weak_object; > >+ EmpathyTpFilePriv *priv = GET_PRIV (self); > > You can just do self->priv. Actually I cannot because EmpathyTpFile was using the old pattern. But we want to get rid of it so I updated to to use the new one. I also push a patch to use tp_clear_object().
ship it!
merged to master and gnome-2.33 This problem has been fixed in the development version. The fix will be available in the next major software release. Thank you for your bug report.