diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2015-04-03 13:14:53 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2015-04-03 13:14:53 +0200 |
commit | c43dfb815a4951b8248f4f0e98babe4f80204f03 (patch) | |
tree | 82745ed2353757c41ea1865bad9ac7a1b0a8a366 /plugins/shotwell-publishing/FacebookPublishing.vala | |
parent | 2785a691b958a79a1dd606c445188c71c3f58b3c (diff) |
Imported Upstream version 0.22.0upstream/0.22.0
Diffstat (limited to 'plugins/shotwell-publishing/FacebookPublishing.vala')
-rw-r--r-- | plugins/shotwell-publishing/FacebookPublishing.vala | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/plugins/shotwell-publishing/FacebookPublishing.vala b/plugins/shotwell-publishing/FacebookPublishing.vala index 79b7a0a..1dd793d 100644 --- a/plugins/shotwell-publishing/FacebookPublishing.vala +++ b/plugins/shotwell-publishing/FacebookPublishing.vala @@ -1,4 +1,4 @@ -/* Copyright 2009-2014 Yorba Foundation +/* Copyright 2009-2015 Yorba Foundation * * This software is licensed under the GNU Lesser General Public License * (version 2.1 or later). See the COPYING file in this distribution. @@ -29,7 +29,7 @@ public class FacebookService : Object, Spit.Pluggable, Spit.Publishing.Service { public void get_info(ref Spit.PluggableInfo info) { info.authors = "Lucas Beeler"; - info.copyright = _("Copyright 2009-2014 Yorba Foundation"); + info.copyright = _("Copyright 2009-2015 Yorba Foundation"); info.translators = Resources.TRANSLATORS; info.version = _VERSION; info.website_name = Resources.WEBSITE_NAME; @@ -1393,9 +1393,19 @@ internal class GraphSession { if (publishable.get_media_type() == Spit.Publishing.Publisher.MediaType.VIDEO) mp_envelope.append_form_string("privacy", resource_privacy); - string publishable_title = publishable.get_publishing_name(); - if (!suppress_titling && publishable_title != "") + //Get photo title and post it as message on FB API + string publishable_title = publishable.get_param_string("title"); + if (!suppress_titling && publishable_title != null) mp_envelope.append_form_string("name", publishable_title); + + //Set 'message' data field with EXIF comment field. Title has precedence. + string publishable_comment = publishable.get_param_string("comment"); + if (!suppress_titling && publishable_comment != null) + mp_envelope.append_form_string("message", publishable_comment); + + //Sets correct date of the picture + if (!suppress_titling) + mp_envelope.append_form_string("backdated_time", publishable.get_exposure_date_time().to_string()); string source_file_mime_type = (publishable.get_media_type() == Spit.Publishing.Publisher.MediaType.VIDEO) ? |