;;; @ content decoder
;;;
-(defvar mime-preview/after-decoded-position nil)
+(defvar mime-preview-after-decoded-position nil)
-(defun mime-view-play-current-entity (&optional mode)
+(defun mime-preview-play-current-entity (&optional mode)
"Play current entity.
It decodes current entity to call internal or external method. The
method is selected from variable `mime-acting-condition'.
(let ((the-buf (current-buffer))
(raw-buffer (get-text-property (point) 'mime-view-raw-buffer))
)
- (setq mime-preview/after-decoded-position (point))
+ (setq mime-preview-after-decoded-position (point))
(set-buffer raw-buffer)
(mime-playback-entity cinfo mode)
(if (eq (current-buffer) raw-buffer)
(progn
(set-buffer the-buf)
- (goto-char mime-preview/after-decoded-position)
+ (goto-char mime-preview-after-decoded-position)
))
))))
(defun mime-playback-entity (cinfo &optional mode)
(let ((beg (mime-entity-info-point-min cinfo))
(end (mime-entity-info-point-max cinfo))
- (ctype (or (mime-entity-info-type/subtype cinfo) "text/plain"))
+ (c-type (mime-entity-info-media-type cinfo))
+ (c-subtype (mime-entity-info-media-subtype cinfo))
(params (mime-entity-info-parameters cinfo))
(encoding (mime-entity-info-encoding cinfo))
)
+ (or c-type
+ (setq c-type 'text
+ c-subtype 'plain))
;; Check for VM
(if (< beg (point-min))
(setq beg (point-min))
(setq end (point-max))
)
(let (method cal ret)
- (setq cal (list* (cons 'type ctype)
+ (setq cal (list* (cons 'type c-type)
+ (cons 'subtype c-subtype)
(cons 'encoding encoding)
(cons 'major-mode major-mode)
params))
(win-conf mime::preview/original-window-configuration)
)
(kill-buffer mime-raw-buffer)
- (mime-view-kill-buffer)
+ (mime-preview-kill-buffer)
(set-window-configuration win-conf)
(pop-to-buffer mother)
))