aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy-gtk
diff options
context:
space:
mode:
authorCosimo Cecchi <cosimoc@gnome.org>2009-05-06 21:04:12 +0800
committerCosimo Cecchi <cosimoc@gnome.org>2009-06-01 23:49:55 +0800
commitd3fc1349507da7d0bb6538a8e66fa3116bb6eec9 (patch)
tree1cb8c7bacef70eeb27e7bb21608f08fb6d37b5e1 /libempathy-gtk
parent6a0da1dbef905ec7bf93e6d1c0eca6c6b8dfdb4a (diff)
downloadgsoc2013-empathy-d3fc1349507da7d0bb6538a8e66fa3116bb6eec9.tar
gsoc2013-empathy-d3fc1349507da7d0bb6538a8e66fa3116bb6eec9.tar.gz
gsoc2013-empathy-d3fc1349507da7d0bb6538a8e66fa3116bb6eec9.tar.bz2
gsoc2013-empathy-d3fc1349507da7d0bb6538a8e66fa3116bb6eec9.tar.lz
gsoc2013-empathy-d3fc1349507da7d0bb6538a8e66fa3116bb6eec9.tar.xz
gsoc2013-empathy-d3fc1349507da7d0bb6538a8e66fa3116bb6eec9.tar.zst
gsoc2013-empathy-d3fc1349507da7d0bb6538a8e66fa3116bb6eec9.zip
Add a new preference in the UI
Diffstat (limited to 'libempathy-gtk')
-rw-r--r--libempathy-gtk/empathy-conf.h1
-rw-r--r--libempathy-gtk/empathy-ui-utils.c9
2 files changed, 9 insertions, 1 deletions
diff --git a/libempathy-gtk/empathy-conf.h b/libempathy-gtk/empathy-conf.h
index 07026df5c..d650f4224 100644
--- a/libempathy-gtk/empathy-conf.h
+++ b/libempathy-gtk/empathy-conf.h
@@ -82,6 +82,7 @@ struct _EmpathyConfClass {
#define EMPATHY_PREFS_LOCATION_RESOURCE_CELL EMPATHY_PREFS_PATH "/location/resource_cell"
#define EMPATHY_PREFS_LOCATION_RESOURCE_GPS EMPATHY_PREFS_PATH "/location/resource_gps"
#define EMPATHY_PREFS_LOCATION_REDUCE_ACCURACY EMPATHY_PREFS_PATH "/location/reduce_accuracy"
+#define EMPATHY_PREFS_FILE_TRANSFER_USE_HASH EMPATHY_PREFS_PATH "/file_transfer/use_hash"
typedef void (*EmpathyConfNotifyFunc) (EmpathyConf *conf,
const gchar *key,
diff --git a/libempathy-gtk/empathy-ui-utils.c b/libempathy-gtk/empathy-ui-utils.c
index f7c8149eb..3ea3e76aa 100644
--- a/libempathy-gtk/empathy-ui-utils.c
+++ b/libempathy-gtk/empathy-ui-utils.c
@@ -1411,14 +1411,21 @@ file_manager_send_file_response_cb (GtkDialog *widget,
GFile *file;
gchar *uri;
GtkRecentManager *manager;
+ gboolean use_hash;
if (response_id == GTK_RESPONSE_OK) {
file = gtk_file_chooser_get_file (GTK_FILE_CHOOSER (widget));
uri = g_file_get_uri (file);
+ use_hash = empathy_conf_get_bool
+ (empathy_conf_get (),
+ EMPATHY_PREFS_FILE_TRANSFER_USE_HASH,
+ &use_hash);
+
factory = empathy_ft_factory_dup_singleton ();
- empathy_ft_factory_new_transfer_outgoing (factory, contact, file);
+ empathy_ft_factory_new_transfer_outgoing (factory, contact,
+ file, use_hash);
manager = gtk_recent_manager_get_default ();
gtk_recent_manager_add_item (manager, uri);