* lisp/gnus/gmm-utils.el (gmm-image-search-load-path): Remove.
(gmm-write-region): Remove.
(gmm-called-interactively-p): Remove.
:tag "Other"
(symbol :tag "Icon item")))))
-;; (defun gmm-color-cells (&optional display)
-;; "Return the number of color cells supported by DISPLAY.
-;; Compatibility function."
-;; ;; `display-color-cells' doesn't return more than 256 even if color depth is
-;; ;; > 8 in Emacs 21.
-;; ;;
-;; ;; Feel free to add proper XEmacs support.
-;; (let* ((cells (and (fboundp 'display-color-cells)
-;; (display-color-cells display)))
-;; (plane (and (fboundp 'x-display-planes)
-;; (ash 1 (x-display-planes))))
-;; (none -1))
-;; (max (if (integerp cells) cells none)
-;; (if (integerp plane) plane none))))
-
(defcustom gmm-tool-bar-style
(if (and (boundp 'tool-bar-mode)
tool-bar-mode
(let ((img image)
(dir (or
;; Images in image-load-path.
- (gmm-image-search-load-path image) ;; "gmm-" prefix!
+ (image-search-load-path image)
;; Images in load-path.
(locate-library image)))
parent)
(string-match "^\\(.+\\)-mode$" mode)
(match-string 1 mode))))))
-(defun gmm-write-region (start end filename &optional append visit
- lockname mustbenew)
- "Compatibility function for `write-region'.
-
-In XEmacs, the seventh argument of `write-region' specifies the
-coding-system."
- (if (and mustbenew (featurep 'xemacs))
- (if (file-exists-p filename)
- (signal 'file-already-exists (list "File exists" filename))
- (write-region start end filename append visit lockname))
- (write-region start end filename append visit lockname mustbenew)))
-
-;; `interactive-p' is obsolete since Emacs 23.2.
-(defmacro gmm-called-interactively-p (kind)
- (condition-case nil
- (progn
- (eval '(called-interactively-p 'any))
- ;; Emacs >=23.2
- `(called-interactively-p ,kind))
- ;; Emacs <23.2
- (wrong-number-of-arguments '(called-interactively-p))
- ;; XEmacs
- (void-function '(interactive-p))))
-
;; `labels' is obsolete since Emacs 24.3.
(defmacro gmm-labels (bindings &rest body)
"Make temporary function bindings.
(while (re-search-forward
"\\(\\(https?\\|ftp\\)://\\S-+\\) *\n\\(\\S-+\\)" nil t)
(replace-match "\\1\\3" t)))
- (when (gmm-called-interactively-p 'any)
+ (when (called-interactively-p 'any)
(gnus-treat-article nil))))
(defun article-wash-html ()
deletion, or > if it is flagged for displaying."
(interactive)
(gnus-bookmark-maybe-load-default-file)
- (if (gmm-called-interactively-p 'any)
+ (if (called-interactively-p 'any)
(switch-to-buffer (get-buffer-create "*Gnus Bookmark List*"))
(set-buffer (get-buffer-create "*Gnus Bookmark List*")))
(let ((inhibit-read-only t)
(let* ((article (last articles))
(id (gnus-registry-fetch-message-id-fast article))
(marks (when id (gnus-registry-get-id-key id 'mark))))
- (when (gmm-called-interactively-p 'any)
+ (when (called-interactively-p 'any)
(gnus-message 1 "Marks are %S" marks))
marks))
(remove-hook 'gnus-check-bogus-groups-hook 'gnus-topic-clean-alist)
(setq gnus-group-prepare-function 'gnus-group-prepare-flat)
(setq gnus-group-sort-alist-function 'gnus-group-sort-flat))
- (when (gmm-called-interactively-p 'any)
+ (when (called-interactively-p 'any)
(gnus-group-list-groups))))
(defun gnus-topic-select-group (&optional all)
(defun message-goto-body ()
"Move point to the beginning of the message body."
(interactive)
- (when (and (gmm-called-interactively-p 'any)
+ (when (and (called-interactively-p 'any)
(looking-at "[ \t]*\n"))
(expand-abbrev))
(push-mark)
inhibit-file-name-handlers)))
(write-region start end filename append visit lockname)))
-(autoload 'gmm-write-region "gmm-utils")
-
;; It is not a MIME function, but some MIME functions use it.
(if (and (fboundp 'make-temp-file)
(ignore-errors
(setq file (concat file suffix)))
(if dir-flag
(make-directory file)
- ;; NOTE: This is unsafe if Emacs 20
- ;; users and XEmacs users don't use
- ;; a secure temp directory.
- (gmm-write-region "" nil file nil 'silent
- nil 'excl))
+ (write-region "" nil file nil 'silent nil 'excl))
nil)
(file-already-exists t)
;; The XEmacs version of `make-directory' issues
(prin1 (vector storage-version num msgid nov) (current-buffer))
(setq file (concat novfile ":"))
(nnmaildir--unlink file)
- (gmm-write-region (point-min) (point-max) file nil 'no-message nil
- 'excl))
+ (write-region (point-min) (point-max) file nil 'no-message nil
+ 'excl))
(rename-file file novfile 'replace)
(setf (nnmaildir--art-msgid article) msgid)
nov)))
(concat "File exists: " tmpfile))
(throw 'return nil))
(with-current-buffer buffer
- (gmm-write-region (point-min) (point-max) tmpfile nil 'no-message nil
- 'excl))
+ (write-region (point-min) (point-max) tmpfile nil 'no-message nil
+ 'excl))
(unix-sync) ;; no fsync :(
(rename-file tmpfile (concat (nnmaildir--cur dir) file suffix) 'replace)
t)))
(throw 'return nil))))
(condition-case nil (add-name-to-file nnmaildir--file tmpfile)
(error
- (gmm-write-region (point-min) (point-max) tmpfile nil 'no-message nil
- 'excl)
+ (write-region (point-min) (point-max) tmpfile nil 'no-message nil
+ 'excl)
(when (fboundp 'unix-sync)
(unix-sync)))) ;; no fsync :(
(nnheader-cancel-timer 24h)