* mu-msg-part: add mu_msg_part_save_temp and some refactoring

This commit is contained in:
djcb
2012-01-15 14:10:04 +02:00
parent 6e3e425c66
commit c2b5e95dae
2 changed files with 60 additions and 17 deletions

View File

@ -120,6 +120,21 @@ gboolean mu_msg_part_save (MuMsg *msg, const char *filepath, guint partidx,
gboolean overwrite, gboolean use_cached, GError **err);
/**
* save a message part to a temporary file and return the full path to
* this file
*
* @param msg a MuMsg message
* @param partidx index of the part to save
* @param err receives error information if any
*
* @return the full path to the temp file, or NULL in case of error
*/
gchar* mu_msg_part_save_temp (MuMsg *msg, guint partidx, GError **err);
/**
* get a filename for the saving the message part; try the filename
* specified for the message part if any, otherwise determine a unique