aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy/empathy-ft-handler.c
diff options
context:
space:
mode:
authorCosimo Cecchi <cosimoc@gnome.org>2009-05-13 23:35:25 +0800
committerCosimo Cecchi <cosimoc@gnome.org>2009-06-01 23:49:56 +0800
commitcecbf767e3364d3342aef9b73206d4e29c692953 (patch)
tree726f46de215c100caf269d827d520099f0107ad9 /libempathy/empathy-ft-handler.c
parent1cde27a07305bc03e8f7d6d676a24e9ccda8e566 (diff)
downloadgsoc2013-empathy-cecbf767e3364d3342aef9b73206d4e29c692953.tar
gsoc2013-empathy-cecbf767e3364d3342aef9b73206d4e29c692953.tar.gz
gsoc2013-empathy-cecbf767e3364d3342aef9b73206d4e29c692953.tar.bz2
gsoc2013-empathy-cecbf767e3364d3342aef9b73206d4e29c692953.tar.lz
gsoc2013-empathy-cecbf767e3364d3342aef9b73206d4e29c692953.tar.xz
gsoc2013-empathy-cecbf767e3364d3342aef9b73206d4e29c692953.tar.zst
gsoc2013-empathy-cecbf767e3364d3342aef9b73206d4e29c692953.zip
Add empathy_ft_handler_get_use_hash
This is needed, as the GConf property might change during the transfer.
Diffstat (limited to 'libempathy/empathy-ft-handler.c')
-rw-r--r--libempathy/empathy-ft-handler.c20
1 files changed, 19 insertions, 1 deletions
diff --git a/libempathy/empathy-ft-handler.c b/libempathy/empathy-ft-handler.c
index a41909570..be1c1a098 100644
--- a/libempathy/empathy-ft-handler.c
+++ b/libempathy/empathy-ft-handler.c
@@ -392,7 +392,7 @@ check_hash_incoming (EmpathyFTHandler *handler)
HashingData *hash_data;
EmpathyFTHandlerPriv *priv = GET_PRIV (handler);
- if (priv->content_hash != NULL)
+ if (!EMP_STR_EMPTY (priv->content_hash))
{
hash_data = g_slice_new0 (HashingData);
hash_data->total_bytes = priv->total_bytes;
@@ -996,6 +996,9 @@ empathy_ft_handler_new_outgoing (EmpathyContact *contact,
CallbacksData *data;
EmpathyFTHandlerPriv *priv;
+ DEBUG ("New handler outgoing, use hash %s",
+ use_hash ? "True" : "False");
+
g_return_if_fail (EMPATHY_IS_CONTACT (contact));
g_return_if_fail (G_IS_FILE (source));
@@ -1090,6 +1093,9 @@ empathy_ft_handler_incoming_set_destination (EmpathyFTHandler *handler,
GFile *destination,
gboolean use_hash)
{
+ DEBUG ("Set incoming destination, use hash %s",
+ use_hash ? "True" : "False");
+
g_return_if_fail (EMPATHY_IS_FT_HANDLER (handler));
g_return_if_fail (G_IS_FILE (destination));
@@ -1146,6 +1152,18 @@ empathy_ft_handler_get_gfile (EmpathyFTHandler *handler)
}
gboolean
+empathy_ft_handler_get_use_hash (EmpathyFTHandler *handler)
+{
+ EmpathyFTHandlerPriv *priv;
+
+ g_return_val_if_fail (EMPATHY_IS_FT_HANDLER (handler), FALSE);
+
+ priv = GET_PRIV (handler);
+
+ return priv->use_hash;
+}
+
+gboolean
empathy_ft_handler_is_incoming (EmpathyFTHandler *handler)
{
EmpathyFTHandlerPriv *priv;