From 777c1cbd40eb63365f2c28e38f6a93beb2d1c9d1 Mon Sep 17 00:00:00 2001 From: Matthew Barnes Date: Tue, 16 Aug 2011 11:25:56 -0400 Subject: Coding style and whitespace cleanup. --- plugins/prefer-plain/prefer-plain.c | 64 +++++++++++++++++++++++++------------ 1 file changed, 44 insertions(+), 20 deletions(-) (limited to 'plugins/prefer-plain') diff --git a/plugins/prefer-plain/prefer-plain.c b/plugins/prefer-plain/prefer-plain.c index ce51ffeefd..55f62f8e3d 100644 --- a/plugins/prefer-plain/prefer-plain.c +++ b/plugins/prefer-plain/prefer-plain.c @@ -36,7 +36,7 @@ void org_gnome_prefer_plain_multipart_alternative (gpointer ep, EMFormatHookTarget *t); void org_gnome_prefer_plain_text_html (gpointer ep, EMFormatHookTarget *t); -GtkWidget *org_gnome_prefer_plain_config_mode (struct _EPlugin *epl, struct _EConfigHookItemFactoryData *data); +GtkWidget *org_gnome_prefer_plain_config_mode (EPlugin *epl, struct _EConfigHookItemFactoryData *data); enum { EPP_NORMAL, @@ -49,7 +49,10 @@ static gint epp_mode = -1; static gboolean epp_show_suppressed = TRUE; static void -make_part_attachment (EMFormat *format, CamelStream *stream, CamelMimePart *part, gint i) +make_part_attachment (EMFormat *format, + CamelStream *stream, + CamelMimePart *part, + gint i) { gint partidlen = format->part_id->len; @@ -72,7 +75,7 @@ make_part_attachment (EMFormat *format, CamelStream *stream, CamelMimePart *part "application/octet-stream", NULL); } else if (i == -1 && CAMEL_IS_MIME_MESSAGE (part)) { /* message was asked to be formatted as text/html; - might be for cases where message itself is a text/html part */ + * might be for cases where message itself is a text/html part */ CamelMimePart *new_part; CamelDataWrapper *content; @@ -94,7 +97,8 @@ make_part_attachment (EMFormat *format, CamelStream *stream, CamelMimePart *part } void -org_gnome_prefer_plain_text_html (gpointer ep, EMFormatHookTarget *t) +org_gnome_prefer_plain_text_html (gpointer ep, + EMFormatHookTarget *t) { /* In text-only mode, all html output is suppressed for the first processing */ if (epp_mode != EPP_TEXT @@ -109,7 +113,10 @@ org_gnome_prefer_plain_text_html (gpointer ep, EMFormatHookTarget *t) } static void -export_as_attachments (CamelMultipart *mp, EMFormat *format, CamelStream *stream, CamelMimePart *except) +export_as_attachments (CamelMultipart *mp, + EMFormat *format, + CamelStream *stream, + CamelMimePart *except) { gint i, nparts; CamelMimePart *part; @@ -134,7 +141,8 @@ export_as_attachments (CamelMultipart *mp, EMFormat *format, CamelStream *stream } void -org_gnome_prefer_plain_multipart_alternative (gpointer ep, EMFormatHookTarget *t) +org_gnome_prefer_plain_multipart_alternative (gpointer ep, + EMFormatHookTarget *t) { CamelMultipart *mp = (CamelMultipart *) camel_medium_get_content ((CamelMedium *) t->part); CamelMimePart *part, *display_part = NULL, *calendar_part = NULL; @@ -146,11 +154,12 @@ org_gnome_prefer_plain_multipart_alternative (gpointer ep, EMFormatHookTarget *t if (epp_mode == EPP_NORMAL) { gboolean have_plain = FALSE; - /* Try to find text/html part even when not as last and force to show it. - Old handler will show the last part of multipart/alternate, but if we - can offer HTML, then offer it, regardless of position in multipart. - But do this when have only text/plain and text/html parts, not more. - */ + /* Try to find text/html part even when not as last and force + * to show it. Old handler will show the last part of + * multipart/alternate, but if we can offer HTML, then + * offer it, regardless of position in multipart. But do + * this when have only text/plain and text/html parts, + * not more. */ nparts = camel_multipart_get_number (mp); for (i = 0; i < nparts; i++) { CamelContentType *content_type; @@ -196,7 +205,7 @@ org_gnome_prefer_plain_multipart_alternative (gpointer ep, EMFormatHookTarget *t } nparts = camel_multipart_get_number (mp); - for (i=0; i", _(epp_options[mode > 2 ? 0 : mode].description), "", NULL); @@ -254,7 +274,8 @@ update_info_label (GtkWidget *info_label, guint mode) } static void -epp_mode_changed (GtkComboBox *dropdown, GtkWidget *info_label) +epp_mode_changed (GtkComboBox *dropdown, + GtkWidget *info_label) { epp_mode = gtk_combo_box_get_active (dropdown); if (epp_mode > 2) @@ -265,7 +286,8 @@ epp_mode_changed (GtkComboBox *dropdown, GtkWidget *info_label) } static void -epp_show_suppressed_toggled (GtkToggleButton *check, gpointer data) +epp_show_suppressed_toggled (GtkToggleButton *check, + gpointer data) { g_return_if_fail (check != NULL); @@ -274,7 +296,8 @@ epp_show_suppressed_toggled (GtkToggleButton *check, gpointer data) } GtkWidget * -org_gnome_prefer_plain_config_mode (struct _EPlugin *epl, struct _EConfigHookItemFactoryData *data) +org_gnome_prefer_plain_config_mode (EPlugin *epl, + struct _EConfigHookItemFactoryData *data) { /*EMConfigTargetPrefs *ep = (EMConfigTargetPrefs *)data->target;*/ GtkComboBox *dropdown; @@ -334,7 +357,8 @@ org_gnome_prefer_plain_config_mode (struct _EPlugin *epl, struct _EConfigHookIte gint e_plugin_lib_enable (EPlugin *ep, gint enable); gint -e_plugin_lib_enable (EPlugin *ep, gint enable) +e_plugin_lib_enable (EPlugin *ep, + gint enable) { gchar *key; gint i; -- cgit v1.2.3