aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
Diffstat (limited to 'mail')
-rw-r--r--mail/e-http-request.c43
-rw-r--r--mail/e-mail-backend.c2
-rw-r--r--mail/e-mail-browser.c7
-rw-r--r--mail/e-mail-config-confirm-page.c6
-rw-r--r--mail/e-mail-config-welcome-page.c2
-rw-r--r--mail/e-mail-display-popup-extension.c3
-rw-r--r--mail/e-mail-display.c144
-rw-r--r--mail/e-mail-label-manager.c2
-rw-r--r--mail/e-mail-migrate.c2
-rw-r--r--mail/e-mail-notebook-view.c13
-rw-r--r--mail/e-mail-paned-view.c10
-rw-r--r--mail/e-mail-printer.c96
-rw-r--r--mail/e-mail-reader-utils.c29
-rw-r--r--mail/e-mail-reader.c23
-rw-r--r--mail/e-mail-request.c14
-rw-r--r--mail/e-mail-ui-session.c3
-rw-r--r--mail/em-composer-utils.c5
-rw-r--r--mail/em-filter-editor-folder-element.c4
-rw-r--r--mail/em-filter-editor.c3
-rw-r--r--mail/em-filter-rule.c40
-rw-r--r--mail/em-filter-source-element.c16
-rw-r--r--mail/em-folder-tree.c5
-rw-r--r--mail/em-folder-utils.c14
-rw-r--r--mail/em-utils.c45
-rw-r--r--mail/em-vfolder-editor-context.c2
-rw-r--r--mail/em-vfolder-editor-rule.c44
-rw-r--r--mail/importers/elm-importer.c22
-rw-r--r--mail/importers/evolution-mbox-importer.c11
-rw-r--r--mail/importers/mail-importer.c10
-rw-r--r--mail/importers/pine-importer.c34
-rw-r--r--mail/mail-autofilter.c22
-rw-r--r--mail/mail-send-recv.c22
-rw-r--r--mail/mail-vfolder-ui.c6
-rw-r--r--mail/message-list.c260
34 files changed, 536 insertions, 428 deletions
diff --git a/mail/e-http-request.c b/mail/e-http-request.c
index 6f564b6410..0f634688a2 100644
--- a/mail/e-http-request.c
+++ b/mail/e-http-request.c
@@ -49,7 +49,6 @@ struct _EHTTPRequestPrivate {
G_DEFINE_TYPE (EHTTPRequest, e_http_request, SOUP_TYPE_REQUEST)
-
static gssize
copy_stream_to_stream (CamelStream *input,
GMemoryInputStream *output,
@@ -168,8 +167,9 @@ handle_http_request (GSimpleAsyncResult *res,
stream = g_memory_input_stream_new ();
- len = copy_stream_to_stream (cache_stream,
- G_MEMORY_INPUT_STREAM (stream), cancellable);
+ len = copy_stream_to_stream (
+ cache_stream,
+ G_MEMORY_INPUT_STREAM (stream), cancellable);
request->priv->content_length = len;
g_object_unref (cache_stream);
@@ -184,13 +184,15 @@ handle_http_request (GSimpleAsyncResult *res,
path = camel_data_cache_get_filename (cache, "http", uri_md5);
file = g_file_new_for_path (path);
- info = g_file_query_info (file, G_FILE_ATTRIBUTE_STANDARD_CONTENT_TYPE,
- 0, cancellable, NULL);
+ info = g_file_query_info (
+ file, G_FILE_ATTRIBUTE_STANDARD_CONTENT_TYPE,
+ 0, cancellable, NULL);
request->priv->content_type = g_strdup (
g_file_info_get_content_type (info));
- d(printf ("'%s' found in cache (%d bytes, %s)\n",
+ d (
+ printf ("'%s' found in cache (%d bytes, %s)\n",
uri, request->priv->content_length,
request->priv->content_type));
@@ -203,7 +205,7 @@ handle_http_request (GSimpleAsyncResult *res,
goto cleanup;
} else {
- d(printf("Failed to load '%s' from cache.\n", uri));
+ d (printf ("Failed to load '%s' from cache.\n", uri));
}
}
@@ -291,7 +293,8 @@ handle_http_request (GSimpleAsyncResult *res,
error = NULL;
cache_stream = camel_data_cache_add (cache, "http", uri_md5, &error);
if (!cache_stream) {
- g_warning ("Failed to create cache file for '%s': %s",
+ g_warning (
+ "Failed to create cache file for '%s': %s",
uri, error ? error->message : "Unknown error");
g_clear_error (&error);
@@ -356,12 +359,12 @@ handle_http_request (GSimpleAsyncResult *res,
g_object_unref (msg);
g_idle_add ((GSourceFunc) unref_soup_session, session);
- d(printf ("Received image from %s\n"
- "Content-Type: %s\n"
- "Content-Length: %d bytes\n"
- "URI MD5: %s:\n",
- uri, request->priv->content_type,
- request->priv->content_length, uri_md5));
+ d (printf ("Received image from %s\n"
+ "Content-Type: %s\n"
+ "Content-Length: %d bytes\n"
+ "URI MD5: %s:\n",
+ uri, request->priv->content_type,
+ request->priv->content_length, uri_md5));
g_simple_async_result_set_op_res_gpointer (res, stream, NULL);
goto cleanup;
@@ -396,8 +399,8 @@ http_request_finalize (GObject *object)
static gboolean
http_request_check_uri (SoupRequest *request,
- SoupURI *uri,
- GError **error)
+ SoupURI *uri,
+ GError **error)
{
return ((strcmp (uri->scheme, "evo-http") == 0) ||
(strcmp (uri->scheme, "evo-https") == 0));
@@ -421,9 +424,9 @@ http_request_send_async (SoupRequest *request,
uri = soup_request_get_uri (request);
query = soup_form_decode (uri->query);
- d({
+ d ({
gchar *uri_str = soup_uri_to_string (uri, FALSE);
- printf("received request for %s\n", uri_str);
+ printf ("received request for %s\n", uri_str);
g_free (uri_str);
});
@@ -481,7 +484,7 @@ http_request_get_content_length (SoupRequest *request)
{
EHTTPRequest *efr = E_HTTP_REQUEST (request);
- d(printf("Content-Length: %d bytes\n", efr->priv->content_length));
+ d (printf ("Content-Length: %d bytes\n", efr->priv->content_length));
return efr->priv->content_length;
}
@@ -490,7 +493,7 @@ http_request_get_content_type (SoupRequest *request)
{
EHTTPRequest *efr = E_HTTP_REQUEST (request);
- d(printf("Content-Type: %s\n", efr->priv->content_type));
+ d (printf ("Content-Type: %s\n", efr->priv->content_type));
return efr->priv->content_type;
}
diff --git a/mail/e-mail-backend.c b/mail/e-mail-backend.c
index e0a0275019..ae6aebba9a 100644
--- a/mail/e-mail-backend.c
+++ b/mail/e-mail-backend.c
@@ -377,7 +377,7 @@ mail_backend_quit_requested_cb (EShell *shell,
/* In express mode, don't raise mail request in non mail window. */
if (e_shell_get_express_mode (shell) &&
- strcmp(e_shell_window_get_active_view((EShellWindow *)window), "mail") != 0)
+ strcmp (e_shell_window_get_active_view ((EShellWindow *) window), "mail") != 0)
return;
if (!e_shell_backend_is_started (mail_shell_backend))
diff --git a/mail/e-mail-browser.c b/mail/e-mail-browser.c
index f337c5cc71..7535785c35 100644
--- a/mail/e-mail-browser.c
+++ b/mail/e-mail-browser.c
@@ -584,8 +584,9 @@ mail_browser_constructed (GObject *object)
browser->priv->message_list, "message-list-built",
G_CALLBACK (mail_browser_message_list_built_cb), object);
- display = g_object_new (E_TYPE_MAIL_DISPLAY,
- "mode", E_MAIL_BROWSER (object)->priv->mode, NULL);
+ display = g_object_new (
+ E_TYPE_MAIL_DISPLAY,
+ "mode", E_MAIL_BROWSER (object)->priv->mode, NULL);
g_signal_connect_swapped (
display, "popup-event",
@@ -679,7 +680,7 @@ mail_browser_constructed (GObject *object)
gtk_style_context_add_class (
gtk_widget_get_style_context (widget),
- GTK_STYLE_CLASS_PRIMARY_TOOLBAR);
+ GTK_STYLE_CLASS_PRIMARY_TOOLBAR);
gtk_container_add (GTK_CONTAINER (container), browser->priv->preview_pane);
diff --git a/mail/e-mail-config-confirm-page.c b/mail/e-mail-config-confirm-page.c
index 6d276263e4..327794f070 100644
--- a/mail/e-mail-config-confirm-page.c
+++ b/mail/e-mail-config-confirm-page.c
@@ -155,9 +155,9 @@ e_mail_config_confirm_page_class_init (EMailConfigConfirmPageClass *class)
"Text",
"Confirmation message",
_("Congratulations, your mail configuration is "
- "complete.\n\nYou are now ready to send and "
- "receive email using Evolution.\n\nClick "
- "\"Apply\" to save your settings."),
+ "complete.\n\nYou are now ready to send and "
+ "receive email using Evolution.\n\nClick "
+ "\"Apply\" to save your settings."),
G_PARAM_READWRITE |
G_PARAM_CONSTRUCT |
G_PARAM_STATIC_STRINGS));
diff --git a/mail/e-mail-config-welcome-page.c b/mail/e-mail-config-welcome-page.c
index 9196bb8c2f..ff61f1e167 100644
--- a/mail/e-mail-config-welcome-page.c
+++ b/mail/e-mail-config-welcome-page.c
@@ -155,7 +155,7 @@ e_mail_config_welcome_page_class_init (EMailConfigWelcomePageClass *class)
"Text",
"Welcome message",
_("Welcome to the Evolution Mail Configuration "
- "Assistant.\n\nClick \"Continue\" to begin."),
+ "Assistant.\n\nClick \"Continue\" to begin."),
G_PARAM_READWRITE |
G_PARAM_CONSTRUCT |
G_PARAM_STATIC_STRINGS));
diff --git a/mail/e-mail-display-popup-extension.c b/mail/e-mail-display-popup-extension.c
index a4441797c3..d84a9ca967 100644
--- a/mail/e-mail-display-popup-extension.c
+++ b/mail/e-mail-display-popup-extension.c
@@ -24,7 +24,6 @@ G_DEFINE_INTERFACE (
e_mail_display_popup_extension,
G_TYPE_OBJECT)
-
static void
e_mail_display_popup_extension_default_init (EMailDisplayPopupExtensionInterface *iface)
{
@@ -42,7 +41,7 @@ e_mail_display_popup_extension_default_init (EMailDisplayPopupExtensionInterface
*/
void
e_mail_display_popup_extension_update_actions (EMailDisplayPopupExtension *extension,
- WebKitHitTestResult *context)
+ WebKitHitTestResult *context)
{
EMailDisplayPopupExtensionInterface *iface;
diff --git a/mail/e-mail-display.c b/mail/e-mail-display.c
index e7af641f5a..1783600725 100644
--- a/mail/e-mail-display.c
+++ b/mail/e-mail-display.c
@@ -165,7 +165,7 @@ static GtkActionEntry image_entries[] = {
static gboolean
mail_display_button_press_event (GtkWidget *widget,
- GdkEventButton *event)
+ GdkEventButton *event)
{
WebKitHitTestResult *hit_test;
WebKitHitTestResultContext context;
@@ -187,7 +187,7 @@ mail_display_button_press_event (GtkWidget *widget,
g_object_get (
G_OBJECT (hit_test),
"context", &context,
- "image-uri", &image_src,
+ "image-uri", &image_src,
NULL);
if ((context & WEBKIT_HIT_TEST_RESULT_CONTEXT_IMAGE)) {
@@ -550,23 +550,26 @@ mail_display_resource_requested (WebKitWebView *web_view,
}
new_uri = g_strconcat ("evo-", uri, NULL);
- mail_uri = e_mail_part_build_uri (part_list->folder,
- part_list->message_uid, NULL, NULL);
+ mail_uri = e_mail_part_build_uri (
+ part_list->folder,
+ part_list->message_uid, NULL, NULL);
soup_uri = soup_uri_new (new_uri);
if (soup_uri->query) {
query = soup_form_decode (soup_uri->query);
} else {
- query = g_hash_table_new_full (g_str_hash, g_str_equal,
- g_free, g_free);
+ query = g_hash_table_new_full (
+ g_str_hash, g_str_equal,
+ g_free, g_free);
}
enc = soup_uri_encode (mail_uri, NULL);
g_hash_table_insert (query, g_strdup ("__evo-mail"), enc);
if (display->priv->force_image_load) {
- g_hash_table_insert (query,
+ g_hash_table_insert (
+ query,
g_strdup ("__evo-load-images"),
- g_strdup ("true"));
+ g_strdup ("true"));
}
g_free (mail_uri);
@@ -600,7 +603,7 @@ find_element_by_id (WebKitDOMDocument *document,
return element;
/* If the element is not here then recursively scan all frames */
- frames = webkit_dom_document_get_elements_by_tag_name(document, "iframe");
+ frames = webkit_dom_document_get_elements_by_tag_name (document, "iframe");
length = webkit_dom_node_list_get_length (frames);
for (i = 0; i < length; i++) {
@@ -635,7 +638,8 @@ mail_display_plugin_widget_resize (GObject *object,
parent_element = g_object_get_data (object, "parent_element");
if (!parent_element || !WEBKIT_DOM_IS_ELEMENT (parent_element)) {
- d(printf("%s: %s does not have (valid) parent element!\n",
+ d (
+ printf ("%s: %s does not have (valid) parent element!\n",
G_STRFUNC, (gchar *) g_object_get_data (object, "uri")));
return;
}
@@ -805,7 +809,7 @@ bind_iframe_content_visibility (WebKitDOMElement *iframe,
d ({
gchar *name = webkit_dom_html_iframe_element_get_name (
WEBKIT_DOM_HTML_IFRAME_ELEMENT (iframe));
- printf("Found %ld objects within iframe %s\n", length, name);
+ printf ("Found %ld objects within iframe %s\n", length, name);
g_free (name);
});
@@ -833,7 +837,8 @@ attachment_button_expanded (GObject *object,
gboolean expanded;
gchar *id;
- d(printf("Attachment button %s has been %s!\n",
+ d (
+ printf ("Attachment button %s has been %s!\n",
(gchar *) g_object_get_data (object, "uri"),
(e_attachment_button_get_expanded (button) ? "expanded" : "collapsed")));
@@ -844,7 +849,8 @@ attachment_button_expanded (GObject *object,
element = find_element_by_id (document, g_object_get_data (object, "attachment_id"));
if (!WEBKIT_DOM_IS_ELEMENT (element)) {
- d(printf("%s: Content <div> of attachment %s does not exist!!\n",
+ d (
+ printf ("%s: Content <div> of attachment %s does not exist!!\n",
G_STRFUNC, (gchar *) g_object_get_data (object, "uri")));
return;
}
@@ -859,8 +865,9 @@ attachment_button_expanded (GObject *object,
g_free (id);
if (!WEBKIT_DOM_IS_HTML_IFRAME_ELEMENT (element)) {
- d(printf("%s: No <iframe> found\n",
- (gchar *) g_object_get_data (object, "attachment_id")));
+ d (
+ printf ("%s: No <iframe> found\n",
+ (gchar *) g_object_get_data (object, "attachment_id")));
return;
}
bind_iframe_content_visibility (element, display, button);
@@ -918,7 +925,7 @@ mail_display_plugin_widget_requested (WebKitWebView *web_view,
display = E_MAIL_DISPLAY (web_view);
if ((widget = g_hash_table_lookup (display->priv->widgets, part_id)) != NULL) {
- d(printf("Handeled %s widget request from cache\n", part_id));
+ d (printf ("Handeled %s widget request from cache\n", part_id));
return widget;
}
@@ -950,7 +957,8 @@ mail_display_plugin_widget_requested (WebKitWebView *web_view,
/* Get the widget from formatter */
widget = e_mail_formatter_extension_get_widget (
extension, display->priv->part_list, part, param);
- d(printf("Created widget %s (%p) for part %s\n",
+ d (
+ printf ("Created widget %s (%p) for part %s\n",
G_OBJECT_TYPE_NAME (widget), widget, part_id));
/* Should not happen! WebKit will display an ugly 'Plug-in not available'
@@ -970,14 +978,16 @@ mail_display_plugin_widget_requested (WebKitWebView *web_view,
attachment_part_id = part_id;
object_uri = g_strconcat (attachment_part_id, ".attachment_button", NULL);
- g_object_set_data_full (G_OBJECT (widget), "attachment_id",
+ g_object_set_data_full (
+ G_OBJECT (widget), "attachment_id",
g_strdup (attachment_part_id), (GDestroyNotify) g_free);
} else {
object_uri = g_strdup (part_id);
}
/* Store the uri as data of the widget */
- g_object_set_data_full (G_OBJECT (widget), "uri",
+ g_object_set_data_full (
+ G_OBJECT (widget), "uri",
object_uri, (GDestroyNotify) g_free);
/* Set pointer to the <object> element as GObject data "parent_element"
@@ -987,10 +997,12 @@ mail_display_plugin_widget_requested (WebKitWebView *web_view,
/* Resizing a GtkWidget requires changing size of parent
* <object> HTML element in DOM. */
- g_signal_connect (widget, "realize",
- G_CALLBACK (mail_display_plugin_widget_realize_cb), display);
- g_signal_connect (widget, "size-allocate",
- G_CALLBACK (mail_display_plugin_widget_resize), display);
+ g_signal_connect (
+ widget, "realize",
+ G_CALLBACK (mail_display_plugin_widget_realize_cb), display);
+ g_signal_connect (
+ widget, "size-allocate",
+ G_CALLBACK (mail_display_plugin_widget_resize), display);
if (E_IS_ATTACHMENT_BAR (widget)) {
GtkWidget *box = NULL;
@@ -1003,14 +1015,17 @@ mail_display_plugin_widget_requested (WebKitWebView *web_view,
/* When EAttachmentBar is expanded/collapsed it does not
* emit size-allocate signal despite it changes it's height. */
- g_signal_connect (widget, "notify::expanded",
+ g_signal_connect (
+ widget, "notify::expanded",
G_CALLBACK (mail_display_plugin_widget_resize), display);
- g_signal_connect (widget, "notify::active-view",
+ g_signal_connect (
+ widget, "notify::active-view",
G_CALLBACK (mail_display_plugin_widget_resize), display);
/* Always hide an attachment bar without attachments */
store = e_attachment_bar_get_store (E_ATTACHMENT_BAR (widget));
- g_signal_connect (store, "notify::num-attachments",
+ g_signal_connect (
+ store, "notify::num-attachments",
G_CALLBACK (mail_display_attachment_count_changed), box);
gtk_widget_show (widget);
@@ -1053,9 +1068,11 @@ mail_display_plugin_widget_requested (WebKitWebView *web_view,
/* Show/hide the attachment when the EAttachmentButton
* * is expanded/collapsed or shown/hidden */
- g_signal_connect (widget, "notify::expanded",
+ g_signal_connect (
+ widget, "notify::expanded",
G_CALLBACK (attachment_button_expanded), display);
- g_signal_connect (widget, "notify::visible",
+ g_signal_connect (
+ widget, "notify::visible",
G_CALLBACK (attachment_button_expanded), display);
/* Automatically expand attachments that have inline
@@ -1068,7 +1085,7 @@ mail_display_plugin_widget_requested (WebKitWebView *web_view,
(g_strcmp0 (empa->snoop_mime_type, "message/rfc822") == 0) ||
(disposition && disposition->disposition &&
g_ascii_strncasecmp (
- disposition->disposition, "inline", 6) == 0))) {
+ disposition->disposition, "inline", 6) == 0))) {
e_attachment_button_set_expanded (
E_ATTACHMENT_BUTTON (widget), TRUE);
@@ -1120,9 +1137,11 @@ toggle_headers_visibility (WebKitDOMElement *button,
expanded = (g_strcmp0 (css_value, "block") == 0);
g_free (css_value);
- webkit_dom_css_style_declaration_set_property (css_full, "display",
+ webkit_dom_css_style_declaration_set_property (
+ css_full, "display",
expanded ? "none" : "block", "", NULL);
- webkit_dom_css_style_declaration_set_property (css_short, "display",
+ webkit_dom_css_style_declaration_set_property (
+ css_short, "display",
expanded ? "block" : "none", "", NULL);
if (expanded)
@@ -1135,10 +1154,10 @@ toggle_headers_visibility (WebKitDOMElement *button,
e_mail_display_set_headers_collapsed (E_MAIL_DISPLAY (web_view), expanded);
- d(printf("Headers %s!\n", expanded ? "collapsed" : "expanded"));
+ d (printf ("Headers %s!\n", expanded ? "collapsed" : "expanded"));
}
-static const gchar* addresses[] = { "to", "cc", "bcc" };
+static const gchar * addresses[] = { "to", "cc", "bcc" };
static void
toggle_address_visibility (WebKitDOMElement *button,
@@ -1311,7 +1330,7 @@ mail_parts_bind_dom (GObject *object,
if (part->bind_func) {
WebKitDOMElement *el = find_element_by_id (document, part->id);
if (el) {
- d(printf("/*bind_func*/ for %s\n", part->id));
+ d (printf ("/*bind_func*/ for %s\n", part->id));
part->bind_func (part, el);
}
}
@@ -1325,10 +1344,11 @@ mail_display_frame_created (WebKitWebView *web_view,
WebKitWebFrame *frame,
gpointer user_data)
{
- d(printf("Frame %s created!\n", webkit_web_frame_get_name (frame)));
+ d (printf ("Frame %s created!\n", webkit_web_frame_get_name (frame)));
/* Call bind_func of all parts written in this frame */
- g_signal_connect (frame, "notify::load-status",
+ g_signal_connect (
+ frame, "notify::load-status",
G_CALLBACK (mail_parts_bind_dom), NULL);
}
@@ -1337,7 +1357,7 @@ mail_display_uri_changed (EMailDisplay *display,
GParamSpec *pspec,
gpointer dummy)
{
- d(printf("EMailDisplay URI changed, recreating widgets hashtable\n"));
+ d (printf ("EMailDisplay URI changed, recreating widgets hashtable\n"));
if (display->priv->widgets)
g_hash_table_destroy (display->priv->widgets);
@@ -1468,18 +1488,24 @@ e_mail_display_init (EMailDisplay *display)
settings = webkit_web_view_get_settings (WEBKIT_WEB_VIEW (display));
g_object_set (settings, "enable-frame-flattening", TRUE, NULL);
- g_signal_connect (display, "navigation-policy-decision-requested",
- G_CALLBACK (mail_display_link_clicked), NULL);
- g_signal_connect (display, "resource-request-starting",
- G_CALLBACK (mail_display_resource_requested), NULL);
- g_signal_connect (display, "process-mailto",
- G_CALLBACK (mail_display_process_mailto), NULL);
- g_signal_connect (display, "create-plugin-widget",
- G_CALLBACK (mail_display_plugin_widget_requested), NULL);
- g_signal_connect (display, "frame-created",
- G_CALLBACK (mail_display_frame_created), NULL);
- g_signal_connect (display, "notify::uri",
- G_CALLBACK (mail_display_uri_changed), NULL);
+ g_signal_connect (
+ display, "navigation-policy-decision-requested",
+ G_CALLBACK (mail_display_link_clicked), NULL);
+ g_signal_connect (
+ display, "resource-request-starting",
+ G_CALLBACK (mail_display_resource_requested), NULL);
+ g_signal_connect (
+ display, "process-mailto",
+ G_CALLBACK (mail_display_process_mailto), NULL);
+ g_signal_connect (
+ display, "create-plugin-widget",
+ G_CALLBACK (mail_display_plugin_widget_requested), NULL);
+ g_signal_connect (
+ display, "frame-created",
+ G_CALLBACK (mail_display_frame_created), NULL);
+ g_signal_connect (
+ display, "notify::uri",
+ G_CALLBACK (mail_display_uri_changed), NULL);
display->priv->settings = g_settings_new ("org.gnome.evolution.mail");
g_signal_connect_swapped (
@@ -1495,11 +1521,13 @@ e_mail_display_init (EMailDisplay *display)
e_web_view_update_fonts (E_WEB_VIEW (display));
main_frame = webkit_web_view_get_main_frame (WEBKIT_WEB_VIEW (display));
- g_signal_connect (main_frame, "notify::load-status",
+ g_signal_connect (
+ main_frame, "notify::load-status",
G_CALLBACK (setup_DOM_bindings), NULL);
main_frame = webkit_web_view_get_main_frame (WEBKIT_WEB_VIEW (display));
- g_signal_connect (main_frame, "notify::load-status",
- G_CALLBACK (mail_parts_bind_dom), NULL);
+ g_signal_connect (
+ main_frame, "notify::load-status",
+ G_CALLBACK (mail_parts_bind_dom), NULL);
actions = e_web_view_get_action_group (E_WEB_VIEW (display), "mailto");
gtk_action_group_add_actions (
@@ -1558,10 +1586,12 @@ e_mail_display_set_mode (EMailDisplay *display,
display->priv->formatter = formatter;
mail_display_update_formatter_colors (display);
- g_signal_connect (formatter, "notify::image-loading-policy",
+ g_signal_connect (
+ formatter, "notify::image-loading-policy",
G_CALLBACK (formatter_image_loading_policy_changed_cb), display);
- g_object_connect (formatter,
+ g_object_connect (
+ formatter,
"swapped-object-signal::notify::charset",
G_CALLBACK (e_mail_display_reload), display,
"swapped-object-signal::notify::image-loading-policy",
@@ -1704,7 +1734,6 @@ e_mail_display_load (EMailDisplay *display,
g_free (uri);
}
-
static gboolean
do_reload_display (EMailDisplay *display)
{
@@ -1722,7 +1751,7 @@ do_reload_display (EMailDisplay *display)
if (!uri || !*uri)
return FALSE;
- if (strstr(uri, "?") == NULL) {
+ if (strstr (uri, "?") == NULL) {
e_web_view_reload (web_view);
return FALSE;
}
@@ -1824,7 +1853,6 @@ e_mail_display_set_status (EMailDisplay *display,
gtk_widget_show_all (GTK_WIDGET (display));
}
-
static gchar *
mail_display_get_frame_selection_text (WebKitDOMElement *iframe)
{
@@ -1920,7 +1948,7 @@ e_mail_display_set_force_load_images (EMailDisplay *display,
void
e_mail_display_set_charset (EMailDisplay *display,
- const gchar *charset)
+ const gchar *charset)
{
g_return_if_fail (E_IS_MAIL_DISPLAY (display));
diff --git a/mail/e-mail-label-manager.c b/mail/e-mail-label-manager.c
index 5b2990bd84..2d09cbc523 100644
--- a/mail/e-mail-label-manager.c
+++ b/mail/e-mail-label-manager.c
@@ -351,7 +351,7 @@ e_mail_label_manager_init (EMailLabelManager *manager)
/* FIXME Clarify this. What menu? */
widget = gtk_label_new (
_("Note: Underscore in the label name is used\n"
- "as mnemonic identifier in menu."));
+ "as mnemonic identifier in menu."));
gtk_label_set_justify (GTK_LABEL (widget), GTK_JUSTIFY_CENTER);
gtk_table_attach (
GTK_TABLE (container), widget,
diff --git a/mail/e-mail-migrate.c b/mail/e-mail-migrate.c
index c642df91db..603bf531f5 100644
--- a/mail/e-mail-migrate.c
+++ b/mail/e-mail-migrate.c
@@ -187,7 +187,7 @@ emm_setup_initial (const gchar *data_dir)
/* special-case - this means brand new install of evolution */
/* FIXME: create default folders and stuff... */
- d(printf("Setting up initial mail tree\n"));
+ d (printf ("Setting up initial mail tree\n"));
base = g_build_filename (data_dir, "local", NULL);
if (g_mkdir_with_parents (base, 0700) == -1 && errno != EEXIST) {
diff --git a/mail/e-mail-notebook-view.c b/mail/e-mail-notebook-view.c
index 28e10dd3b2..f5d30d588f 100644
--- a/mail/e-mail-notebook-view.c
+++ b/mail/e-mail-notebook-view.c
@@ -136,7 +136,7 @@ static void
tab_remove_gtk_cb (GtkWidget *button,
EMailNotebookView *view)
{
- EMailView *page = g_object_get_data ((GObject *)button, "page");
+ EMailView *page = g_object_get_data ((GObject *) button, "page");
EMailView *prev;
gint num;
@@ -158,8 +158,9 @@ tab_remove_gtk_cb (GtkWidget *button,
num = emnv_get_page_num (view, (GtkWidget *) prev);
gtk_notebook_set_current_page (view->priv->book, num);
}
- gtk_notebook_remove_page (view->priv->book,
- gtk_notebook_page_num (view->priv->book, (GtkWidget *) page));
+ gtk_notebook_remove_page (
+ view->priv->book,
+ gtk_notebook_page_num (view->priv->book, (GtkWidget *) page));
}
@@ -226,8 +227,8 @@ create_tab_label (EMailNotebookView *view,
"gtk-close", GTK_ICON_SIZE_MENU));
gtk_widget_show_all (widget);
gtk_box_pack_end (GTK_BOX (container), widget, FALSE, FALSE, 0);
- g_object_set_data ((GObject *)widget, "page", page);
- g_object_set_data ((GObject *)page, "close-button", widget);
+ g_object_set_data ((GObject *) widget, "page", page);
+ g_object_set_data ((GObject *) page, "close-button", widget);
g_signal_connect (
widget, "clicked",
@@ -686,7 +687,7 @@ mail_netbook_view_open_mail (EMailView *view,
gtk_notebook_set_current_page (priv->book, page);
g_signal_connect (
- E_MAIL_READER(pane), "changed",
+ E_MAIL_READER (pane), "changed",
G_CALLBACK (reconnect_changed_event), nview);
g_signal_connect (
E_MAIL_READER (pane), "folder-loaded",
diff --git a/mail/e-mail-paned-view.c b/mail/e-mail-paned-view.c
index 55fbd93589..8ba322539e 100644
--- a/mail/e-mail-paned-view.c
+++ b/mail/e-mail-paned-view.c
@@ -642,7 +642,8 @@ mail_paned_view_constructed (GObject *object)
priv = E_MAIL_PANED_VIEW_GET_PRIVATE (object);
- priv->display = g_object_new (E_TYPE_MAIL_DISPLAY,
+ priv->display = g_object_new (
+ E_TYPE_MAIL_DISPLAY,
"headers-collapsable", TRUE, NULL);
view = E_MAIL_VIEW (object);
@@ -655,9 +656,10 @@ mail_paned_view_constructed (GObject *object)
backend = E_MAIL_BACKEND (shell_backend);
session = e_mail_backend_get_session (backend);
- g_object_bind_property (shell_settings, "paned-view-headers-state",
- priv->display, "headers-collapsed",
- G_BINDING_BIDIRECTIONAL | G_BINDING_SYNC_CREATE);
+ g_object_bind_property (
+ shell_settings, "paned-view-headers-state",
+ priv->display, "headers-collapsed",
+ G_BINDING_BIDIRECTIONAL | G_BINDING_SYNC_CREATE);
/* Build content widgets. */
diff --git a/mail/e-mail-printer.c b/mail/e-mail-printer.c
index 1c92f61944..92642bb996 100644
--- a/mail/e-mail-printer.c
+++ b/mail/e-mail-printer.c
@@ -164,7 +164,6 @@ do_run_print_operation (EMailPrinter *emp)
return FALSE;
}
-
static void
emp_start_printing (GObject *object,
GParamSpec *pspec,
@@ -204,7 +203,8 @@ emp_run_print_operation (EMailPrinter *emp)
{
gchar *mail_uri;
- mail_uri = e_mail_part_build_uri (emp->priv->parts_list->folder,
+ mail_uri = e_mail_part_build_uri (
+ emp->priv->parts_list->folder,
emp->priv->parts_list->message_uid,
"__evo-load-image", G_TYPE_BOOLEAN, TRUE,
"mode", G_TYPE_INT, E_MAIL_FORMATTER_MODE_PRINTING,
@@ -220,15 +220,17 @@ emp_run_print_operation (EMailPrinter *emp)
E_MAIL_DISPLAY (emp->priv->webview), TRUE);
g_object_ref_sink (emp->priv->webview);
- g_signal_connect (emp->priv->webview, "notify::load-status",
+ g_signal_connect (
+ emp->priv->webview, "notify::load-status",
G_CALLBACK (emp_start_printing), emp);
w ({
GtkWidget *window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
GtkWidget *sw = gtk_scrolled_window_new (NULL, NULL);
gtk_container_add (GTK_CONTAINER (window), sw);
- gtk_container_add (GTK_CONTAINER (sw),
- GTK_WIDGET (emp->priv->webview));
+ gtk_container_add (
+ GTK_CONTAINER (sw),
+ GTK_WIDGET (emp->priv->webview));
gtk_widget_show_all (window);
});
}
@@ -257,7 +259,8 @@ set_header_visible (EMailPrinter *emp,
element = WEBKIT_DOM_ELEMENT (webkit_dom_node_list_item (headers, index));
style = webkit_dom_element_get_style (element);
- webkit_dom_css_style_declaration_set_property (style,
+ webkit_dom_css_style_declaration_set_property (
+ style,
"display", (visible ? "table-row" : "none"), "", NULL);
}
@@ -272,14 +275,18 @@ header_active_renderer_toggled_cb (GtkCellRendererToggle *renderer,
EMailFormatterHeader *header;
gint *indices;
- gtk_tree_model_get_iter_from_string (GTK_TREE_MODEL (emp->priv->headers),
+ gtk_tree_model_get_iter_from_string (
+ GTK_TREE_MODEL (emp->priv->headers),
&iter, path);
- gtk_tree_model_get (GTK_TREE_MODEL (emp->priv->headers), &iter,
+ gtk_tree_model_get (
+ GTK_TREE_MODEL (emp->priv->headers), &iter,
COLUMN_ACTIVE, &active, -1);
- gtk_tree_model_get (GTK_TREE_MODEL (emp->priv->headers), &iter,
+ gtk_tree_model_get (
+ GTK_TREE_MODEL (emp->priv->headers), &iter,
COLUMN_HEADER_STRUCT, &header, -1);
- gtk_list_store_set (GTK_LIST_STORE (emp->priv->headers), &iter,
+ gtk_list_store_set (
+ GTK_LIST_STORE (emp->priv->headers), &iter,
COLUMN_ACTIVE, !active, -1);
p = gtk_tree_path_new_from_string (path);
@@ -311,9 +318,11 @@ emp_headers_tab_toggle_selection (GtkWidget *button,
GtkTreePath *path;
gint *indices;
- gtk_tree_model_get (GTK_TREE_MODEL (emp->priv->headers), &iter,
+ gtk_tree_model_get (
+ GTK_TREE_MODEL (emp->priv->headers), &iter,
COLUMN_HEADER_STRUCT, &header, -1);
- gtk_list_store_set (GTK_LIST_STORE (emp->priv->headers), &iter,
+ gtk_list_store_set (
+ GTK_LIST_STORE (emp->priv->headers), &iter,
COLUMN_ACTIVE, select, -1);
path = gtk_tree_model_get_path (GTK_TREE_MODEL (emp->priv->headers), &iter);
@@ -393,7 +402,8 @@ emp_headers_tab_move (GtkWidget *button,
references = NULL;
for (l = selected_rows; l; l = l->next) {
- references = g_list_prepend (references,
+ references = g_list_prepend (
+ references,
gtk_tree_row_reference_new (model, l->data));
}
@@ -496,7 +506,8 @@ emp_headers_tab_move (GtkWidget *button,
/* Keep the selection in middle of the screen */
path = gtk_tree_row_reference_get_path (selection_middle);
- gtk_tree_view_scroll_to_cell (GTK_TREE_VIEW (emp->priv->treeview),
+ gtk_tree_view_scroll_to_cell (
+ GTK_TREE_VIEW (emp->priv->treeview),
path, COLUMN_ACTIVE, TRUE, 0.5, 0.5);
gtk_tree_path_free (path);
gtk_tree_row_reference_free (selection_middle);
@@ -526,20 +537,22 @@ emp_create_headers_tab (GtkPrintOperation *operation,
view = GTK_TREE_VIEW (emp->priv->treeview);
selection = gtk_tree_view_get_selection (view);
gtk_tree_selection_set_mode (selection, GTK_SELECTION_MULTIPLE);
- g_signal_connect (selection, "changed",
+ g_signal_connect (
+ selection, "changed",
G_CALLBACK (emp_headers_tab_selection_changed), emp);
renderer = gtk_cell_renderer_toggle_new ();
- g_signal_connect (renderer, "toggled",
+ g_signal_connect (
+ renderer, "toggled",
G_CALLBACK (header_active_renderer_toggled_cb), emp);
column = gtk_tree_view_column_new_with_attributes (
- _("Print"), renderer,
+ _("Print"), renderer,
"active", COLUMN_ACTIVE, NULL);
gtk_tree_view_append_column (view, column);
renderer = gtk_cell_renderer_text_new ();
column = gtk_tree_view_column_new_with_attributes (
- _("Header Name"), renderer,
+ _("Header Name"), renderer,
"text", COLUMN_HEADER_NAME, NULL);
gtk_tree_view_append_column (view, column);
@@ -555,41 +568,47 @@ emp_create_headers_tab (GtkPrintOperation *operation,
button = gtk_button_new_from_stock (GTK_STOCK_SELECT_ALL);
emp->priv->buttons[BUTTON_SELECT_ALL] = button;
- g_signal_connect (button, "clicked",
+ g_signal_connect (
+ button, "clicked",
G_CALLBACK (emp_headers_tab_toggle_selection), emp);
gtk_box_pack_start (GTK_BOX (vbox), button, FALSE, TRUE, 5);
button = gtk_button_new_from_stock (GTK_STOCK_CLEAR);
emp->priv->buttons[BUTTON_SELECT_NONE] = button;
- g_signal_connect (button, "clicked",
+ g_signal_connect (
+ button, "clicked",
G_CALLBACK (emp_headers_tab_toggle_selection), emp);
gtk_box_pack_start (GTK_BOX (vbox), button, FALSE, TRUE, 5);
button = gtk_button_new_from_stock (GTK_STOCK_GOTO_TOP);
emp->priv->buttons[BUTTON_TOP] = button;
gtk_widget_set_sensitive (button, FALSE);
- g_signal_connect (button, "clicked",
+ g_signal_connect (
+ button, "clicked",
G_CALLBACK (emp_headers_tab_move), emp);
gtk_box_pack_start (GTK_BOX (vbox), button, FALSE, TRUE, 5);
button = gtk_button_new_from_stock (GTK_STOCK_GO_UP);
emp->priv->buttons[BUTTON_UP] = button;
gtk_widget_set_sensitive (button, FALSE);
- g_signal_connect (button, "clicked",
+ g_signal_connect (
+ button, "clicked",
G_CALLBACK (emp_headers_tab_move), emp);
gtk_box_pack_start (GTK_BOX (vbox), button, FALSE, TRUE, 5);
button = gtk_button_new_from_stock (GTK_STOCK_GO_DOWN);
emp->priv->buttons[BUTTON_DOWN] = button;
gtk_widget_set_sensitive (button, FALSE);
- g_signal_connect (button, "clicked",
+ g_signal_connect (
+ button, "clicked",
G_CALLBACK (emp_headers_tab_move), emp);
gtk_box_pack_start (GTK_BOX (vbox), button, FALSE, TRUE, 5);
button = gtk_button_new_from_stock (GTK_STOCK_GOTO_BOTTOM);
emp->priv->buttons[BUTTON_BOTTOM] = button;
gtk_widget_set_sensitive (button, FALSE);
- g_signal_connect (button, "clicked",
+ g_signal_connect (
+ button, "clicked",
G_CALLBACK (emp_headers_tab_move), emp);
gtk_box_pack_start (GTK_BOX (vbox), button, FALSE, TRUE, 5);
@@ -614,7 +633,8 @@ emp_set_parts_list (EMailPrinter *emp,
if (emp->priv->headers)
g_object_unref (emp->priv->headers);
- emp->priv->headers = gtk_list_store_new (5,
+ emp->priv->headers = gtk_list_store_new (
+ 5,
G_TYPE_BOOLEAN, G_TYPE_STRING, G_TYPE_STRING, G_TYPE_POINTER, G_TYPE_INT);
headers = camel_medium_get_headers (CAMEL_MEDIUM (parts_list->message));
@@ -648,7 +668,8 @@ emp_set_parts_list (EMailPrinter *emp,
last_known = iter;
}
- gtk_list_store_set (emp->priv->headers, &iter,
+ gtk_list_store_set (
+ emp->priv->headers, &iter,
COLUMN_ACTIVE, (found_header != NULL),
COLUMN_HEADER_NAME, emfh->name,
COLUMN_HEADER_VALUE, emfh->value,
@@ -687,8 +708,7 @@ emp_get_property (GObject *object,
switch (property_id) {
case PROP_PART_LIST:
- g_value_set_pointer (value,
- emp->priv->parts_list);
+ g_value_set_pointer (value, emp->priv->parts_list);
return;
}
@@ -711,7 +731,8 @@ emp_finalize (GObject *object)
if (gtk_tree_model_get_iter_first (GTK_TREE_MODEL (priv->headers), &iter)) {
do {
EMailFormatterHeader *header = NULL;
- gtk_tree_model_get (GTK_TREE_MODEL (priv->headers), &iter,
+ gtk_tree_model_get (
+ GTK_TREE_MODEL (priv->headers), &iter,
COLUMN_HEADER_STRUCT, &header, -1);
e_mail_formatter_header_free (header);
} while (gtk_tree_model_iter_next (GTK_TREE_MODEL (priv->headers), &iter));
@@ -793,7 +814,8 @@ e_mail_printer_new (EMailPartList *source)
{
EMailPrinter *emp;
- emp = g_object_new (E_TYPE_MAIL_PRINTER,
+ emp = g_object_new (
+ E_TYPE_MAIL_PRINTER,
"parts-list", source, NULL);
return emp;
@@ -801,7 +823,7 @@ e_mail_printer_new (EMailPartList *source)
void
e_mail_printer_print (EMailPrinter *emp,
- GtkPrintOperationAction action,
+ GtkPrintOperationAction action,
GCancellable *cancellable)
{
g_return_if_fail (E_IS_MAIL_PRINTER (emp));
@@ -813,15 +835,19 @@ e_mail_printer_print (EMailPrinter *emp,
gtk_print_operation_set_unit (emp->priv->operation, GTK_UNIT_PIXEL);
gtk_print_operation_set_show_progress (emp->priv->operation, TRUE);
- g_signal_connect (emp->priv->operation, "create-custom-widget",
+ g_signal_connect (
+ emp->priv->operation, "create-custom-widget",
G_CALLBACK (emp_create_headers_tab), emp);
- g_signal_connect (emp->priv->operation, "done",
+ g_signal_connect (
+ emp->priv->operation, "done",
G_CALLBACK (emp_printing_done), emp);
- g_signal_connect (emp->priv->operation, "draw-page",
+ g_signal_connect (
+ emp->priv->operation, "draw-page",
G_CALLBACK (emp_draw_footer), NULL);
if (cancellable)
- g_signal_connect_swapped (cancellable, "cancelled",
+ g_signal_connect_swapped (
+ cancellable, "cancelled",
G_CALLBACK (gtk_print_operation_cancel), emp->priv->operation);
emp_run_print_operation (emp);
diff --git a/mail/e-mail-reader-utils.c b/mail/e-mail-reader-utils.c
index ae4a98b664..3a8a2cab54 100644
--- a/mail/e-mail-reader-utils.c
+++ b/mail/e-mail-reader-utils.c
@@ -834,13 +834,15 @@ e_mail_reader_open_selected (EMailReader *reader)
GtkWidget *browser;
MessageList *ml;
- browser = e_mail_browser_new (backend, folder, uid,
- E_MAIL_FORMATTER_MODE_NORMAL);
+ browser = e_mail_browser_new (
+ backend, folder, uid,
+ E_MAIL_FORMATTER_MODE_NORMAL);
e_mail_reader_set_folder (E_MAIL_READER (browser), folder);
e_mail_reader_set_message (E_MAIL_READER (browser), uid);
- ml = MESSAGE_LIST (e_mail_reader_get_message_list (E_MAIL_READER (browser)));
+ ml = MESSAGE_LIST (e_mail_reader_get_message_list (
+ E_MAIL_READER (browser)));
message_list_freeze (ml);
copy_tree_state (reader, E_MAIL_READER (browser));
@@ -885,7 +887,8 @@ printing_done_cb (EMailPrinter *printer,
gtk_print_operation_get_error (operation, &error);
if (error != NULL) {
- e_alert_submit (alert_sink, "mail:printing-failed",
+ e_alert_submit (
+ alert_sink, "mail:printing-failed",
error->message, NULL);
g_error_free (error);
}
@@ -902,10 +905,12 @@ printing_done_cb (EMailPrinter *printer,
/* We can't destroy the printer and associated WebKitWebView directly from
* here, because this callback is a handler of a WebKit's signal. This
* will destroy the printer later, together with the activity */
- g_object_set_data_full (G_OBJECT (activity),
+ g_object_set_data_full (
+ G_OBJECT (activity),
"printer", printer, (GDestroyNotify) g_object_unref);
- g_timeout_add_seconds_full (G_PRIORITY_DEFAULT, 3,
+ g_timeout_add_seconds_full (
+ G_PRIORITY_DEFAULT, 3,
(GSourceFunc) destroy_printing_activity, activity, NULL);
}
@@ -953,7 +958,8 @@ mail_reader_do_print_message (GObject *object,
part_list = e_mail_reader_parse_message_finish (reader, result);
printer = e_mail_printer_new (part_list);
- g_signal_connect (printer, "done",
+ g_signal_connect (
+ printer, "done",
G_CALLBACK (printing_done_cb), activity);
e_mail_printer_print (printer, context->action, cancellable);
@@ -1299,7 +1305,8 @@ mail_reader_get_message_ready_cb (CamelFolder *folder,
g_return_if_fail (CAMEL_IS_MIME_MESSAGE (message));
- e_mail_reader_parse_message (context->reader, context->folder,
+ e_mail_reader_parse_message (
+ context->reader, context->folder,
context->message_uid, message, NULL,
mail_reader_reply_message_parsed, context);
}
@@ -1834,7 +1841,7 @@ emr_header_from_xmldoc (xmlDocPtr doc)
return NULL;
root = doc->children;
- if (strcmp ((gchar *)root->name, "header") != 0)
+ if (strcmp ((gchar *) root->name, "header") != 0)
return NULL;
name = xmlGetProp (root, (const guchar *)"name");
@@ -1899,7 +1906,7 @@ e_mail_reader_header_to_xml (EMailReaderHeader *header)
doc = xmlNewDoc ((const guchar *)"1.0");
root = xmlNewDocNode (doc, NULL, (const guchar *)"header", NULL);
- xmlSetProp (root, (const guchar *)"name", (guchar *)header->name);
+ xmlSetProp (root, (const guchar *)"name", (guchar *) header->name);
if (header->enabled)
xmlSetProp (root, (const guchar *)"enabled", NULL);
@@ -1995,7 +2002,7 @@ e_mail_reader_parse_message (EMailReader *reader,
CamelFolder *folder,
const gchar *message_uid,
CamelMimeMessage *message,
- GCancellable *cancellable,
+ GCancellable *cancellable,
GAsyncReadyCallback ready_callback,
gpointer user_data)
{
diff --git a/mail/e-mail-reader.c b/mail/e-mail-reader.c
index 33b604a017..659e5699a0 100644
--- a/mail/e-mail-reader.c
+++ b/mail/e-mail-reader.c
@@ -1718,12 +1718,13 @@ mail_source_retrieved (GObject *object,
error = NULL;
message = camel_folder_get_message_finish (
- CAMEL_FOLDER (object), result, &error);
+ CAMEL_FOLDER (object), result, &error);
if (error || !message) {
gchar *status;
- status = g_strdup_printf ("%s<br>%s",
- _("Failed to retrieve message:"),
- error ? error->message : _("Unknown error"));
+ status = g_strdup_printf (
+ "%s<br>%s",
+ _("Failed to retrieve message:"),
+ error ? error->message : _("Unknown error"));
e_mail_display_set_status (display, status);
g_free (status);
g_clear_error (&error);
@@ -1782,9 +1783,10 @@ action_mail_show_source_cb (GtkAction *action,
closure->browser = g_object_ref (E_MAIL_READER (browser));
closure->activity = activity;
closure->message_uid = g_strdup (message_uid);
- camel_folder_get_message (folder, message_uid, G_PRIORITY_DEFAULT,
- cancellable, mail_source_retrieved,
- closure);
+ camel_folder_get_message (
+ folder, message_uid, G_PRIORITY_DEFAULT,
+ cancellable, mail_source_retrieved,
+ closure);
em_utils_uids_free (uids);
}
@@ -3025,6 +3027,7 @@ mail_reader_set_folder (EMailReader *reader,
EMailBackend *backend;
EShell *shell;
gboolean outgoing;
+ gboolean sync_folder;
priv = E_MAIL_READER_GET_PRIVATE (reader);
@@ -3039,7 +3042,11 @@ mail_reader_set_folder (EMailReader *reader,
registry = e_shell_get_registry (shell);
/* Only synchronize the real folder if we're online. */
- if (previous_folder != NULL && (CAMEL_IS_VEE_FOLDER (previous_folder) || e_shell_get_online (shell)))
+ sync_folder =
+ (previous_folder != NULL) &&
+ (CAMEL_IS_VEE_FOLDER (previous_folder) ||
+ e_shell_get_online (shell));
+ if (sync_folder)
mail_sync_folder (previous_folder, NULL, NULL);
/* Skip the rest if we're already viewing the folder. */
diff --git a/mail/e-mail-request.c b/mail/e-mail-request.c
index 28d1c87d25..37320bc4a3 100644
--- a/mail/e-mail-request.c
+++ b/mail/e-mail-request.c
@@ -149,14 +149,14 @@ handle_mail_request (GSimpleAsyncResult *res,
/* Convert the GString to GInputStream and send it back to WebKit */
ba = camel_stream_mem_get_byte_array (CAMEL_STREAM_MEM (request->priv->output_stream));
if (!ba->data) {
- gchar *data = g_strdup_printf(_("Failed to load part '%s'"), part_id);
- dd(printf("%s", data));
+ gchar *data = g_strdup_printf (_("Failed to load part '%s'"), part_id);
+ dd (printf ("%s", data));
g_byte_array_append (ba, (guchar *) data, strlen (data));
g_free (data);
} else {
dd ({
gchar *d = g_strndup ((gchar *) ba->data, ba->len);
- printf("%s", d);
+ printf ("%s", d);
g_free (d);
});
}
@@ -328,7 +328,7 @@ mail_request_send_async (SoupRequest *request,
uri = soup_request_get_uri (request);
- d(printf("received request for %s\n", soup_uri_to_string (uri, FALSE)));
+ d (printf ("received request for %s\n", soup_uri_to_string (uri, FALSE)));
if (uri->query) {
emr->priv->uri_query = soup_form_decode (uri->query);
@@ -396,7 +396,7 @@ mail_request_get_content_length (SoupRequest *request)
}
}
- d(printf("Content-Length: %d bytes\n", content_length));
+ d (printf ("Content-Length: %d bytes\n", content_length));
return content_length;
}
@@ -419,12 +419,12 @@ mail_request_get_content_type (SoupRequest *request)
emr->priv->ret_mime_type = mime_type;
}
- d(printf("Content-Type: %s\n", emr->priv->ret_mime_type));
+ d (printf ("Content-Type: %s\n", emr->priv->ret_mime_type));
return emr->priv->ret_mime_type;
}
-static const char *data_schemes[] = { "mail", NULL };
+static const gchar *data_schemes[] = { "mail", NULL };
static void
e_mail_request_class_init (EMailRequestClass *class)
diff --git a/mail/e-mail-ui-session.c b/mail/e-mail-ui-session.c
index 7476a3521a..c86de6af0e 100644
--- a/mail/e-mail-ui-session.c
+++ b/mail/e-mail-ui-session.c
@@ -667,9 +667,6 @@ static void
mail_ui_session_refresh_service (EMailSession *session,
CamelService *service)
{
- g_debug ("*** Refreshing %s ***",
- camel_service_get_display_name (service));
-
if (camel_session_get_online (CAMEL_SESSION (session)))
mail_receive_service (service);
}
diff --git a/mail/em-composer-utils.c b/mail/em-composer-utils.c
index c01ec85913..28b1962002 100644
--- a/mail/em-composer-utils.c
+++ b/mail/em-composer-utils.c
@@ -973,7 +973,8 @@ em_utils_composer_print_cb (EMsgComposer *composer,
/* Use EMailPrinter and WebKit to print the message */
emp = e_mail_printer_new (parts);
- g_signal_connect (emp, "done",
+ g_signal_connect (
+ emp, "done",
G_CALLBACK (composer_print_done_cb), NULL);
e_mail_printer_print (
@@ -1279,7 +1280,7 @@ static struct {
* with a value. To see a full list of available variables,
* see mail/em-composer-utils.c:attribvars array. */
N_("On ${AbbrevWeekdayName}, ${Year}-${Month}-${Day} at "
- "${24Hour}:${Minute} ${TimeZone}, ${Sender} wrote:")
+ "${24Hour}:${Minute} ${TimeZone}, ${Sender} wrote:")
},
[QUOTING_FORWARD] =
diff --git a/mail/em-filter-editor-folder-element.c b/mail/em-filter-editor-folder-element.c
index 025693cc80..6179384e33 100644
--- a/mail/em-filter-editor-folder-element.c
+++ b/mail/em-filter-editor-folder-element.c
@@ -149,13 +149,15 @@ filter_editor_folder_element_get_widget (EFilterElement *fe)
EMFilterEditorFolderElement *ff = (EMFilterEditorFolderElement *) fe;
EMailSession *session;
GtkWidget *button;
+ const gchar *uri;
session = em_filter_editor_folder_element_get_session (ff);
+ uri = em_filter_folder_element_get_uri ((EMFilterFolderElement *) ff);
button = em_folder_selection_button_new (
session, _("Select Folder"), NULL);
em_folder_selection_button_set_folder_uri (
- EM_FOLDER_SELECTION_BUTTON (button), em_filter_folder_element_get_uri ((EMFilterFolderElement *) ff));
+ EM_FOLDER_SELECTION_BUTTON (button), uri);
gtk_widget_show (button);
g_signal_connect (
diff --git a/mail/em-filter-editor.c b/mail/em-filter-editor.c
index 1d60acdec6..e47b104ee9 100644
--- a/mail/em-filter-editor.c
+++ b/mail/em-filter-editor.c
@@ -147,7 +147,8 @@ em_filter_editor_construct (EMFilterEditor *fe,
for (i = 0; source_names[i].source; i++) {
gtk_list_store_append (store, &iter);
- gtk_list_store_set (store, &iter,
+ gtk_list_store_set (
+ store, &iter,
0, source_names[i].name,
-1);
sources = g_slist_append (sources, g_strdup (source_names[i].source));
diff --git a/mail/em-filter-rule.c b/mail/em-filter-rule.c
index 901d79b21a..cd0c46b570 100644
--- a/mail/em-filter-rule.c
+++ b/mail/em-filter-rule.c
@@ -130,9 +130,9 @@ void
em_filter_rule_build_action (EMFilterRule *fr,
GString *out)
{
- g_string_append(out, "(begin\n");
+ g_string_append (out, "(begin\n");
e_filter_part_build_code_list (fr->actions, out);
- g_string_append(out, ")\n");
+ g_string_append (out, ")\n");
}
static gint
@@ -193,7 +193,7 @@ xml_encode (EFilterRule *fr)
node = E_FILTER_RULE_CLASS (em_filter_rule_parent_class)->
xml_encode (fr);
g_return_val_if_fail (node != NULL, NULL);
- set = xmlNewNode(NULL, (const guchar *)"actionset");
+ set = xmlNewNode (NULL, (const guchar *)"actionset");
xmlAddChild (node, set);
l = ff->actions;
while (l) {
@@ -217,19 +217,19 @@ load_set (xmlNodePtr node,
work = node->children;
while (work) {
- if (!strcmp((gchar *)work->name, "part")) {
- rulename = (gchar *)xmlGetProp(work, (const guchar *)"name");
+ if (!strcmp ((gchar *) work->name, "part")) {
+ rulename = (gchar *) xmlGetProp (work, (const guchar *)"name");
part = em_filter_context_find_action ((EMFilterContext *) rc, rulename);
if (part) {
part = e_filter_part_clone (part);
e_filter_part_xml_decode (part, work);
em_filter_rule_add_action (ff, part);
} else {
- g_warning("cannot find rule part '%s'\n", rulename);
+ g_warning ("cannot find rule part '%s'\n", rulename);
}
xmlFree (rulename);
} else if (work->type == XML_ELEMENT_NODE) {
- g_warning("Unknown xml node in part: %s", work->name);
+ g_warning ("Unknown xml node in part: %s", work->name);
}
work = work->next;
}
@@ -251,7 +251,7 @@ xml_decode (EFilterRule *fr,
work = node->children;
while (work) {
- if (!strcmp((gchar *)work->name, "actionset")) {
+ if (!strcmp ((gchar *) work->name, "actionset")) {
load_set (work, ff, rc);
}
work = work->next;
@@ -405,7 +405,7 @@ less_parts (GtkWidget *button,
if (g_list_length (l) < 2)
return;
- rule = g_object_get_data((GObject *)button, "rule");
+ rule = g_object_get_data ((GObject *) button, "rule");
part_data = g_object_get_data ((GObject *) rule, "data");
g_return_if_fail (part_data != NULL);
@@ -429,17 +429,19 @@ attach_rule (GtkWidget *rule,
{
GtkWidget *remove;
- gtk_table_attach (GTK_TABLE (data->parts), rule, 0, 1, row, row + 1,
- GTK_EXPAND | GTK_FILL, 0, 0, 0);
+ gtk_table_attach (
+ GTK_TABLE (data->parts), rule, 0, 1, row, row + 1,
+ GTK_EXPAND | GTK_FILL, 0, 0, 0);
remove = gtk_button_new_from_stock (GTK_STOCK_REMOVE);
- g_object_set_data((GObject *)remove, "rule", rule);
+ g_object_set_data ((GObject *) remove, "rule", rule);
/*gtk_button_set_relief(GTK_BUTTON(remove), GTK_RELIEF_NONE);*/
g_signal_connect (
remove, "clicked",
G_CALLBACK (less_parts), data);
- gtk_table_attach (GTK_TABLE (data->parts), remove, 1, 2, row, row + 1,
- 0, 0, 0, 0);
+ gtk_table_attach (
+ GTK_TABLE (data->parts), remove, 1, 2, row, row + 1,
+ 0, 0, 0, 0);
gtk_widget_show (remove);
}
@@ -488,7 +490,7 @@ more_parts (GtkWidget *button,
gtk_widget_grab_focus (w);
/* also scroll down to see new part */
- w = (GtkWidget*) g_object_get_data (G_OBJECT (button), "scrolled-window");
+ w = (GtkWidget *) g_object_get_data (G_OBJECT (button), "scrolled-window");
if (w) {
GtkAdjustment *adjustment;
@@ -507,8 +509,8 @@ more_parts (GtkWidget *button,
static void
ensure_scrolled_height_cb (GtkAdjustment *adj,
- GParamSpec *param_spec,
- GtkScrolledWindow *scrolled_window)
+ GParamSpec *param_spec,
+ GtkScrolledWindow *scrolled_window)
{
GtkWidget *toplevel;
GdkScreen *screen;
@@ -578,7 +580,7 @@ get_widget (EFilterRule *fr,
get_widget (fr, rc);
/* and now for the action area */
- msg = g_strdup_printf("<b>%s</b>", _("Then"));
+ msg = g_strdup_printf ("<b>%s</b>", _("Then"));
label = gtk_label_new (msg);
gtk_label_set_use_markup (GTK_LABEL (label), TRUE);
gtk_misc_set_alignment (GTK_MISC (label), 0, 0.5);
@@ -617,7 +619,7 @@ get_widget (EFilterRule *fr,
l = ff->actions;
while (l) {
part = l->data;
- d(printf("adding action %s\n", part->title));
+ d (printf ("adding action %s\n", part->title));
w = get_rule_part_widget ((EMFilterContext *) rc, part, fr);
attach_rule (w, data, part, i++);
l = l->next;
diff --git a/mail/em-filter-source-element.c b/mail/em-filter-source-element.c
index 2d5be7fd52..cdb590564f 100644
--- a/mail/em-filter-source-element.c
+++ b/mail/em-filter-source-element.c
@@ -161,7 +161,7 @@ filter_source_element_xml_encode (EFilterElement *fe)
EMFilterSourceElement *fs = (EMFilterSourceElement *) fe;
value = xmlNewNode (NULL, (const guchar *) "value");
- xmlSetProp (value, (const guchar *) "name", (guchar *)fe->name);
+ xmlSetProp (value, (const guchar *) "name", (guchar *) fe->name);
xmlSetProp (value, (const guchar *) "type", (const guchar *) "uid");
if (fs->priv->active_id != NULL)
@@ -197,7 +197,7 @@ filter_source_element_xml_decode (EFilterElement *fe,
/* For backward-compatibility: We used to store
* sources by their URI string, which can change. */
- if (strcmp ((gchar *)node->name, "uri") == 0) {
+ if (strcmp ((gchar *) node->name, "uri") == 0) {
CamelService *service = NULL;
xmlChar *content;
CamelURL *url;
@@ -255,8 +255,8 @@ filter_source_element_clone (EFilterElement *fe)
static void
filter_source_element_add_to_combo (GtkComboBox *combo_box,
- CamelService *service,
- ESourceRegistry *registry)
+ CamelService *service,
+ ESourceRegistry *registry)
{
ESource *source;
ESourceMailIdentity *extension;
@@ -267,7 +267,8 @@ filter_source_element_add_to_combo (GtkComboBox *combo_box,
const gchar *uid;
gchar *label;
- source = e_source_registry_ref_source (registry,
+ source = e_source_registry_ref_source (
+ registry,
camel_service_get_uid (service));
if (!source)
return;
@@ -313,7 +314,7 @@ filter_source_element_add_to_combo (GtkComboBox *combo_box,
label = g_strdup (display_name);
else
label = g_strdup_printf ("%s (%s)", name ? name : address, display_name);
-
+
} else if (g_strcmp0 (display_name, address) == 0)
label = g_strdup_printf ("%s <%s>", name, address);
else
@@ -354,7 +355,8 @@ filter_source_element_get_widget (EFilterElement *fe)
service = NULL;
- gtk_tree_model_get (model, &iter,
+ gtk_tree_model_get (
+ model, &iter,
E_MAIL_ACCOUNT_STORE_COLUMN_SERVICE, &service,
E_MAIL_ACCOUNT_STORE_COLUMN_ENABLED, &enabled,
E_MAIL_ACCOUNT_STORE_COLUMN_BUILTIN, &builtin,
diff --git a/mail/em-folder-tree.c b/mail/em-folder-tree.c
index ddcfc65c15..0a19e50bad 100644
--- a/mail/em-folder-tree.c
+++ b/mail/em-folder-tree.c
@@ -2005,7 +2005,8 @@ ask_drop_folder (EMFolderTree *folder_tree,
session = em_folder_tree_get_session (folder_tree);
if (!e_mail_folder_uri_parse (CAMEL_SESSION (session),
src_folder_uri, NULL, &src_folder_name, &error)) {
- g_debug ("%s: Failed to convert '%s' to folder name: %s",
+ g_debug (
+ "%s: Failed to convert '%s' to folder name: %s",
G_STRFUNC, src_folder_uri, error ? error->message : "Unknown error");
g_clear_error (&error);
g_object_unref (settings);
@@ -2074,7 +2075,7 @@ folder_tree_drop_folder (struct _DragDataReceivedAsync *m)
data = gtk_selection_data_get_data (m->selection);
- d(printf(" * Drop folder '%s' onto '%s'\n", data, m->full_name));
+ d (printf (" * Drop folder '%s' onto '%s'\n", data, m->full_name));
cancellable = m->base.cancellable;
diff --git a/mail/em-folder-utils.c b/mail/em-folder-utils.c
index cbfd910eed..d689c5c2bc 100644
--- a/mail/em-folder-utils.c
+++ b/mail/em-folder-utils.c
@@ -153,7 +153,7 @@ emft_copy_folders__exec (struct _EMCopyFolders *m,
else
fromlen = tmp - m->frombase + 1;
- d(printf ("top name is '%s'\n", fi->full_name));
+ d (printf ("top name is '%s'\n", fi->full_name));
while (pending) {
CamelFolderInfo *info = pending->data;
@@ -179,17 +179,21 @@ emft_copy_folders__exec (struct _EMCopyFolders *m,
toname, "%s",
info->full_name + fromlen);
- d(printf ("Copying from '%s' to '%s'\n", info->full_name, toname->str));
+ d (printf (
+ "Copying from '%s' to '%s'\n",
+ info->full_name, toname->str));
/* This makes sure we create the same tree,
* e.g. from a nonselectable source. */
/* Not sure if this is really the 'right thing',
* e.g. for spool stores, but it makes the ui work. */
if ((info->flags & CAMEL_FOLDER_NOSELECT) == 0) {
- d(printf ("this folder is selectable\n"));
+ d (printf ("this folder is selectable\n"));
if (m->tostore == m->fromstore && m->delete) {
camel_store_rename_folder_sync (
- m->fromstore, info->full_name, toname->str,
+ m->fromstore,
+ info->full_name,
+ toname->str,
cancellable, error);
if (error && *error)
goto exception;
@@ -258,7 +262,7 @@ emft_copy_folders__exec (struct _EMCopyFolders *m,
while (l) {
CamelFolderInfo *info = l->data;
- d(printf ("deleting folder '%s'\n", info->full_name));
+ d (printf ("deleting folder '%s'\n", info->full_name));
/* FIXME: we need to do something with the exception
* since otherwise the users sees a failed operation
diff --git a/mail/em-utils.c b/mail/em-utils.c
index 17ecdbcae8..4dc130c60b 100644
--- a/mail/em-utils.c
+++ b/mail/em-utils.c
@@ -501,9 +501,9 @@ em_utils_flag_for_followup_clear (GtkWindow *parent,
CamelMessageInfo *mi = camel_folder_get_message_info (folder, uids->pdata[i]);
if (mi) {
- camel_message_info_set_user_tag(mi, "follow-up", NULL);
- camel_message_info_set_user_tag(mi, "due-by", NULL);
- camel_message_info_set_user_tag(mi, "completed-on", NULL);
+ camel_message_info_set_user_tag (mi, "follow-up", NULL);
+ camel_message_info_set_user_tag (mi, "due-by", NULL);
+ camel_message_info_set_user_tag (mi, "completed-on", NULL);
camel_folder_free_message_info (folder, mi);
}
}
@@ -543,9 +543,9 @@ em_utils_flag_for_followup_completed (GtkWindow *parent,
CamelMessageInfo *mi = camel_folder_get_message_info (folder, uids->pdata[i]);
if (mi) {
- tag = camel_message_info_user_tag(mi, "follow-up");
+ tag = camel_message_info_user_tag (mi, "follow-up");
if (tag && tag[0])
- camel_message_info_set_user_tag(mi, "completed-on", now);
+ camel_message_info_set_user_tag (mi, "completed-on", now);
camel_folder_free_message_info (folder, mi);
}
}
@@ -627,7 +627,8 @@ do_print_msg_to_file (GObject *source,
printer = e_mail_printer_new (parts_list);
e_mail_printer_set_export_filename (printer, filename);
- g_signal_connect_swapped (printer, "done",
+ g_signal_connect_swapped (
+ printer, "done",
G_CALLBACK (g_object_unref), printer);
e_mail_printer_print (printer, GTK_PRINT_OPERATION_ACTION_EXPORT, NULL);
@@ -654,8 +655,10 @@ em_utils_print_messages_to_file (CamelFolder *folder,
parser = e_mail_parser_new (session);
- e_mail_parser_parse (parser, folder, uid, message,
- (GAsyncReadyCallback) do_print_msg_to_file, NULL, g_strdup (filename));
+ e_mail_parser_parse (
+ parser, folder, uid, message,
+ (GAsyncReadyCallback) do_print_msg_to_file,
+ NULL, g_strdup (filename));
return TRUE;
}
@@ -991,12 +994,12 @@ em_utils_build_export_filename (CamelFolder *folder,
}
ts = localtime (&reftime);
- strftime(datetmp, 15, "%Y%m%d%H%M%S", ts);
+ strftime (datetmp, 15, "%Y%m%d%H%M%S", ts);
- if (g_ascii_strcasecmp (exporttype, "pdf")==0)
+ if (g_ascii_strcasecmp (exporttype, "pdf") == 0)
file = g_strdup_printf ("%s_%s.pdf", datetmp, camel_message_info_subject (info));
else
- file = g_strdup_printf ("%s_%s", datetmp, camel_message_info_subject(info));
+ file = g_strdup_printf ("%s_%s", datetmp, camel_message_info_subject (info));
}
camel_folder_free_message_info (folder, info);
@@ -1004,8 +1007,8 @@ em_utils_build_export_filename (CamelFolder *folder,
time_t reftime;
reftime = time (NULL);
ts = localtime (&reftime);
- strftime(datetmp, 15, "%Y%m%d%H%M%S", ts);
- if (g_ascii_strcasecmp (exporttype, "pdf")==0)
+ strftime (datetmp, 15, "%Y%m%d%H%M%S", ts);
+ if (g_ascii_strcasecmp (exporttype, "pdf") == 0)
file = g_strdup_printf ("%s_Untitled Message.pdf", datetmp);
else
file = g_strdup_printf ("%s_Untitled Message", datetmp);
@@ -1043,7 +1046,7 @@ em_utils_selection_set_urilist (GtkSelectionData *data,
gchar *exporttype;
gint exportname;
- tmpdir = e_mkdtemp("drag-n-drop-XXXXXX");
+ tmpdir = e_mkdtemp ("drag-n-drop-XXXXXX");
if (tmpdir == NULL)
return;
@@ -1083,7 +1086,7 @@ em_utils_selection_set_urilist (GtkSelectionData *data,
if (em_utils_write_messages_to_stream (folder, uids, fstream) == 0) {
GdkAtom type;
/* terminate with \r\n to be compliant with the spec */
- gchar *uri_crlf = g_strconcat(uri, "\r\n", NULL);
+ gchar *uri_crlf = g_strconcat (uri, "\r\n", NULL);
type = gtk_selection_data_get_target (data);
gtk_selection_data_set (data, type, 8, (guchar *) uri_crlf, strlen (uri_crlf));
@@ -1124,7 +1127,7 @@ em_utils_selection_set_urilist (GtkSelectionData *data,
if (em_utils_print_messages_to_file (folder, uids->pdata[i], filenames[i])) {
/* terminate with \r\n to be compliant with the spec */
uri = g_filename_to_uri (filenames[i], NULL, NULL);
- uris[uris_count++] = g_strconcat(uri, "\r\n", NULL);
+ uris[uris_count++] = g_strconcat (uri, "\r\n", NULL);
g_free (uri);
}
}
@@ -1167,7 +1170,7 @@ em_utils_selection_get_urilist (GtkSelectionData *selection_data,
gint fd, i, res = 0;
gchar **uris;
- d(printf(" * drop uri list\n"));
+ d (printf (" * drop uri list\n"));
uris = gtk_selection_data_get_uris (selection_data);
@@ -1180,7 +1183,7 @@ em_utils_selection_get_urilist (GtkSelectionData *selection_data,
if (url == NULL)
continue;
- if (strcmp(url->protocol, "file") == 0
+ if (strcmp (url->protocol, "file") == 0
&& (fd = g_open (url->path, O_RDONLY | O_BINARY, 0)) != -1) {
stream = camel_stream_fs_new_with_fd (fd);
if (stream) {
@@ -1316,7 +1319,7 @@ em_utils_message_to_html (CamelSession *session,
if (append && *append)
camel_stream_write_string (mem, append, NULL, NULL);
- camel_stream_write(mem, "", 1, NULL, NULL);
+ camel_stream_write (mem, "", 1, NULL, NULL);
g_object_unref (mem);
return (gchar *) g_byte_array_free (buf, FALSE);
@@ -1393,7 +1396,7 @@ em_utils_url_unescape_amp (const gchar *url)
amps = 0;
for (i = 0; url[i]; i++) {
- if (url [i] == '&' && strncmp (url + i, "&amp;", 5) == 0)
+ if (url[i] == '&' && strncmp (url + i, "&amp;", 5) == 0)
amps++;
}
@@ -1405,7 +1408,7 @@ em_utils_url_unescape_amp (const gchar *url)
for (i = 0, j = 0; url[i]; i++, j++) {
buff[j] = url[i];
- if (url [i] == '&' && strncmp (url + i, "&amp;", 5) == 0)
+ if (url[i] == '&' && strncmp (url + i, "&amp;", 5) == 0)
i += 4;
}
buff[j] = 0;
diff --git a/mail/em-vfolder-editor-context.c b/mail/em-vfolder-editor-context.c
index b7c7a490da..31a2c20793 100644
--- a/mail/em-vfolder-editor-context.c
+++ b/mail/em-vfolder-editor-context.c
@@ -138,7 +138,7 @@ vfolder_editor_context_new_element (ERuleContext *context,
return e_filter_option_new ();
if (strcmp (type, "score") == 0)
- return e_filter_int_new_type("score", -3, 3);
+ return e_filter_int_new_type ("score", -3, 3);
if (strcmp (type, "folder") == 0)
return em_filter_editor_folder_element_new (priv->session);
diff --git a/mail/em-vfolder-editor-rule.c b/mail/em-vfolder-editor-rule.c
index 78fbd4624d..6a4cd6c37c 100644
--- a/mail/em-vfolder-editor-rule.c
+++ b/mail/em-vfolder-editor-rule.c
@@ -232,7 +232,7 @@ set_sensitive (struct _source_data *data)
static void
selection_changed_cb (GtkTreeSelection *selection,
- struct _source_data *data)
+ struct _source_data *data)
{
set_sensitive (data);
}
@@ -256,21 +256,22 @@ select_source_with_changed (GtkWidget *widget,
static void
autoupdate_toggled_cb (GtkToggleButton *toggle,
- struct _source_data *data)
+ struct _source_data *data)
{
em_vfolder_rule_set_autoupdate (data->vr, gtk_toggle_button_get_active (toggle));
}
static void
include_subfolders_toggled_cb (GtkCellRendererToggle *cell_renderer,
- const gchar *path_string,
- struct _source_data *data)
+ const gchar *path_string,
+ struct _source_data *data)
{
GtkTreeModel *model;
GtkTreePath *path;
GtkTreeIter iter;
- gtk_cell_renderer_toggle_set_active (cell_renderer,
+ gtk_cell_renderer_toggle_set_active (
+ cell_renderer,
!gtk_cell_renderer_toggle_get_active (cell_renderer));
model = gtk_tree_view_get_model (data->tree_view);
@@ -279,13 +280,15 @@ include_subfolders_toggled_cb (GtkCellRendererToggle *cell_renderer,
if (gtk_tree_model_get_iter (model, &iter, path)) {
gchar *source = NULL;
- gtk_list_store_set (GTK_LIST_STORE (model), &iter,
+ gtk_list_store_set (
+ GTK_LIST_STORE (model), &iter,
2, gtk_cell_renderer_toggle_get_active (cell_renderer),
-1);
gtk_tree_model_get (model, &iter, 1, &source, -1);
if (source) {
- em_vfolder_rule_source_set_include_subfolders (data->vr, source,
+ em_vfolder_rule_source_set_include_subfolders (
+ data->vr, source,
gtk_cell_renderer_toggle_get_active (cell_renderer));
g_free (source);
}
@@ -514,7 +517,8 @@ get_widget (EFilterRule *fr,
tmp = g_strdup_printf ("<b>%s</b>", _("Search Folder Sources"));
label = gtk_label_new (tmp);
g_free (tmp);
- g_object_set (G_OBJECT (label),
+ g_object_set (
+ G_OBJECT (label),
"use-markup", TRUE,
"xalign", 0.0,
NULL);
@@ -529,7 +533,8 @@ get_widget (EFilterRule *fr,
gtk_container_add (GTK_CONTAINER (hgrid), label);
vgrid = gtk_grid_new ();
- g_object_set (G_OBJECT (vgrid),
+ g_object_set (
+ G_OBJECT (vgrid),
"orientation", GTK_ORIENTATION_VERTICAL,
"border-width", 6,
"row-spacing", 6,
@@ -565,7 +570,8 @@ get_widget (EFilterRule *fr,
gtk_container_add (GTK_CONTAINER (vgrid), hgrid);
scrolled_window = gtk_scrolled_window_new (NULL, NULL);
- g_object_set (G_OBJECT (scrolled_window),
+ g_object_set (
+ G_OBJECT (scrolled_window),
"hscrollbar-policy", GTK_POLICY_AUTOMATIC,
"vscrollbar-policy", GTK_POLICY_AUTOMATIC,
"shadow-type", GTK_SHADOW_IN,
@@ -580,7 +586,8 @@ get_widget (EFilterRule *fr,
renderer = gtk_cell_renderer_text_new ();
tree_view = gtk_tree_view_new_with_model (GTK_TREE_MODEL (model));
gtk_tree_view_set_headers_visible (GTK_TREE_VIEW (tree_view), FALSE);
- gtk_tree_view_insert_column_with_attributes (GTK_TREE_VIEW (tree_view),
+ gtk_tree_view_insert_column_with_attributes (
+ GTK_TREE_VIEW (tree_view),
-1, "column", renderer, "markup", 0, NULL);
renderer = gtk_cell_renderer_toggle_new ();
@@ -589,7 +596,8 @@ get_widget (EFilterRule *fr,
g_signal_connect (renderer, "toggled", G_CALLBACK (include_subfolders_toggled_cb), data);
renderer = gtk_cell_renderer_text_new ();
- g_object_set (G_OBJECT (renderer),
+ g_object_set (
+ G_OBJECT (renderer),
"editable", FALSE,
"text", _("include subfolders"),
NULL);
@@ -602,7 +610,8 @@ get_widget (EFilterRule *fr,
gtk_scrolled_window_add_with_viewport (GTK_SCROLLED_WINDOW (scrolled_window), tree_view);
vgrid = gtk_grid_new ();
- g_object_set (G_OBJECT (vgrid),
+ g_object_set (
+ G_OBJECT (vgrid),
"orientation", GTK_ORIENTATION_VERTICAL,
"border-width", 6,
"row-spacing", 6,
@@ -610,11 +619,13 @@ get_widget (EFilterRule *fr,
gtk_container_add (GTK_CONTAINER (hgrid), vgrid);
data->buttons[BUTTON_ADD] = gtk_button_new_from_stock (GTK_STOCK_ADD);
- g_signal_connect (data->buttons[BUTTON_ADD], "clicked",
+ g_signal_connect (
+ data->buttons[BUTTON_ADD], "clicked",
G_CALLBACK (source_add), data);
data->buttons[BUTTON_REMOVE] = gtk_button_new_from_stock (GTK_STOCK_REMOVE);
- g_signal_connect (data->buttons[BUTTON_REMOVE], "clicked",
+ g_signal_connect (
+ data->buttons[BUTTON_REMOVE], "clicked",
G_CALLBACK (source_remove), data);
gtk_container_add (GTK_CONTAINER (vgrid), data->buttons[BUTTON_ADD]);
@@ -633,7 +644,8 @@ get_widget (EFilterRule *fr,
CAMEL_SESSION (session), source, NULL);
gtk_list_store_append (data->model, &iter);
- gtk_list_store_set (data->model, &iter,
+ gtk_list_store_set (
+ data->model, &iter,
0, markup,
1, source,
2, em_vfolder_rule_source_get_include_subfolders (vr, source),
diff --git a/mail/importers/elm-importer.c b/mail/importers/elm-importer.c
index 24db1041e3..5b555cb1c7 100644
--- a/mail/importers/elm-importer.c
+++ b/mail/importers/elm-importer.c
@@ -126,12 +126,12 @@ elm_get_rc (EImport *ei,
GHashTable *prefs;
gchar *elmrc;
- prefs = g_object_get_data((GObject *)ei, "elm-rc");
+ prefs = g_object_get_data ((GObject *) ei, "elm-rc");
if (prefs == NULL) {
- elmrc = g_build_filename(g_get_home_dir(), ".elm/elmrc", NULL);
+ elmrc = g_build_filename (g_get_home_dir (), ".elm/elmrc", NULL);
prefs = parse_elm_rc (elmrc);
g_free (elmrc);
- g_object_set_data((GObject *)ei, "elm-rc", prefs);
+ g_object_set_data ((GObject *) ei, "elm-rc", prefs);
}
if (prefs == NULL)
@@ -152,13 +152,13 @@ elm_supported (EImport *ei,
if (target->type != E_IMPORT_TARGET_HOME)
return FALSE;
- elmdir = g_build_filename(g_get_home_dir (), ".elm", NULL);
+ elmdir = g_build_filename (g_get_home_dir (), ".elm", NULL);
exists = g_file_test (elmdir, G_FILE_TEST_IS_DIR);
g_free (elmdir);
if (!exists)
return FALSE;
- maildir = elm_get_rc(ei, "maildir");
+ maildir = elm_get_rc (ei, "maildir");
if (maildir == NULL)
maildir = "Mail";
@@ -202,7 +202,7 @@ elm_import_exec (struct _elm_import_msg *m,
shell_backend = e_shell_get_backend_by_name (shell, "mail");
session = e_mail_backend_get_session (E_MAIL_BACKEND (shell_backend));
- maildir = elm_get_rc(m->import, "maildir");
+ maildir = elm_get_rc (m->import, "maildir");
if (maildir == NULL)
maildir = "Mail";
@@ -289,7 +289,7 @@ mail_importer_elm_import (EImport *ei,
gint id;
m = mail_msg_new (&elm_import_info);
- g_datalist_set_data(&target->data, "elm-msg", m);
+ g_datalist_set_data (&target->data, "elm-msg", m);
m->import = ei;
g_object_ref (m->import);
m->target = (EImportTargetHome *) target;
@@ -325,11 +325,11 @@ elm_getwidget (EImport *ei,
GtkWidget *box, *w;
g_datalist_set_data (
- &target->data, "elm-do-mail", GINT_TO_POINTER(TRUE));
+ &target->data, "elm-do-mail", GINT_TO_POINTER (TRUE));
box = gtk_vbox_new (FALSE, 2);
- w = gtk_check_button_new_with_label(_("Mail"));
+ w = gtk_check_button_new_with_label (_("Mail"));
gtk_toggle_button_set_active ((GtkToggleButton *) w, TRUE);
g_signal_connect (
w, "toggled",
@@ -346,7 +346,7 @@ elm_import (EImport *ei,
EImportTarget *target,
EImportImporter *im)
{
- if (GPOINTER_TO_INT(g_datalist_get_data(&target->data, "elm-do-mail")))
+ if (GPOINTER_TO_INT (g_datalist_get_data (&target->data, "elm-do-mail")))
mail_importer_elm_import (ei, target);
else
e_import_complete (ei, target);
@@ -357,7 +357,7 @@ elm_cancel (EImport *ei,
EImportTarget *target,
EImportImporter *im)
{
- struct _elm_import_msg *m = g_datalist_get_data(&target->data, "elm-msg");
+ struct _elm_import_msg *m = g_datalist_get_data (&target->data, "elm-msg");
if (m)
g_cancellable_cancel (m->status);
diff --git a/mail/importers/evolution-mbox-importer.c b/mail/importers/evolution-mbox-importer.c
index 24a63c3af0..a024729bc2 100644
--- a/mail/importers/evolution-mbox-importer.c
+++ b/mail/importers/evolution-mbox-importer.c
@@ -184,7 +184,7 @@ mbox_supported (EImport *ei,
if (s->uri_src == NULL)
return TRUE;
- if (strncmp(s->uri_src, "file:///", strlen("file:///")) != 0)
+ if (strncmp (s->uri_src, "file:///", strlen ("file:///")) != 0)
return FALSE;
filename = g_filename_from_uri (s->uri_src, NULL, NULL);
@@ -192,7 +192,7 @@ mbox_supported (EImport *ei,
g_free (filename);
if (fd != -1) {
n = read (fd, signature, 5);
- ret = n == 5 && memcmp(signature, "From ", 5) == 0;
+ ret = n == 5 && memcmp (signature, "From ", 5) == 0;
close (fd);
}
@@ -272,7 +272,7 @@ mbox_import (EImport *ei,
/* TODO: do we validate target? */
importer = g_malloc0 (sizeof (*importer));
- g_datalist_set_data(&target->data, "mbox-data", importer);
+ g_datalist_set_data (&target->data, "mbox-data", importer);
importer->import = ei;
importer->target = target;
importer->status_lock = g_mutex_new ();
@@ -296,7 +296,7 @@ mbox_cancel (EImport *ei,
EImportTarget *target,
EImportImporter *im)
{
- MboxImporter *importer = g_datalist_get_data(&target->data, "mbox-data");
+ MboxImporter *importer = g_datalist_get_data (&target->data, "mbox-data");
if (importer)
g_cancellable_cancel (importer->cancellable);
@@ -407,7 +407,8 @@ mbox_get_preview (EImport *ei,
camel_mime_message_get_from (msg)));
gtk_list_store_append (store, &iter);
- gtk_list_store_set (store, &iter,
+ gtk_list_store_set (
+ store, &iter,
0, camel_mime_message_get_subject (msg) ?
camel_mime_message_get_subject (msg) : "",
1, from ? from : "", 2, msg, -1);
diff --git a/mail/importers/mail-importer.c b/mail/importers/mail-importer.c
index 824d48a444..789a7d3611 100644
--- a/mail/importers/mail-importer.c
+++ b/mail/importers/mail-importer.c
@@ -177,13 +177,13 @@ import_mbox_exec (struct _import_mbox_msg *m,
info = camel_message_info_new (NULL);
- tmp = camel_medium_get_header((CamelMedium *)msg, "X-Mozilla-Status");
+ tmp = camel_medium_get_header ((CamelMedium *) msg, "X-Mozilla-Status");
if (tmp)
flags |= decode_mozilla_status (tmp);
- tmp = camel_medium_get_header((CamelMedium *)msg, "Status");
+ tmp = camel_medium_get_header ((CamelMedium *) msg, "Status");
if (tmp)
flags |= decode_status (tmp);
- tmp = camel_medium_get_header((CamelMedium *)msg, "X-Status");
+ tmp = camel_medium_get_header ((CamelMedium *) msg, "X-Status");
if (tmp)
flags |= decode_status (tmp);
@@ -348,7 +348,7 @@ import_folders_rec (struct _import_folders_data *m,
data_dir, folderparent, folder);
}
- printf("importing to uri %s\n", uri);
+ printf ("importing to uri %s\n", uri);
mail_importer_import_mbox_sync (
m->session, filefull, uri, m->cancellable);
g_free (uri);
@@ -356,7 +356,7 @@ import_folders_rec (struct _import_folders_data *m,
/* This little gem re-uses the stat buffer and filefull
* to automagically scan mozilla-format folders. */
if (!m->elmfmt) {
- gchar *tmp = g_strdup_printf("%s.sbd", filefull);
+ gchar *tmp = g_strdup_printf ("%s.sbd", filefull);
g_free (filefull);
filefull = tmp;
diff --git a/mail/importers/pine-importer.c b/mail/importers/pine-importer.c
index dbcc488f03..664a77bcba 100644
--- a/mail/importers/pine-importer.c
+++ b/mail/importers/pine-importer.c
@@ -71,11 +71,11 @@ pine_supported (EImport *ei,
if (target->type != E_IMPORT_TARGET_HOME)
return FALSE;
- maildir = g_build_filename(g_get_home_dir (), "mail", NULL);
+ maildir = g_build_filename (g_get_home_dir (), "mail", NULL);
md_exists = g_file_test (maildir, G_FILE_TEST_IS_DIR);
g_free (maildir);
- addrfile = g_build_filename(g_get_home_dir (), ".addressbook", NULL);
+ addrfile = g_build_filename (g_get_home_dir (), ".addressbook", NULL);
addr_exists = g_file_test (addrfile, G_FILE_TEST_IS_REGULAR);
g_free (addrfile);
@@ -109,7 +109,7 @@ import_contact (EBookClient *book_client,
GError *error = NULL;
card = e_contact_new ();
- strings = g_strsplit(line, "\t", 5);
+ strings = g_strsplit (line, "\t", 5);
if (strings[0] && strings[1] && strings[2]) {
gchar *new_uid = NULL;
@@ -121,7 +121,7 @@ import_contact (EBookClient *book_client,
if (addr[0] == '(' && addr[len - 1] == ')') {
addr[0] = 0;
addr[len - 1] = 0;
- addrs = g_strsplit(addr+1, ",", 0);
+ addrs = g_strsplit (addr + 1, ",", 0);
list = NULL;
/* XXX So ... this api is just insane ... we set
* plain strings as the contact email if it
@@ -184,14 +184,14 @@ import_contacts (void)
const gchar *extension_name;
GError *error = NULL;
- printf("importing pine addressbook\n");
+ printf ("importing pine addressbook\n");
shell = e_shell_get_default ();
registry = e_shell_get_registry (shell);
extension_name = E_SOURCE_EXTENSION_ADDRESS_BOOK;
- name = g_build_filename(g_get_home_dir(), ".addressbook", NULL);
- fp = fopen(name, "r");
+ name = g_build_filename (g_get_home_dir (), ".addressbook", NULL);
+ fp = fopen (name, "r");
g_free (name);
if (fp == NULL)
return;
@@ -219,7 +219,7 @@ import_contacts (void)
return;
}
- line = g_string_new("");
+ line = g_string_new ("");
g_string_set_size (line, 256);
offset = 0;
while (fgets (line->str + offset, 256, fp)) {
@@ -273,13 +273,13 @@ pine_import_exec (struct _pine_import_msg *m,
shell_backend = e_shell_get_backend_by_name (shell, "mail");
session = e_mail_backend_get_session (E_MAIL_BACKEND (shell_backend));
- if (GPOINTER_TO_INT(g_datalist_get_data(&m->target->data, "pine-do-addr")))
+ if (GPOINTER_TO_INT (g_datalist_get_data (&m->target->data, "pine-do-addr")))
import_contacts ();
- if (GPOINTER_TO_INT(g_datalist_get_data(&m->target->data, "pine-do-mail"))) {
+ if (GPOINTER_TO_INT (g_datalist_get_data (&m->target->data, "pine-do-mail"))) {
gchar *path;
- path = g_build_filename(g_get_home_dir(), "mail", NULL);
+ path = g_build_filename (g_get_home_dir (), "mail", NULL);
mail_importer_import_folders_sync (
session, path, pine_special_folders, 0, m->cancellable);
g_free (path);
@@ -358,7 +358,7 @@ mail_importer_pine_import (EImport *ei,
gint id;
m = mail_msg_new (&pine_import_info);
- g_datalist_set_data(&target->data, "pine-msg", m);
+ g_datalist_set_data (&target->data, "pine-msg", m);
m->import = ei;
g_object_ref (m->import);
m->target = target;
@@ -420,14 +420,14 @@ pine_getwidget (EImport *ei,
box = gtk_vbox_new (FALSE, 2);
- w = gtk_check_button_new_with_label(_("Mail"));
+ w = gtk_check_button_new_with_label (_("Mail"));
gtk_toggle_button_set_active ((GtkToggleButton *) w, TRUE);
g_signal_connect (
w, "toggled",
G_CALLBACK (checkbox_mail_toggle_cb), target);
gtk_box_pack_start ((GtkBox *) box, w, FALSE, FALSE, 0);
- w = gtk_check_button_new_with_label(_("Address Book"));
+ w = gtk_check_button_new_with_label (_("Address Book"));
gtk_toggle_button_set_active ((GtkToggleButton *) w, TRUE);
g_signal_connect (
w, "toggled",
@@ -444,8 +444,8 @@ pine_import (EImport *ei,
EImportTarget *target,
EImportImporter *im)
{
- if (GPOINTER_TO_INT(g_datalist_get_data(&target->data, "pine-do-mail"))
- || GPOINTER_TO_INT(g_datalist_get_data(&target->data, "pine-do-addr")))
+ if (GPOINTER_TO_INT (g_datalist_get_data (&target->data, "pine-do-mail"))
+ || GPOINTER_TO_INT (g_datalist_get_data (&target->data, "pine-do-addr")))
mail_importer_pine_import (ei, target);
else
e_import_complete (ei, target);
@@ -456,7 +456,7 @@ pine_cancel (EImport *ei,
EImportTarget *target,
EImportImporter *im)
{
- struct _pine_import_msg *m = g_datalist_get_data(&target->data, "pine-msg");
+ struct _pine_import_msg *m = g_datalist_get_data (&target->data, "pine-msg");
if (m)
g_cancellable_cancel (m->cancellable);
diff --git a/mail/mail-autofilter.c b/mail/mail-autofilter.c
index f0876a4bdc..5ce81dd001 100644
--- a/mail/mail-autofilter.c
+++ b/mail/mail-autofilter.c
@@ -66,7 +66,7 @@ rule_match_recipients (ERuleContext *context,
part = e_rule_context_create_part (context, "to");
e_filter_rule_add_part ((EFilterRule *) rule, part);
element = e_filter_part_find_element (part, "recipient-type");
- e_filter_option_set_current ((EFilterOption *)element, "contains");
+ e_filter_option_set_current ((EFilterOption *) element, "contains");
element = e_filter_part_find_element (part, "recipient");
e_filter_input_set_value ((EFilterInput *) element, addr);
@@ -119,7 +119,7 @@ rule_add_subject (ERuleContext *context,
part = e_rule_context_create_part (context, "subject");
e_filter_rule_add_part ((EFilterRule *) rule, part);
element = e_filter_part_find_element (part, "subject-type");
- e_filter_option_set_current ((EFilterOption *)element, "contains");
+ e_filter_option_set_current ((EFilterOption *) element, "contains");
element = e_filter_part_find_element (part, "subject");
e_filter_input_set_value ((EFilterInput *) element, text);
}
@@ -138,7 +138,7 @@ rule_add_sender (ERuleContext *context,
part = e_rule_context_create_part (context, "sender");
e_filter_rule_add_part ((EFilterRule *) rule, part);
element = e_filter_part_find_element (part, "sender-type");
- e_filter_option_set_current ((EFilterOption *)element, "contains");
+ e_filter_option_set_current ((EFilterOption *) element, "contains");
element = e_filter_part_find_element (part, "sender");
e_filter_input_set_value ((EFilterInput *) element, text);
}
@@ -200,11 +200,11 @@ rule_match_mlist (ERuleContext *context,
if (mlist[0] == 0)
return;
- part = e_rule_context_create_part(context, "mlist");
+ part = e_rule_context_create_part (context, "mlist");
e_filter_rule_add_part (rule, part);
- element = e_filter_part_find_element(part, "mlist-type");
- e_filter_option_set_current((EFilterOption *)element, "is");
+ element = e_filter_part_find_element (part, "mlist-type");
+ e_filter_option_set_current ((EFilterOption *) element, "is");
element = e_filter_part_find_element (part, "mlist");
e_filter_input_set_value ((EFilterInput *) element, mlist);
@@ -226,7 +226,7 @@ rule_from_address (EFilterRule *rule,
rule_add_sender (context, rule, address);
if (name == NULL || name[0] == '\0')
name = address;
- namestr = g_strdup_printf(_("Mail from %s"), name);
+ namestr = g_strdup_printf (_("Mail from %s"), name);
e_filter_rule_set_name (rule, namestr);
g_free (namestr);
}
@@ -269,7 +269,7 @@ rule_from_message (EFilterRule *rule,
rule_add_sender (context, rule, address);
if (name == NULL || name[0] == '\0')
name = address;
- namestr = g_strdup_printf(_("Mail from %s"), name);
+ namestr = g_strdup_printf (_("Mail from %s"), name);
e_filter_rule_set_name (rule, namestr);
g_free (namestr);
}
@@ -403,7 +403,7 @@ filter_gui_add_from_message (EMailSession *session,
e_filter_rule_set_source (rule, source);
e_rule_context_add_rule_gui (
- (ERuleContext *)fc, rule, _("Add Filter Rule"), user);
+ (ERuleContext *) fc, rule, _("Add Filter Rule"), user);
g_free (user);
g_object_unref (fc);
}
@@ -441,7 +441,7 @@ mail_filter_rename_folder (CamelStore *store,
(ERuleContext *) fc, old_uri, new_uri, g_str_equal);
if (changed) {
if (e_rule_context_save ((ERuleContext *) fc, user) == -1)
- g_warning("Could not write out changed filter rules\n");
+ g_warning ("Could not write out changed filter rules\n");
e_rule_context_free_uri_list ((ERuleContext *) fc, changed);
}
@@ -487,7 +487,7 @@ mail_filter_delete_folder (CamelStore *store,
gchar *info;
GList *l;
- s = g_string_new("");
+ s = g_string_new ("");
s_count = 0;
for (l = deleted; l; l = l->next) {
const gchar *name = (const gchar *) l->data;
diff --git a/mail/mail-send-recv.c b/mail/mail-send-recv.c
index c5d3cd7530..9d55c004fe 100644
--- a/mail/mail-send-recv.c
+++ b/mail/mail-send-recv.c
@@ -266,7 +266,7 @@ dialog_response (GtkDialog *gd,
{
switch (button) {
case GTK_RESPONSE_CANCEL:
- d(printf("cancelled whole thing\n"));
+ d (printf ("cancelled whole thing\n"));
if (!data->cancelled) {
data->cancelled = TRUE;
g_hash_table_foreach (data->active, (GHFunc) cancel_send_info, NULL);
@@ -274,7 +274,7 @@ dialog_response (GtkDialog *gd,
gtk_dialog_set_response_sensitive (gd, GTK_RESPONSE_CANCEL, FALSE);
break;
default:
- d(printf("hiding dialog\n"));
+ d (printf ("hiding dialog\n"));
g_hash_table_foreach (data->active, (GHFunc) hide_send_info, NULL);
data->gd = NULL;
/*gtk_widget_destroy((GtkWidget *)gd);*/
@@ -783,12 +783,12 @@ update_folders (gchar *uri,
{
time_t now = *((time_t *) data);
- d(printf("checking update for folder: %s\n", info->uri));
+ d (printf ("checking update for folder: %s\n", info->uri));
/* let it flow through to the folders every 10 seconds */
/* we back off slowly as we progress */
if (now > info->update + 10 + info->count *5) {
- d(printf("upating a folder: %s\n", info->uri));
+ d (printf ("upating a folder: %s\n", info->uri));
/*camel_folder_thaw(info->folder);
camel_folder_freeze (info->folder);*/
info->update = now;
@@ -810,7 +810,7 @@ receive_status (CamelFilterDriver *driver,
g_hash_table_foreach (info->data->folders, (GHFunc) update_folders, &now);
if (info->data->inbox && now > info->data->inbox_update + 20) {
- d(printf("updating inbox too\n"));
+ d (printf ("updating inbox too\n"));
/* this doesn't seem to work right :( */
/*camel_folder_thaw(info->data->inbox);
camel_folder_freeze (info->data->inbox);*/
@@ -890,7 +890,7 @@ receive_done (gint still_more,
gtk_widget_set_sensitive (info->cancel_button, FALSE);
/* remove/free this active download */
- d(printf("%s: freeing info %p\n", G_STRFUNC, info));
+ d (printf ("%s: freeing info %p\n", G_STRFUNC, info));
if (info->type == SEND_SEND) {
gpointer key = NULL, value = NULL;
if (!g_hash_table_lookup_extended (info->data->active, SEND_URI_KEY, &key, &value))
@@ -1017,7 +1017,7 @@ struct _refresh_folders_msg {
static gchar *
refresh_folders_desc (struct _refresh_folders_msg *m)
{
- return g_strdup_printf(_("Checking for new mail"));
+ return g_strdup_printf (_("Checking for new mail"));
}
static void
@@ -1319,7 +1319,7 @@ mail_receive_service (CamelService *service)
info->cancellable, "status",
G_CALLBACK (operation_status), info);
- d(printf("Adding new info %p\n", info));
+ d (printf ("Adding new info %p\n", info));
g_hash_table_insert (data->active, g_strdup (uid), info);
@@ -1378,12 +1378,12 @@ mail_send (EMailSession *session)
info = g_hash_table_lookup (data->active, SEND_URI_KEY);
if (info != NULL) {
info->again++;
- d(printf("send of %s still in progress\n", transport->url));
+ d (printf ("send of %s still in progress\n", transport->url));
g_object_unref (service);
return;
}
- d(printf("starting non-interactive send of '%s'\n", transport->url));
+ d (printf ("starting non-interactive send of '%s'\n", transport->url));
type = get_receive_type (service);
if (type == SEND_INVALID) {
@@ -1403,7 +1403,7 @@ mail_send (EMailSession *session)
info->state = SEND_ACTIVE;
info->timeout_id = 0;
- d(printf("Adding new info %p\n", info));
+ d (printf ("Adding new info %p\n", info));
g_hash_table_insert (data->active, g_strdup (SEND_URI_KEY), info);
diff --git a/mail/mail-vfolder-ui.c b/mail/mail-vfolder-ui.c
index d9b68ad834..efe086c262 100644
--- a/mail/mail-vfolder-ui.c
+++ b/mail/mail-vfolder-ui.c
@@ -197,7 +197,7 @@ new_rule_clicked (GtkWidget *w,
if (button == GTK_RESPONSE_OK) {
const gchar *config_dir;
gchar *user;
- EFilterRule *rule = g_object_get_data((GObject *)w, "rule");
+ EFilterRule *rule = g_object_get_data ((GObject *) w, "rule");
EAlert *alert = NULL;
if (!e_filter_rule_validate (rule, &alert)) {
@@ -260,8 +260,8 @@ static void
release_rule_notify_cb (gpointer rule)
{
/* disconnect the "changed" signal */
- g_signal_handlers_disconnect_by_data (rule,
- g_object_get_data (rule, "editor-dlg"));
+ g_signal_handlers_disconnect_by_data (
+ rule, g_object_get_data (rule, "editor-dlg"));
g_object_set_data (rule, "editor-dlg", NULL);
g_object_unref (rule);
}
diff --git a/mail/message-list.c b/mail/message-list.c
index 3a6f6efee5..da0be14fea 100644
--- a/mail/message-list.c
+++ b/mail/message-list.c
@@ -146,7 +146,7 @@ static struct {
GdkAtom atom;
guint32 actions;
} ml_drag_info[] = {
- { "x-uid-list", NULL, GDK_ACTION_MOVE|GDK_ACTION_COPY },
+ { "x-uid-list", NULL, GDK_ACTION_MOVE | GDK_ACTION_COPY },
{ "message/rfc822", NULL, GDK_ACTION_COPY },
{ "text/uri-list", NULL, GDK_ACTION_COPY },
};
@@ -1029,9 +1029,10 @@ message_list_copy (MessageList *ml,
void
message_list_paste (MessageList *ml)
{
- gtk_selection_convert (ml->priv->invisible, GDK_SELECTION_CLIPBOARD,
- gdk_atom_intern ("x-uid-list", FALSE),
- GDK_CURRENT_TIME);
+ gtk_selection_convert (
+ ml->priv->invisible, GDK_SELECTION_CLIPBOARD,
+ gdk_atom_intern ("x-uid-list", FALSE),
+ GDK_CURRENT_TIME);
}
/*
@@ -1065,7 +1066,7 @@ ml_get_save_id (ETreeModel *etm,
CamelMessageInfo *info;
if (e_tree_model_node_is_root (etm, path))
- return g_strdup("root");
+ return g_strdup ("root");
/* Note: etable can ask for the save_id while we're clearing it,
* which is the only time data should be null */
@@ -1302,7 +1303,7 @@ ml_value_to_string (ETreeModel *etm,
case COL_DELETED:
case COL_UNREAD:
case COL_FOLLOWUP_FLAG_STATUS:
- return g_strdup_printf ("%u", GPOINTER_TO_UINT(value));
+ return g_strdup_printf ("%u", GPOINTER_TO_UINT (value));
case COL_SENT:
case COL_RECEIVED:
@@ -1429,7 +1430,7 @@ sanitize_recipients (const gchar *string)
quoted = ~quoted;
else if (c == ',' && !quoted) {
single_add = g_string_free (gstring, FALSE);
- name = g_strsplit(single_add,"<",2);
+ name = g_strsplit (single_add,"<",2);
g_string_append (recipients, *name);
g_string_append (recipients, ",");
g_free (single_add);
@@ -1442,7 +1443,7 @@ sanitize_recipients (const gchar *string)
}
single_add = g_string_free (gstring, FALSE);
- name = g_strsplit(single_add,"<",2);
+ name = g_strsplit (single_add,"<",2);
g_string_append (recipients, *name);
g_free (single_add);
g_strfreev (name);
@@ -1462,7 +1463,8 @@ add_label_if_known (struct LabelsData *ld,
GtkTreeIter label_defn;
if (e_mail_label_list_store_lookup (ld->store, tag, &label_defn)) {
- g_hash_table_insert (ld->labels_tag2iter,
+ g_hash_table_insert (
+ ld->labels_tag2iter,
/* Should be the same as the "tag" arg */
e_mail_label_list_store_get_tag (ld->store, &label_defn),
gtk_tree_iter_copy (&label_defn));
@@ -1596,7 +1598,7 @@ ml_tree_value_at_ex (ETreeModel *etm,
const gchar *tag;
gint score = 0;
- tag = camel_message_info_user_tag(msg_info, "score");
+ tag = camel_message_info_user_tag (msg_info, "score");
if (tag)
score = atoi (tag);
@@ -1607,8 +1609,8 @@ ml_tree_value_at_ex (ETreeModel *etm,
/* FIXME: this all should be methods off of message-tag-followup class,
* FIXME: the tag names should be namespaced :( */
- tag = camel_message_info_user_tag(msg_info, "follow-up");
- cmp = camel_message_info_user_tag(msg_info, "completed-on");
+ tag = camel_message_info_user_tag (msg_info, "follow-up");
+ cmp = camel_message_info_user_tag (msg_info, "completed-on");
if (tag && tag[0]) {
if (cmp && cmp[0])
return GINT_TO_POINTER (2);
@@ -1621,7 +1623,7 @@ ml_tree_value_at_ex (ETreeModel *etm,
const gchar *tag;
time_t due_by;
- tag = camel_message_info_user_tag(msg_info, "due-by");
+ tag = camel_message_info_user_tag (msg_info, "due-by");
if (tag && *tag) {
due_by = camel_header_decode_date (tag, NULL);
return GINT_TO_POINTER (due_by);
@@ -1630,7 +1632,7 @@ ml_tree_value_at_ex (ETreeModel *etm,
}
}
case COL_FOLLOWUP_FLAG:
- str = camel_message_info_user_tag(msg_info, "follow-up");
+ str = camel_message_info_user_tag (msg_info, "follow-up");
return (gpointer)(str ? str : "");
case COL_ATTACHMENT:
if (camel_message_info_user_flag (msg_info, "$has_cal"))
@@ -1694,9 +1696,9 @@ ml_tree_value_at_ex (ETreeModel *etm,
Don't say that I need to have the new labels[with subject] column visible always */
colour = NULL;
- due_by = camel_message_info_user_tag(msg_info, "due-by");
- completed = camel_message_info_user_tag(msg_info, "completed-on");
- followup = camel_message_info_user_tag(msg_info, "follow-up");
+ due_by = camel_message_info_user_tag (msg_info, "due-by");
+ completed = camel_message_info_user_tag (msg_info, "completed-on");
+ followup = camel_message_info_user_tag (msg_info, "follow-up");
if (colour == NULL) {
/* Get all applicable labels. */
struct LabelsData ld;
@@ -1975,16 +1977,18 @@ static ECell * create_composite_cell (gint col)
cell_date = e_cell_date_new (NULL, GTK_JUSTIFY_RIGHT);
e_cell_date_set_format_component (E_CELL_DATE (cell_date), "mail");
- g_object_set (cell_date,
- "bold_column", COL_UNREAD,
- "color_column", COL_COLOUR,
- NULL);
+ g_object_set (
+ cell_date,
+ "bold_column", COL_UNREAD,
+ "color_column", COL_COLOUR,
+ NULL);
cell_from = e_cell_text_new (NULL, GTK_JUSTIFY_LEFT);
- g_object_set (cell_from,
- "bold_column", COL_UNREAD,
- "color_column", COL_COLOUR,
- NULL);
+ g_object_set (
+ cell_from,
+ "bold_column", COL_UNREAD,
+ "color_column", COL_COLOUR,
+ NULL);
e_cell_hbox_append (E_CELL_HBOX (cell_hbox), cell_from, show_email ? col : alt_col, 68);
e_cell_hbox_append (E_CELL_HBOX (cell_hbox), cell_attach, COL_ATTACHMENT, 5);
@@ -1994,9 +1998,10 @@ static ECell * create_composite_cell (gint col)
g_object_unref (cell_date);
cell_sub = e_cell_text_new (fixed_name? fixed_name : NULL, GTK_JUSTIFY_LEFT);
- g_object_set (cell_sub,
- "color_column", COL_COLOUR,
- NULL);
+ g_object_set (
+ cell_sub,
+ "color_column", COL_COLOUR,
+ NULL);
cell_tree = e_cell_tree_new (TRUE, cell_sub);
e_cell_vbox_append (E_CELL_VBOX (cell_vbox), cell_hbox, COL_FROM);
e_cell_vbox_append (E_CELL_VBOX (cell_vbox), cell_tree, COL_SUBJECT);
@@ -2017,8 +2022,8 @@ static void
composite_cell_set_strike_col (ECell *cell,
gint col)
{
- g_object_set (g_object_get_data(G_OBJECT (cell), "cell_date"), "strikeout_column", col, NULL);
- g_object_set (g_object_get_data(G_OBJECT (cell), "cell_from"), "strikeout_column", col, NULL);
+ g_object_set (g_object_get_data (G_OBJECT (cell), "cell_date"), "strikeout_column", col, NULL);
+ g_object_set (g_object_get_data (G_OBJECT (cell), "cell_from"), "strikeout_column", col, NULL);
}
static ETableExtras *
@@ -2064,19 +2069,21 @@ message_list_create_extras (void)
/* date cell */
cell = e_cell_date_new (NULL, GTK_JUSTIFY_LEFT);
e_cell_date_set_format_component (E_CELL_DATE (cell), "mail");
- g_object_set (cell,
- "bold_column", COL_UNREAD,
- "color_column", COL_COLOUR,
- NULL);
+ g_object_set (
+ cell,
+ "bold_column", COL_UNREAD,
+ "color_column", COL_COLOUR,
+ NULL);
e_table_extras_add_cell (extras, "render_date", cell);
g_object_unref (cell);
/* text cell */
cell = e_cell_text_new (NULL, GTK_JUSTIFY_LEFT);
- g_object_set (cell,
- "bold_column", COL_UNREAD,
- "color_column", COL_COLOUR,
- NULL);
+ g_object_set (
+ cell,
+ "bold_column", COL_UNREAD,
+ "color_column", COL_COLOUR,
+ NULL);
e_table_extras_add_cell (extras, "render_text", cell);
g_object_unref (cell);
@@ -2086,10 +2093,11 @@ message_list_create_extras (void)
/* size cell */
cell = e_cell_size_new (NULL, GTK_JUSTIFY_RIGHT);
- g_object_set (cell,
- "bold_column", COL_UNREAD,
- "color_column", COL_COLOUR,
- NULL);
+ g_object_set (
+ cell,
+ "bold_column", COL_UNREAD,
+ "color_column", COL_COLOUR,
+ NULL);
e_table_extras_add_cell (extras, "render_size", cell);
g_object_unref (cell);
@@ -2187,11 +2195,11 @@ ml_selection_get (GtkWidget *widget,
if (info & 2) {
/* text/plain */
- d(printf("setting text/plain selection for uids\n"));
+ d (printf ("setting text/plain selection for uids\n"));
em_utils_selection_set_mailbox (data, selection->folder, selection->uids);
} else {
/* x-uid-list */
- d(printf("setting x-uid-list selection for uids\n"));
+ d (printf ("setting x-uid-list selection for uids\n"));
em_utils_selection_set_uidlist (data, selection->folder, selection->uids);
}
}
@@ -2220,7 +2228,7 @@ ml_selection_received (GtkWidget *widget,
target = gtk_selection_data_get_target (selection_data);
if (target != gdk_atom_intern ("x-uid-list", FALSE)) {
- d(printf("Unknown selection received by message-list\n"));
+ d (printf ("Unknown selection received by message-list\n"));
return;
}
@@ -2290,9 +2298,9 @@ ml_drop_async_desc (struct _drop_msg *m)
full_name = camel_folder_get_full_name (m->folder);
if (m->move)
- return g_strdup_printf(_("Moving messages into folder %s"), full_name);
+ return g_strdup_printf (_("Moving messages into folder %s"), full_name);
else
- return g_strdup_printf(_("Copying messages into folder %s"), full_name);
+ return g_strdup_printf (_("Copying messages into folder %s"), full_name);
}
static void
@@ -2490,14 +2498,14 @@ ml_tree_drag_motion (ETree *tree,
while (targets != NULL) {
gint i;
- d(printf("atom drop '%s'\n", gdk_atom_name(targets->data)));
+ d (printf ("atom drop '%s'\n", gdk_atom_name (targets->data)));
for (i = 0; i < G_N_ELEMENTS (ml_drag_info); i++)
if (targets->data == (gpointer) ml_drag_info[i].atom)
actions |= ml_drag_info[i].actions;
targets = g_list_next (targets);
}
- d(printf("\n"));
+ d (printf ("\n"));
actions &= gdk_drag_context_get_actions (context);
action = gdk_drag_context_get_suggested_action (context);
@@ -2810,25 +2818,26 @@ message_list_class_init (MessageListClass *class)
G_PARAM_READWRITE |
G_PARAM_CONSTRUCT_ONLY));
- message_list_signals[MESSAGE_SELECTED] =
- g_signal_new ("message_selected",
- MESSAGE_LIST_TYPE,
- G_SIGNAL_RUN_LAST,
- G_STRUCT_OFFSET (MessageListClass, message_selected),
- NULL,
- NULL,
- g_cclosure_marshal_VOID__STRING,
- G_TYPE_NONE, 1, G_TYPE_STRING);
-
- message_list_signals[MESSAGE_LIST_BUILT] =
- g_signal_new ("message_list_built",
- MESSAGE_LIST_TYPE,
- G_SIGNAL_RUN_LAST,
- G_STRUCT_OFFSET (MessageListClass, message_list_built),
- NULL,
- NULL,
- g_cclosure_marshal_VOID__VOID,
- G_TYPE_NONE, 0);
+ message_list_signals[MESSAGE_SELECTED] = g_signal_new (
+ "message_selected",
+ MESSAGE_LIST_TYPE,
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET (MessageListClass, message_selected),
+ NULL,
+ NULL,
+ g_cclosure_marshal_VOID__STRING,
+ G_TYPE_NONE, 1,
+ G_TYPE_STRING);
+
+ message_list_signals[MESSAGE_LIST_BUILT] = g_signal_new (
+ "message_list_built",
+ MESSAGE_LIST_TYPE,
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET (MessageListClass, message_list_built),
+ NULL,
+ NULL,
+ g_cclosure_marshal_VOID__VOID,
+ G_TYPE_NONE, 0);
}
static void
@@ -2847,28 +2856,29 @@ message_list_construct (MessageList *message_list)
GSettings *settings;
message_list->model =
- e_tree_memory_callbacks_new (ml_tree_icon_at,
+ e_tree_memory_callbacks_new (
+ ml_tree_icon_at,
- ml_column_count,
+ ml_column_count,
- ml_has_save_id,
- ml_get_save_id,
+ ml_has_save_id,
+ ml_get_save_id,
- ml_has_get_node_by_id,
- ml_get_node_by_id,
+ ml_has_get_node_by_id,
+ ml_get_node_by_id,
- ml_tree_sort_value_at,
- ml_tree_value_at,
- ml_tree_set_value_at,
- ml_tree_is_cell_editable,
+ ml_tree_sort_value_at,
+ ml_tree_value_at,
+ ml_tree_set_value_at,
+ ml_tree_is_cell_editable,
- ml_duplicate_value,
- ml_free_value,
- ml_initialize_value,
- ml_value_is_empty,
- ml_value_to_string,
+ ml_duplicate_value,
+ ml_free_value,
+ ml_initialize_value,
+ ml_value_is_empty,
+ ml_value_to_string,
- message_list);
+ message_list);
settings = g_settings_new ("org.gnome.evolution.mail");
e_tree_memory_set_expanded_default (
@@ -2894,7 +2904,7 @@ message_list_construct (MessageList *message_list)
if (atk_get_root () != NULL) {
a11y = gtk_widget_get_accessible (GTK_WIDGET (message_list));
- atk_object_set_name(a11y, _("Messages"));
+ atk_object_set_name (a11y, _("Messages"));
}
g_signal_connect (
@@ -2995,7 +3005,7 @@ clear_tree (MessageList *ml,
struct timeval start, end;
gulong diff;
- printf("Clearing tree\n");
+ printf ("Clearing tree\n");
gettimeofday (&start, NULL);
#endif
@@ -3022,7 +3032,7 @@ clear_tree (MessageList *ml,
gettimeofday (&end, NULL);
diff = end.tv_sec * 1000 + end.tv_usec / 1000;
diff -= start.tv_sec * 1000 + start.tv_usec / 1000;
- printf("Clearing tree took %ld.%03ld seconds\n", diff / 1000, diff % 1000);
+ printf ("Clearing tree took %ld.%03ld seconds\n", diff / 1000, diff % 1000);
#endif
}
@@ -3239,7 +3249,7 @@ build_tree (MessageList *ml,
struct timeval start, end;
gulong diff;
- printf("Building tree\n");
+ printf ("Building tree\n");
gettimeofday (&start, NULL);
#endif
@@ -3247,7 +3257,7 @@ build_tree (MessageList *ml,
gettimeofday (&end, NULL);
diff = end.tv_sec * 1000 + end.tv_usec / 1000;
diff -= start.tv_sec * 1000 + start.tv_usec / 1000;
- printf("Loading tree state took %ld.%03ld seconds\n", diff / 1000, diff % 1000);
+ printf ("Loading tree state took %ld.%03ld seconds\n", diff / 1000, diff % 1000);
#endif
if (ml->tree_root == NULL) {
@@ -3315,7 +3325,7 @@ build_tree (MessageList *ml,
gettimeofday (&end, NULL);
diff = end.tv_sec * 1000 + end.tv_usec / 1000;
diff -= start.tv_sec * 1000 + start.tv_usec / 1000;
- printf("Building tree took %ld.%03ld seconds\n", diff / 1000, diff % 1000);
+ printf ("Building tree took %ld.%03ld seconds\n", diff / 1000, diff % 1000);
#endif
}
@@ -3334,7 +3344,7 @@ build_subtree (MessageList *ml,
while (c) {
/* phantom nodes no longer allowed */
if (!c->message) {
- g_warning("c->message shouldn't be NULL\n");
+ g_warning ("c->message shouldn't be NULL\n");
c = c->next;
continue;
}
@@ -3377,10 +3387,10 @@ tree_equal (ETreeModel *etm,
while (ap && bp) {
if (!node_equal (etm, ap, bp)) {
- g_warning("Nodes in tree differ");
+ g_warning ("Nodes in tree differ");
info = e_tree_memory_node_get_data (E_TREE_MEMORY (etm), ap);
- printf("table uid = %s\n", camel_message_info_uid(info));
- printf("camel uid = %s\n", camel_message_info_uid(bp->message));
+ printf ("table uid = %s\n", camel_message_info_uid (info));
+ printf ("camel uid = %s\n", camel_message_info_uid (bp->message));
return FALSE;
} else {
if (!tree_equal (etm, e_tree_model_node_get_first_child (etm, ap), bp->child))
@@ -3391,16 +3401,16 @@ tree_equal (ETreeModel *etm,
}
if (ap || bp) {
- g_warning("Tree differs, out of nodes in one branch");
+ g_warning ("Tree differs, out of nodes in one branch");
if (ap) {
info = e_tree_memory_node_get_data (E_TREE_MEMORY (etm), ap);
if (info)
- printf("table uid = %s\n", camel_message_info_uid(info));
+ printf ("table uid = %s\n", camel_message_info_uid (info));
else
- printf("info is empty?\n");
+ printf ("info is empty?\n");
}
if (bp) {
- printf("camel uid = %s\n", camel_message_info_uid(bp->message));
+ printf ("camel uid = %s\n", camel_message_info_uid (bp->message));
return FALSE;
}
return FALSE;
@@ -3446,7 +3456,7 @@ remove_node_diff (MessageList *ml,
ETreePath cp, cn;
CamelMessageInfo *info;
- t(printf("Removing node: %s\n", (gchar *)e_tree_memory_node_get_data(etm, node)));
+ t (printf ("Removing node: %s\n", (gchar *) e_tree_memory_node_get_data (etm, node)));
/* we depth-first remove all node data's ... */
cp = e_tree_model_node_get_first_child (etm, node);
@@ -3485,15 +3495,15 @@ build_subtree_diff (MessageList *ml,
bp = c;
while (ap || bp) {
- t(printf("Processing row: %d (subtree row %d)\n", *row, myrow));
+ t (printf ("Processing row: %d (subtree row %d)\n", *row, myrow));
if (ap == NULL) {
- t(printf("out of old nodes\n"));
+ t (printf ("out of old nodes\n"));
/* ran out of old nodes - remaining nodes are added */
add_node_diff (ml, parent, ap, bp, row, myrow);
myrow++;
bp = bp->next;
} else if (bp == NULL) {
- t(printf("out of new nodes\n"));
+ t (printf ("out of new nodes\n"));
/* ran out of new nodes - remaining nodes are removed */
tmp = e_tree_model_node_get_next (etm, ap);
remove_node_diff (ml, ap, 0);
@@ -3510,7 +3520,7 @@ build_subtree_diff (MessageList *ml,
g_hash_table_insert (ml->uid_rowmap, olduid, (gpointer)(*row));
}
} else {
- g_warning("Cannot find uid %s in table?", camel_message_info_uid(bp->message));
+ g_warning ("Cannot find uid %s in table?", camel_message_info_uid (bp->message));
}
}
#endif
@@ -3524,7 +3534,7 @@ build_subtree_diff (MessageList *ml,
ap = e_tree_model_node_get_next (etm, ap);
bp = bp->next;
} else {
- t(printf("searching for matches\n"));
+ t (printf ("searching for matches\n"));
/* we have to scan each side for a match */
bi = bp->next;
ai = e_tree_model_node_get_next (etm, ap);
@@ -3541,14 +3551,14 @@ build_subtree_diff (MessageList *ml,
if (bi) {
bt = bp;
while (bt != bi) {
- t(printf("adding new node 0\n"));
+ t (printf ("adding new node 0\n"));
add_node_diff (ml, parent, NULL, bt, row, myrow);
myrow++;
bt = bt->next;
}
bp = bi;
} else {
- t(printf("adding new node 1\n"));
+ t (printf ("adding new node 1\n"));
/* no match in new nodes, add one, try next */
add_node_diff (ml, parent, NULL, bp, row, myrow);
myrow++;
@@ -3559,14 +3569,14 @@ build_subtree_diff (MessageList *ml,
if (ai) {
at = ap;
while (at != ai) {
- t(printf("removing old node 0\n"));
+ t (printf ("removing old node 0\n"));
tmp = e_tree_model_node_get_next (etm, at);
remove_node_diff (ml, at, 0);
at = tmp;
}
ap = ai;
} else {
- t(printf("adding new node 2\n"));
+ t (printf ("adding new node 2\n"));
/* didn't find match in old nodes, must be new node? */
add_node_diff (ml, parent, NULL, bp, row, myrow);
myrow++;
@@ -3601,7 +3611,7 @@ build_flat (MessageList *ml,
struct timeval start, end;
gulong diff;
- printf("Building flat\n");
+ printf ("Building flat\n");
gettimeofday (&start, NULL);
#endif
@@ -3646,7 +3656,7 @@ build_flat (MessageList *ml,
gettimeofday (&end, NULL);
diff = end.tv_sec * 1000 + end.tv_usec / 1000;
diff -= start.tv_sec * 1000 + start.tv_usec / 1000;
- printf("Building flat took %ld.%03ld seconds\n", diff / 1000, diff % 1000);
+ printf ("Building flat took %ld.%03ld seconds\n", diff / 1000, diff % 1000);
#endif
}
@@ -3685,10 +3695,10 @@ build_flat_diff (MessageList *ml,
gettimeofday (&start, NULL);
#endif
- d(printf("updating changes to display\n"));
+ d (printf ("updating changes to display\n"));
/* remove individual nodes? */
- d(printf("Removing messages from view:\n"));
+ d (printf ("Removing messages from view:\n"));
for (i = 0; i < changes->uid_removed->len; i++) {
node = g_hash_table_lookup (ml->uid_nodemap, changes->uid_removed->pdata[i]);
if (node) {
@@ -3699,17 +3709,17 @@ build_flat_diff (MessageList *ml,
}
/* add new nodes? - just append to the end */
- d(printf("Adding messages to view:\n"));
+ d (printf ("Adding messages to view:\n"));
for (i = 0; i < changes->uid_added->len; i++) {
info = camel_folder_get_message_info (ml->folder, changes->uid_added->pdata[i]);
if (info) {
- d(printf(" %s\n", (gchar *)changes->uid_added->pdata[i]));
+ d (printf (" %s\n", (gchar *) changes->uid_added->pdata[i]));
ml_uid_nodemap_insert (ml, info, NULL, -1);
}
}
/* and update changes too */
- d(printf("Changing messages to view:\n"));
+ d (printf ("Changing messages to view:\n"));
for (i = 0; i < changes->uid_changed->len; i++) {
ETreePath *node = g_hash_table_lookup (ml->uid_nodemap, changes->uid_changed->pdata[i]);
if (node) {
@@ -3724,7 +3734,7 @@ build_flat_diff (MessageList *ml,
gettimeofday (&end, NULL);
diff = end.tv_sec * 1000 + end.tv_usec / 1000;
diff -= start.tv_sec * 1000 + start.tv_usec / 1000;
- printf("Inserting changes took %ld.%03ld seconds\n", diff / 1000, diff % 1000);
+ printf ("Inserting changes took %ld.%03ld seconds\n", diff / 1000, diff % 1000);
#endif
}
@@ -3792,11 +3802,8 @@ folder_changed (CamelFolder *folder,
if (ml->priv->destroyed)
return;
- d(printf("folder changed event, changes = %p\n", changes));
+ d (printf ("folder changed event, changes = %p\n", changes));
if (changes) {
- d(printf("changed = %d added = %d removed = %d\n",
- changes->uid_changed->len, changes->uid_added->len, changes->uid_removed->len));
-
for (i = 0; i < changes->uid_removed->len; i++)
g_hash_table_remove (
ml->normalised_hash,
@@ -3998,7 +4005,7 @@ on_cursor_activated_idle (gpointer data)
selected = e_selection_model_selected_count (esm);
if (selected == 1 && message_list->cursor_uid) {
- d(printf ("emitting cursor changed signal, for uid %s\n", message_list->cursor_uid));
+ d (printf ("emitting cursor changed signal, for uid %s\n", message_list->cursor_uid));
g_signal_emit (message_list, message_list_signals[MESSAGE_SELECTED], 0, message_list->cursor_uid);
} else {
g_signal_emit (message_list, message_list_signals[MESSAGE_SELECTED], 0, NULL);
@@ -4037,8 +4044,9 @@ on_cursor_activated_cmd (ETree *tree,
if (!message_list->idle_id) {
message_list->idle_id =
- g_idle_add_full (G_PRIORITY_LOW, on_cursor_activated_idle,
- message_list, NULL);
+ g_idle_add_full (
+ G_PRIORITY_LOW, on_cursor_activated_idle,
+ message_list, NULL);
}
}
@@ -4652,13 +4660,13 @@ regen_list_exec (struct _regen_list_msg *m,
if (m->hidejunk) {
if (m->search) {
expr = g_alloca (strlen (m->search) + 92);
- sprintf(expr, "(and (match-all (and (not (system-flag \"deleted\")) (not (system-flag \"junk\"))))\n %s)", m->search);
+ sprintf (expr, "(and (match-all (and (not (system-flag \"deleted\")) (not (system-flag \"junk\"))))\n %s)", m->search);
} else
expr = (gchar *) "(match-all (and (not (system-flag \"deleted\")) (not (system-flag \"junk\"))))";
} else {
if (m->search) {
expr = g_alloca (strlen (m->search) + 64);
- sprintf(expr, "(and (match-all (not (system-flag \"deleted\")))\n %s)", m->search);
+ sprintf (expr, "(and (match-all (not (system-flag \"deleted\")))\n %s)", m->search);
} else
expr = (gchar *) "(match-all (not (system-flag \"deleted\")))";
}
@@ -4666,7 +4674,7 @@ regen_list_exec (struct _regen_list_msg *m,
if (m->hidejunk) {
if (m->search) {
expr = g_alloca (strlen (m->search) + 64);
- sprintf(expr, "(and (match-all (not (system-flag \"junk\")))\n %s)", m->search);
+ sprintf (expr, "(and (match-all (not (system-flag \"junk\")))\n %s)", m->search);
} else
expr = (gchar *) "(match-all (not (system-flag \"junk\")))";
} else {