From: tomo Date: Mon, 10 Jan 2000 14:16:59 +0000 (+0000) Subject: (emh-raw-buffer): New inline function. X-Git-Tag: emacs-21_0_90-emh-1_13_0-0~3 X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=218774bc34e52877aaa258e33ba0fef87f079a68;p=elisp%2Femh.git (emh-raw-buffer): New inline function. (mh-display-msg): Use `emh-raw-buffer'. (emh-toggle-decoding-mode): Likewise. --- diff --git a/emh.el b/emh.el index 8a0c1ad..22a2d7e 100644 --- a/emh.el +++ b/emh.el @@ -1,6 +1,6 @@ ;;; emh.el --- MIME extender for mh-e -;; Copyright (C) 1995,1996,1997,1998 Free Software Foundation, Inc. +;; Copyright (C) 1995,1996,1997,1998,2000 Free Software Foundation, Inc. ;; Author: MORIOKA Tomohiko ;; OKABE Yasuo @@ -62,6 +62,11 @@ ;;; @ functions ;;; +(defsubst emh-raw-buffer (folder-buffer) + (concat "article-" (if (bufferp folder-buffer) + (buffer-name folder-buffer) + folder-buffer))) + (defun mh-display-msg (msg-num folder &optional show-buffer mode) "Display message number MSG-NUM of FOLDER. This function uses `mime-view-mode' if MODE is not nil. If MODE is @@ -87,7 +92,7 @@ nil, `emh-automatic-mime-preview' is used as default value." (setq buffer-read-only nil) (erase-buffer) (if mode - (let* ((aname (concat "article-" folder)) + (let* ((aname (emh-raw-buffer folder)) (abuf (get-buffer aname))) (if abuf (progn @@ -173,8 +178,7 @@ With arg, turn MIME processing on if arg is positive." (if (null arg) (not emh-automatic-mime-preview) arg)) - (let ((raw-buffer - (concat "article-" (buffer-name (current-buffer))))) + (let ((raw-buffer (emh-raw-buffer (current-buffer)))) (if (get-buffer raw-buffer) (kill-buffer raw-buffer) ))