aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libempathy-gtk/empathy-ft-manager.c65
-rw-r--r--libempathy/empathy-file.c67
2 files changed, 87 insertions, 45 deletions
diff --git a/libempathy-gtk/empathy-ft-manager.c b/libempathy-gtk/empathy-ft-manager.c
index 31ec9392d..1fdb56ede 100644
--- a/libempathy-gtk/empathy-ft-manager.c
+++ b/libempathy-gtk/empathy-ft-manager.c
@@ -186,7 +186,8 @@ empathy_ft_manager_get_default (void)
* @ft.
*/
void
-empathy_ft_manager_add_file (EmpathyFTManager *ft_manager, EmpathyFile *file)
+empathy_ft_manager_add_file (EmpathyFTManager *ft_manager,
+ EmpathyFile *file)
{
EmpFileTransferState state;
@@ -243,7 +244,8 @@ format_interval (gint interval)
}
static GtkTreeRowReference *
-get_row_from_file (EmpathyFTManager *ft_manager, EmpathyFile *file)
+get_row_from_file (EmpathyFTManager *ft_manager,
+ EmpathyFile *file)
{
EmpathyFTManagerPriv *priv;
@@ -322,7 +324,8 @@ get_state_change_reason_description (EmpFileTransferStateChangeReason reason)
}
static void
-update_ft_row (EmpathyFTManager *ft_manager, EmpathyFile *file)
+update_ft_row (EmpathyFTManager *ft_manager,
+ EmpathyFile *file)
{
EmpathyFTManagerPriv *priv;
GtkTreeRowReference *row_ref;
@@ -488,15 +491,17 @@ update_ft_row (EmpathyFTManager *ft_manager, EmpathyFile *file)
}
static void
-transferred_bytes_changed_cb (EmpathyFile *file, GParamSpec *pspec,
- EmpathyFTManager *ft_manager)
+transferred_bytes_changed_cb (EmpathyFile *file,
+ GParamSpec *pspec,
+ EmpathyFTManager *ft_manager)
{
update_ft_row (ft_manager, file);
}
static void
-state_changed_cb (EmpathyFile *file, GParamSpec *pspec,
- EmpathyFTManager *ft_manager)
+state_changed_cb (EmpathyFile *file,
+ GParamSpec *pspec,
+ EmpathyFTManager *ft_manager)
{
EmpathyFTManagerPriv *priv;
gboolean remove;
@@ -537,7 +542,8 @@ state_changed_cb (EmpathyFile *file, GParamSpec *pspec,
}
static void
-ft_manager_add_file_to_list (EmpathyFTManager *ft_manager, EmpathyFile *file)
+ft_manager_add_file_to_list (EmpathyFTManager *ft_manager,
+ EmpathyFile *file)
{
EmpathyFTManagerPriv *priv;
GtkTreeRowReference *row_ref;
@@ -607,14 +613,18 @@ ft_manager_add_file_to_list (EmpathyFTManager *ft_manager, EmpathyFile *file)
}
static void
-selection_changed (GtkTreeSelection *selection, EmpathyFTManager *ft_manager)
+selection_changed (GtkTreeSelection *selection,
+ EmpathyFTManager *ft_manager)
{
update_buttons (ft_manager);
}
static void
-progress_cell_data_func (GtkTreeViewColumn *col, GtkCellRenderer *renderer,
- GtkTreeModel *model, GtkTreeIter *iter, gpointer user_data)
+progress_cell_data_func (GtkTreeViewColumn *col,
+ GtkCellRenderer *renderer,
+ GtkTreeModel *model,
+ GtkTreeIter *iter,
+ gpointer user_data)
{
const gchar *text = NULL;
gint percent;
@@ -634,7 +644,9 @@ progress_cell_data_func (GtkTreeViewColumn *col, GtkCellRenderer *renderer,
}
static void
-ft_manager_clear_foreach_cb (gpointer key, gpointer value, gpointer user_data)
+ft_manager_clear_foreach_cb (gpointer key,
+ gpointer value,
+ gpointer user_data)
{
GSList **list = user_data;
EmpathyFile *file = key;
@@ -673,8 +685,9 @@ ft_manager_clear (EmpathyFTManager *ft_manager)
}
static gboolean
-ft_manager_delete_event_cb (GtkWidget *widget, GdkEvent *event,
- EmpathyFTManager *ft_manager)
+ft_manager_delete_event_cb (GtkWidget *widget,
+ GdkEvent *event,
+ EmpathyFTManager *ft_manager)
{
EmpathyFTManagerPriv *priv;
@@ -715,8 +728,9 @@ ft_manager_save_geometry_timeout_cb (EmpathyFTManager *ft_manager)
}
static gboolean
-ft_manager_configure_event_cb (GtkWidget *widget, GdkEventConfigure *event,
- EmpathyFTManager *ft_manager)
+ft_manager_configure_event_cb (GtkWidget *widget,
+ GdkEventConfigure *event,
+ EmpathyFTManager *ft_manager)
{
EmpathyFTManagerPriv *priv;
@@ -854,7 +868,7 @@ ft_manager_build_ui (EmpathyFTManager *ft_manager)
static void
ft_manager_remove_file_from_list (EmpathyFTManager *ft_manager,
- EmpathyFile *file)
+ EmpathyFile *file)
{
EmpathyFTManagerPriv *priv;
GtkTreeRowReference *row_ref;
@@ -977,8 +991,9 @@ ft_manager_stop (EmpathyFTManager *ft_manager)
}
static void
-ft_manager_response_cb (GtkWidget *dialog, gint response,
- EmpathyFTManager *ft_manager)
+ft_manager_response_cb (GtkWidget *dialog,
+ gint response,
+ EmpathyFTManager *ft_manager)
{
switch (response)
{
@@ -1015,8 +1030,9 @@ free_receive_response_data (ReceiveResponseData *response_data)
}
static void
-ft_manager_save_dialog_response_cb (GtkDialog *widget, gint response_id,
- ReceiveResponseData *response_data)
+ft_manager_save_dialog_response_cb (GtkDialog *widget,
+ gint response_id,
+ ReceiveResponseData *response_data)
{
if (response_id == GTK_RESPONSE_OK)
{
@@ -1127,8 +1143,9 @@ ft_manager_create_save_dialog (ReceiveResponseData *response_data)
}
static void
-ft_manager_receive_file_response_cb (GtkWidget *dialog, gint response,
- ReceiveResponseData *response_data)
+ft_manager_receive_file_response_cb (GtkWidget *dialog,
+ gint response,
+ ReceiveResponseData *response_data)
{
TpChannel *channel;
@@ -1146,7 +1163,7 @@ ft_manager_receive_file_response_cb (GtkWidget *dialog, gint response,
void
ft_manager_display_accept_dialog (EmpathyFTManager *ft_manager,
- EmpathyFile *file)
+ EmpathyFile *file)
{
GtkWidget *dialog;
GtkWidget *image;
diff --git a/libempathy/empathy-file.c b/libempathy/empathy-file.c
index b45fbff10..80f19f6a0 100644
--- a/libempathy/empathy-file.c
+++ b/libempathy/empathy-file.c
@@ -297,7 +297,9 @@ file_finalize (GObject *object)
}
static GObject *
-file_constructor (GType type, guint n_props, GObjectConstructParam *props)
+file_constructor (GType type,
+ guint n_props,
+ GObjectConstructParam *props)
{
GObject *file;
EmpathyFilePriv *priv;
@@ -379,8 +381,10 @@ file_constructor (GType type, guint n_props, GObjectConstructParam *props)
}
static void
-file_get_property (GObject *object, guint param_id, GValue *value,
- GParamSpec *pspec)
+file_get_property (GObject *object,
+ guint param_id,
+ GValue *value,
+ GParamSpec *pspec)
{
EmpathyFilePriv *priv;
EmpathyFile *file;
@@ -403,8 +407,9 @@ file_get_property (GObject *object, guint param_id, GValue *value,
}
static void
-file_channel_set_dbus_property (gpointer proxy, const gchar *property,
- const GValue *value)
+file_channel_set_dbus_property (gpointer proxy,
+ const gchar *property,
+ const GValue *value)
{
DEBUG ("Setting %s property", property);
tp_cli_dbus_properties_run_set (TP_PROXY (proxy),
@@ -418,8 +423,10 @@ file_channel_set_dbus_property (gpointer proxy, const gchar *property,
static void
-file_set_property (GObject *object, guint param_id, const GValue *value,
- GParamSpec *pspec)
+file_set_property (GObject *object,
+ guint param_id,
+ const GValue *value,
+ GParamSpec *pspec)
{
EmpathyFilePriv *priv;
@@ -479,7 +486,8 @@ file_set_property (GObject *object, guint param_id, const GValue *value,
* Returns: a new #EmpathyFile
*/
EmpathyFile *
-empathy_file_new (McAccount *account, TpChannel *channel)
+empathy_file_new (McAccount *account,
+ TpChannel *channel)
{
return g_object_new (EMPATHY_TYPE_FILE,
"account", account,
@@ -528,7 +536,8 @@ empathy_file_get_channel (EmpathyFile *file)
}
static void
-file_destroy_cb (TpChannel *file_channel, EmpathyFile *file)
+file_destroy_cb (TpChannel *file_channel,
+ EmpathyFile *file)
{
EmpathyFilePriv *priv;
@@ -541,7 +550,9 @@ file_destroy_cb (TpChannel *file_channel, EmpathyFile *file)
}
static void
-file_closed_cb (TpChannel *file_channel, EmpathyFile *file, GObject *weak_object)
+file_closed_cb (TpChannel *file_channel,
+ EmpathyFile *file,
+ GObject *weak_object)
{
EmpathyFilePriv *priv;
@@ -710,8 +721,10 @@ send_file (EmpathyFile *file)
}
static void
-file_state_changed_cb (DBusGProxy *file_iface, EmpFileTransferState state,
- EmpFileTransferStateChangeReason reason, EmpathyFile *file)
+file_state_changed_cb (DBusGProxy *file_iface,
+ EmpFileTransferState state,
+ EmpFileTransferStateChangeReason reason,
+ EmpathyFile *file)
{
EmpathyFilePriv *priv;
@@ -746,7 +759,9 @@ file_state_changed_cb (DBusGProxy *file_iface, EmpFileTransferState state,
static void
file_transferred_bytes_changed_cb (TpProxy *proxy,
- guint64 count, EmpathyFile *file, GObject *weak_object)
+ guint64 count,
+ EmpathyFile *file,
+ GObject *weak_object)
{
EmpathyFilePriv *priv;
@@ -891,7 +906,7 @@ empathy_file_cancel (EmpathyFile *file)
void
empathy_file_set_input_stream (EmpathyFile *file,
- GInputStream *in_stream)
+ GInputStream *in_stream)
{
EmpathyFilePriv *priv;
@@ -916,7 +931,8 @@ empathy_file_set_input_stream (EmpathyFile *file,
}
void
-empathy_file_set_output_stream (EmpathyFile *file, GOutputStream *out_stream)
+empathy_file_set_output_stream (EmpathyFile *file,
+ GOutputStream *out_stream)
{
EmpathyFilePriv *priv;
@@ -940,7 +956,7 @@ empathy_file_set_output_stream (EmpathyFile *file, GOutputStream *out_stream)
void
empathy_file_set_filename (EmpathyFile *file,
- const gchar *filename)
+ const gchar *filename)
{
EmpathyFilePriv *priv;
@@ -1003,7 +1019,8 @@ free_copy_data_if_closed (CopyData *copy)
}
static void
-io_error (CopyData *copy, GError *error)
+io_error (CopyData *copy,
+ GError *error)
{
g_cancellable_cancel (copy->cancellable);
@@ -1024,7 +1041,9 @@ io_error (CopyData *copy, GError *error)
}
static void
-close_done (GObject *source_object, GAsyncResult *res, gpointer user_data)
+close_done (GObject *source_object,
+ GAsyncResult *res,
+ gpointer user_data)
{
CopyData *copy = user_data;
@@ -1033,7 +1052,9 @@ close_done (GObject *source_object, GAsyncResult *res, gpointer user_data)
}
static void
-write_done_cb (GObject *source_object, GAsyncResult *res, gpointer user_data)
+write_done_cb (GObject *source_object,
+ GAsyncResult *res,
+ gpointer user_data)
{
CopyData *copy = user_data;
gssize count_write;
@@ -1056,7 +1077,9 @@ write_done_cb (GObject *source_object, GAsyncResult *res, gpointer user_data)
}
static void
-read_done_cb (GObject *source_object, GAsyncResult *res, gpointer user_data)
+read_done_cb (GObject *source_object,
+ GAsyncResult *res,
+ gpointer user_data)
{
CopyData *copy = user_data;
gssize count_read;
@@ -1129,7 +1152,9 @@ schedule_next (CopyData *copy)
}
static void
-copy_stream (GInputStream *in, GOutputStream *out, GCancellable *cancellable)
+copy_stream (GInputStream *in,
+ GOutputStream *out,
+ GCancellable *cancellable)
{
CopyData *copy;
gint i;