From: morioka Date: Wed, 29 Sep 1999 13:58:58 +0000 (+0000) Subject: (mime-preview-play-current-entity): Use text-property X-Git-Tag: semi-1_13_7~11 X-Git-Url: http://git.chise.org/gitweb/?a=commitdiff_plain;h=74443f44963dcd6d461be0c1a480ec0e960be450;p=elisp%2Fsemi.git (mime-preview-play-current-entity): Use text-property `mime-view-situation' as the initial value of acting-situation to add major-mode. --- diff --git a/mime-play.el b/mime-play.el index 0840304..b4a03a2 100644 --- a/mime-play.el +++ b/mime-play.el @@ -159,7 +159,15 @@ If MODE is specified, play as it. Default MODE is \"play\"." (interactive "P") (let ((entity (get-text-property (point) 'mime-view-entity))) (if entity - (let ((situation (list (cons 'mode (or mode "play"))))) + (let ((situation + (get-text-property (point) 'mime-view-situation))) + (or mode + (setq mode "play")) + (setq situation + (if (assq 'mode situation) + (put-alist 'mode mode (copy-alist situation)) + (cons (cons 'mode mode) + situation))) (if ignore-examples (setq situation (cons (cons 'ignore-examples ignore-examples)