[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] master 00cc327 2/5: Remove more XEmacs compat code from Gn
From: |
Lars Ingebrigtsen |
Subject: |
[Emacs-diffs] master 00cc327 2/5: Remove more XEmacs compat code from Gnus |
Date: |
Thu, 11 Feb 2016 06:00:30 +0000 |
branch: master
commit 00cc327b9d7f2b90b10ec45f111dcc670dbbb102
Author: Lars Ingebrigtsen <address@hidden>
Commit: Lars Ingebrigtsen <address@hidden>
Remove more XEmacs compat code from Gnus
* lisp/gnus/gnus-util.el (gnus-bound-and-true-p): Remove.
(gnus-timer--function): Remove.
* lisp/gnus/gnus-uu.el (gnus-uu-save-article): Remove XEmacs
19.2 compat.
* lisp/gnus/gnus-win.el: Remove XEmacs compat code.
---
lisp/gnus/gnus-art.el | 2 +-
lisp/gnus/gnus-util.el | 10 ----------
lisp/gnus/gnus-uu.el | 5 +----
lisp/gnus/gnus-win.el | 19 ++++---------------
lisp/gnus/gnus.el | 13 ++++---------
lisp/gnus/nnir.el | 4 ++--
lisp/gnus/nnmairix.el | 2 +-
7 files changed, 13 insertions(+), 42 deletions(-)
diff --git a/lisp/gnus/gnus-art.el b/lisp/gnus/gnus-art.el
index 9b1215b..99d107e 100644
--- a/lisp/gnus/gnus-art.el
+++ b/lisp/gnus/gnus-art.el
@@ -4562,7 +4562,7 @@ commands:
(defun gnus-article-stop-animations ()
(dolist (timer (and (boundp 'timer-list)
timer-list))
- (when (eq (gnus-timer--function timer) 'image-animate-timeout)
+ (when (eq (timer--function timer) 'image-animate-timeout)
(cancel-timer timer))))
(defun gnus-stop-downloads ()
diff --git a/lisp/gnus/gnus-util.el b/lisp/gnus/gnus-util.el
index 52b2df4..eee80fd 100644
--- a/lisp/gnus/gnus-util.el
+++ b/lisp/gnus/gnus-util.el
@@ -1819,16 +1819,6 @@ to case differences."
(string-equal (downcase str1) (downcase prefix))
(string-equal str1 prefix))))))
-;; Simple check: can be a macro but this way, although slow, it's really clear.
-;; We don't use `bound-and-true-p' because it's not in XEmacs.
-(defun gnus-bound-and-true-p (sym)
- (and (boundp sym) (symbol-value sym)))
-
-(if (fboundp 'timer--function)
- (defalias 'gnus-timer--function 'timer--function)
- (defun gnus-timer--function (timer)
- (elt timer 5)))
-
(defun gnus-test-list (list predicate)
"To each element of LIST apply PREDICATE.
Return nil if LIST is no list or is empty or some test returns nil;
diff --git a/lisp/gnus/gnus-uu.el b/lisp/gnus/gnus-uu.el
index 416567e..1a249e9 100644
--- a/lisp/gnus/gnus-uu.el
+++ b/lisp/gnus/gnus-uu.el
@@ -876,10 +876,7 @@ When called interactively, prompt for REGEXP."
(with-current-buffer buffer
(save-restriction
(let ((inhibit-read-only t))
- (set-text-properties (point-min) (point-max) nil)
- ;; These two are necessary for XEmacs 19.12 fascism.
- (put-text-property (point-min) (point-max) 'invisible nil)
- (put-text-property (point-min) (point-max) 'intangible nil))
+ (set-text-properties (point-min) (point-max) nil))
(when (and message-forward-as-mime
message-forward-show-mml
gnus-uu-digest-buffer)
diff --git a/lisp/gnus/gnus-win.el b/lisp/gnus/gnus-win.el
index 2c448aa..c17ccd6 100644
--- a/lisp/gnus/gnus-win.el
+++ b/lisp/gnus/gnus-win.el
@@ -273,9 +273,7 @@ See the Gnus manual for an explanation of the syntax used.")
(cond
((eq buf (window-buffer (selected-window)))
(set-buffer buf))
- ((eq t (window-dedicated-p
- ;; XEmacs version of `window-dedicated-p' requires it.
- (selected-window)))
+ ((eq t (window-dedicated-p))
;; If the window is hard-dedicated, we have a problem because
;; we just can't do what we're asked. But signaling an error,
;; like `switch-to-buffer' would do, is not an option because
@@ -417,15 +415,11 @@ See the Gnus manual for an explanation of the syntax
used.")
(gnus-delete-windows-in-gnusey-frames))
;; Just remove some windows.
(gnus-remove-some-windows)
- (if (featurep 'xemacs)
- (switch-to-buffer nntp-server-buffer)
- (set-buffer nntp-server-buffer)))
+ (set-buffer nntp-server-buffer))
(select-frame frame)))
(let (gnus-window-frame-focus)
- (if (featurep 'xemacs)
- (switch-to-buffer nntp-server-buffer)
- (set-buffer nntp-server-buffer))
+ (set-buffer nntp-server-buffer)
(gnus-configure-frame split)
(run-hooks 'gnus-configure-windows-hook)
(when gnus-window-frame-focus
@@ -510,9 +504,7 @@ should have point."
lowest-buf buf))))
(when lowest-buf
(pop-to-buffer lowest-buf)
- (if (featurep 'xemacs)
- (switch-to-buffer nntp-server-buffer)
- (set-buffer nntp-server-buffer)))
+ (set-buffer nntp-server-buffer))
(mapcar (lambda (b) (delete-windows-on b t))
(delq lowest-buf bufs)))))
@@ -520,9 +512,6 @@ should have point."
(cond
((fboundp 'frames-on-display-list)
(defalias 'gnus-frames-on-display-list 'frames-on-display-list))
- ((and (featurep 'xemacs) (fboundp 'frame-device))
- (defun gnus-frames-on-display-list ()
- (apply 'filtered-frame-list 'identity (list (frame-device nil)))))
(t
(defalias 'gnus-frames-on-display-list 'frame-list))))
diff --git a/lisp/gnus/gnus.el b/lisp/gnus/gnus.el
index 661f483..fe86749 100644
--- a/lisp/gnus/gnus.el
+++ b/lisp/gnus/gnus.el
@@ -2503,16 +2503,11 @@ Disabling the agent may result in noticeable loss of
performance."
(function-item gnus-slave-no-server)))
(defcustom gnus-other-frame-parameters nil
- "Frame parameters used by `gnus-other-frame' to create a Gnus frame.
-This should be an alist for Emacs, or a plist for XEmacs."
+ "Frame parameters used by `gnus-other-frame' to create a Gnus frame."
:group 'gnus-start
- :type (if (featurep 'xemacs)
- '(repeat (list :inline t :format "%v"
- (symbol :tag "Property")
- (sexp :tag "Value")))
- '(repeat (cons :format "%v"
- (symbol :tag "Parameter")
- (sexp :tag "Value")))))
+ :type '(repeat (cons :format "%v"
+ (symbol :tag "Parameter")
+ (sexp :tag "Value"))))
(defcustom gnus-user-agent '(emacs gnus type)
"Which information should be exposed in the User-Agent header.
diff --git a/lisp/gnus/nnir.el b/lisp/gnus/nnir.el
index eb436f5..783d1b9 100644
--- a/lisp/gnus/nnir.el
+++ b/lisp/gnus/nnir.el
@@ -1787,7 +1787,7 @@ article came from is also searched."
(list (list (gnus-method-to-server
(gnus-find-method-for-group gnus-newsgroup-name)))))
(registry-group (and
- (gnus-bound-and-true-p 'gnus-registry-enabled)
+ (bound-and-true-p gnus-registry-enabled)
(car (gnus-registry-get-id-key
(mail-header-id header) 'group))))
(registry-server
@@ -1859,7 +1859,7 @@ article came from is also searched."
(when (eq (car (gnus-find-method-for-group gnus-newsgroup-name)) 'nnir)
(setq gnus-summary-line-format
(or nnir-summary-line-format gnus-summary-line-format))
- (when (gnus-bound-and-true-p 'gnus-registry-enabled)
+ (when (bound-and-true-p gnus-registry-enabled)
(remove-hook 'gnus-summary-article-delete-hook 'gnus-registry-action t)
(remove-hook 'gnus-summary-article-move-hook 'gnus-registry-action t)
(remove-hook 'gnus-summary-article-expire-hook 'gnus-registry-action t)
diff --git a/lisp/gnus/nnmairix.el b/lisp/gnus/nnmairix.el
index d5fa4fa..20aecd9 100644
--- a/lisp/gnus/nnmairix.el
+++ b/lisp/gnus/nnmairix.el
@@ -1635,7 +1635,7 @@ search in raw mode."
(defun nnmairix-determine-original-group-from-registry (mid)
"Try to determine original group for message-id MID from the registry."
- (when (gnus-bound-and-true-p 'gnus-registry-enabled)
+ (when (bound-and-true-p gnus-registry-enabled)
(unless (string-match "^<" mid)
(set mid (concat "<" mid)))
(unless (string-match ">$" mid)