From 3a08341e504d7f9b27f8a67a2fed223a38edb706 Mon Sep 17 00:00:00 2001 From: Austin Clements Date: Thu, 2 Aug 2012 21:14:52 -0400 Subject: show: Feed the sprinter down to part formatters There are several levels of function calls between where we create the sprinter and the call to the part formatter in show_message. This feeds the sprinter through all of them and into the part formatters. --- notmuch-client.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'notmuch-client.h') diff --git a/notmuch-client.h b/notmuch-client.h index bbc0a114..112574c7 100644 --- a/notmuch-client.h +++ b/notmuch-client.h @@ -66,12 +66,13 @@ typedef GMimeCipherContext notmuch_crypto_context_t; #define STRINGIFY_(s) #s typedef struct mime_node mime_node_t; +struct sprinter; struct notmuch_show_params; typedef struct notmuch_show_format { struct sprinter *(*new_sprinter) (const void *ctx, FILE *stream); const char *message_set_start; - notmuch_status_t (*part) (const void *ctx, + notmuch_status_t (*part) (const void *ctx, struct sprinter *sprinter, struct mime_node *node, int indent, const struct notmuch_show_params *params); const char *message_set_sep; @@ -178,7 +179,8 @@ notmuch_status_t show_one_part (const char *filename, int part); void -format_part_json (const void *ctx, mime_node_t *node, notmuch_bool_t first, notmuch_bool_t output_body); +format_part_json (const void *ctx, struct sprinter *sp, mime_node_t *node, + notmuch_bool_t first, notmuch_bool_t output_body); void format_headers_json (const void *ctx, GMimeMessage *message, notmuch_bool_t reply); -- cgit v1.2.3