diff options
author | Cosimo Cecchi <cosimo.cecchi@collabora.co.uk> | 2009-11-13 23:15:17 +0800 |
---|---|---|
committer | Guillaume Desmottes <guillaume.desmottes@collabora.co.uk> | 2009-11-13 23:59:22 +0800 |
commit | d7e43c8e57ef7e164b77823983acb16bb2026672 (patch) | |
tree | 5e2a9254a03a0c116f3db88da383d9873d78e909 | |
parent | 77cd05e44a390273974fbb53266b0173a9ac7368 (diff) | |
download | gsoc2013-empathy-d7e43c8e57ef7e164b77823983acb16bb2026672.tar gsoc2013-empathy-d7e43c8e57ef7e164b77823983acb16bb2026672.tar.gz gsoc2013-empathy-d7e43c8e57ef7e164b77823983acb16bb2026672.tar.bz2 gsoc2013-empathy-d7e43c8e57ef7e164b77823983acb16bb2026672.tar.lz gsoc2013-empathy-d7e43c8e57ef7e164b77823983acb16bb2026672.tar.xz gsoc2013-empathy-d7e43c8e57ef7e164b77823983acb16bb2026672.tar.zst gsoc2013-empathy-d7e43c8e57ef7e164b77823983acb16bb2026672.zip |
Respect indentation style.
-rw-r--r-- | libempathy-gtk/empathy-chat.c | 28 | ||||
-rw-r--r-- | libempathy/empathy-tp-chat.c | 32 | ||||
-rw-r--r-- | libempathy/empathy-tp-chat.h | 16 |
3 files changed, 39 insertions, 37 deletions
diff --git a/libempathy-gtk/empathy-chat.c b/libempathy-gtk/empathy-chat.c index dc332c6d9..62b3d437b 100644 --- a/libempathy-gtk/empathy-chat.c +++ b/libempathy-gtk/empathy-chat.c @@ -2314,19 +2314,19 @@ empathy_chat_get_tp_chat (EmpathyChat *chat) } static void display_password_info_bar (EmpathyChat *self, - gboolean retry); + gboolean retry); static void provide_password_cb (GObject *tp_chat, - GAsyncResult *res, - gpointer user_data) + GAsyncResult *res, + gpointer user_data) { EmpathyChat *self = EMPATHY_CHAT (user_data); EmpathyChatPriv *priv = GET_PRIV (self); GError *error = NULL; if (!empathy_tp_chat_provide_password_finish (EMPATHY_TP_CHAT (tp_chat), res, - &error)) { + &error)) { DEBUG ("error: %s", error->message); /* FIXME: what should we do if that's another error? Close the channel? * Display the raw D-Bus error to the user isn't very useful */ @@ -2343,8 +2343,8 @@ provide_password_cb (GObject *tp_chat, static void password_infobar_response_cb (GtkWidget *info_bar, - gint response_id, - EmpathyChat *self) + gint response_id, + EmpathyChat *self) { EmpathyChatPriv *priv = GET_PRIV (self); GtkWidget *entry; @@ -2359,9 +2359,9 @@ password_infobar_response_cb (GtkWidget *info_bar, password = gtk_entry_get_text (GTK_ENTRY (entry)); empathy_tp_chat_provide_password_async (priv->tp_chat, password, - provide_password_cb, self); + provide_password_cb, self); -out: + out: gtk_widget_destroy (info_bar); } @@ -2381,7 +2381,7 @@ passwd_join_button_cb (GtkButton *button, static void display_password_info_bar (EmpathyChat *self, - gboolean retry) + gboolean retry) { EmpathyChatPriv *priv = GET_PRIV (self); GtkWidget *info_bar; @@ -2418,7 +2418,7 @@ display_password_info_bar (EmpathyChat *self, /* Add image */ image = gtk_image_new_from_stock (GTK_STOCK_DIALOG_AUTHENTICATION, - GTK_ICON_SIZE_DIALOG); + GTK_ICON_SIZE_DIALOG); gtk_box_pack_start (GTK_BOX (hbox), image, FALSE, FALSE, 0); /* Add message */ @@ -2431,7 +2431,7 @@ display_password_info_bar (EmpathyChat *self, gtk_box_pack_start (GTK_BOX (hbox), entry, TRUE, TRUE, 0); g_signal_connect (entry, "activate", - G_CALLBACK (password_entry_activate_cb), info_bar); + G_CALLBACK (password_entry_activate_cb), info_bar); /* Focus the password entry once it's realized */ g_signal_connect (entry, "realize", G_CALLBACK (gtk_widget_grab_focus), NULL); @@ -2444,16 +2444,16 @@ display_password_info_bar (EmpathyChat *self, gtk_box_pack_start (GTK_BOX (hbox), alig, FALSE, FALSE, 0); g_signal_connect (button, "clicked", G_CALLBACK (passwd_join_button_cb), - info_bar); + info_bar); g_object_set_data (G_OBJECT (info_bar), "password-entry", entry); gtk_box_pack_start (GTK_BOX (priv->info_bar_vbox), info_bar, - FALSE, FALSE, 3); + FALSE, FALSE, 3); gtk_widget_show_all (hbox); g_signal_connect (info_bar, "response", - G_CALLBACK (password_infobar_response_cb), self); + G_CALLBACK (password_infobar_response_cb), self); gtk_widget_show_all (info_bar); } diff --git a/libempathy/empathy-tp-chat.c b/libempathy/empathy-tp-chat.c index 9a235b70e..928520631 100644 --- a/libempathy/empathy-tp-chat.c +++ b/libempathy/empathy-tp-chat.c @@ -795,7 +795,7 @@ tp_chat_check_if_ready (EmpathyTpChat *chat) * If the chat is protected by a password we can't get these information so * consider the chat as ready so it can be presented to the user. */ if (!empathy_tp_chat_password_needed (chat) && priv->members == NULL && - priv->remote_contact == NULL) + priv->remote_contact == NULL) return; DEBUG ("Ready!"); @@ -1159,12 +1159,12 @@ tp_chat_constructor (GType type, TP_IFACE_QUARK_CHANNEL_INTERFACE_PASSWORD)) { priv->got_password_flags = FALSE; - tp_cli_channel_interface_password_connect_to_password_flags_changed ( - priv->channel, password_flags_changed_cb, chat, NULL, - G_OBJECT (chat), NULL); + tp_cli_channel_interface_password_connect_to_password_flags_changed + (priv->channel, password_flags_changed_cb, chat, NULL, + G_OBJECT (chat), NULL); - tp_cli_channel_interface_password_call_get_password_flags (priv->channel, - -1, got_password_flags_cb, chat, NULL, chat); + tp_cli_channel_interface_password_call_get_password_flags + (priv->channel, -1, got_password_flags_cb, chat, NULL, chat); } else { /* No Password interface, so no need to fetch the password flags */ priv->got_password_flags = TRUE; @@ -1572,13 +1572,13 @@ provide_password_cb (TpChannel *channel, GSimpleAsyncResult *result = user_data; if (error != NULL) { - g_simple_async_result_set_from_error (result, error); + g_simple_async_result_set_from_error (result, error); } else if (!correct) { - /* The current D-Bus API is a bit weird so re-use the - * AuthenticationFailed error */ - g_simple_async_result_set_error (result, TP_ERRORS, - TP_ERROR_AUTHENTICATION_FAILED, "Wrong password"); + /* The current D-Bus API is a bit weird so re-use the + * AuthenticationFailed error */ + g_simple_async_result_set_error (result, TP_ERRORS, + TP_ERROR_AUTHENTICATION_FAILED, "Wrong password"); } g_simple_async_result_complete (result); @@ -1595,10 +1595,12 @@ empathy_tp_chat_provide_password_async (EmpathyTpChat *self, GSimpleAsyncResult *result; result = g_simple_async_result_new (G_OBJECT (self), - callback, user_data, empathy_tp_chat_provide_password_finish); + callback, user_data, + empathy_tp_chat_provide_password_finish); - tp_cli_channel_interface_password_call_provide_password (priv->channel, -1, - password, provide_password_cb, result, NULL, G_OBJECT (self)); + tp_cli_channel_interface_password_call_provide_password + (priv->channel, -1, password, provide_password_cb, result, + NULL, G_OBJECT (self)); } gboolean @@ -1611,7 +1613,7 @@ empathy_tp_chat_provide_password_finish (EmpathyTpChat *self, return FALSE; g_return_val_if_fail (g_simple_async_result_is_valid (result, - G_OBJECT (self), empathy_tp_chat_provide_password_finish), FALSE); + G_OBJECT (self), empathy_tp_chat_provide_password_finish), FALSE); return TRUE; } diff --git a/libempathy/empathy-tp-chat.h b/libempathy/empathy-tp-chat.h index 013a926bf..940c36095 100644 --- a/libempathy/empathy-tp-chat.h +++ b/libempathy/empathy-tp-chat.h @@ -86,16 +86,16 @@ void empathy_tp_chat_acknowledge_message (EmpathyTpChat *chat, void empathy_tp_chat_acknowledge_messages (EmpathyTpChat *chat, const GList *messages); -gboolean empathy_tp_chat_password_needed (EmpathyTpChat *chat); +gboolean empathy_tp_chat_password_needed (EmpathyTpChat *chat); -void empathy_tp_chat_provide_password_async (EmpathyTpChat *chat, - const gchar *password, - GAsyncReadyCallback callback, - gpointer user_data); +void empathy_tp_chat_provide_password_async (EmpathyTpChat *chat, + const gchar *password, + GAsyncReadyCallback callback, + gpointer user_data); -gboolean empathy_tp_chat_provide_password_finish (EmpathyTpChat *chat, - GAsyncResult *result, - GError **error); +gboolean empathy_tp_chat_provide_password_finish (EmpathyTpChat *chat, + GAsyncResult *result, + GError **error); G_END_DECLS |