From 231f9bdddd5e4dd3106cb1cbe8572ee3c9c6bdb3 Mon Sep 17 00:00:00 2001 From: morioka Date: Sat, 13 Jun 1998 12:12:55 +0000 Subject: [PATCH] (mime-entity-situation): Add information of Content-Disposition. --- mime-view.el | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/mime-view.el b/mime-view.el index 1437691..04ddfe3 100644 --- a/mime-view.el +++ b/mime-view.el @@ -210,10 +210,30 @@ If optional argument MESSAGE-INFO is not specified, (set-buffer (mime-entity-buffer entity)) mime-raw-message-info)))) -(defsubst mime-entity-situation (entity) +(defun mime-entity-situation (entity) "Return situation of ENTITY." (append (or (mime-entity-content-type entity) (make-mime-content-type 'text 'plain)) + (let ((d (mime-entity-content-disposition entity))) + (cons (cons 'disposition-type + (mime-content-disposition-type d)) + (mapcar (function + (lambda (param) + (let ((name (car param))) + (cons (cond ((string= name "filename") + 'filename) + ((string= name "creation-date") + 'creation-date) + ((string= name "modification-date") + 'modification-date) + ((string= name "read-date") + 'read-date) + ((string= name "size") + 'size) + (t (cons 'disposition (car param)))) + (cdr param))))) + (mime-content-disposition-parameters d)) + )) (list (cons 'encoding (mime-entity-encoding entity)) (cons 'major-mode (save-excursion -- 1.7.10.4