auctex-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[AUCTeX-diffs] [elpa] externals/auctex 430025d 20/43: Remove compatibili


From: Tassilo Horn
Subject: [AUCTeX-diffs] [elpa] externals/auctex 430025d 20/43: Remove compatibility code for XEmacs in toolbar-x.el
Date: Tue, 20 Mar 2018 11:34:08 -0400 (EDT)

branch: externals/auctex
commit 430025dc4cdd9e8aab931c3b2796640997fe3a15
Author: Mosè Giordano <address@hidden>
Commit: Mosè Giordano <address@hidden>

    Remove compatibility code for XEmacs in toolbar-x.el
    
    * toolbar-x.el (toolbarx--if-when-compile): Remove macro no more needed.
    (toolbarx-emacs-mount-popup-menu):
    (toolbarx-mount-popup-menu):
    (toolbarx-test-image-type):
    (toolbarx-test-button-type):
    (toolbarx-test-toolbar-type):
    (toolbarx-find-image):
    (toolbarx-emacs-add-button):
    (toolbarx-refresh):
    (toolbarx-install-toolbar):
    (toolbarx-default-toolbar-meaning-alist): Remove code for compatibility with
    XEmacs.
    (toolbarx-xemacs-mount-popup-menu):
    (toolbarx-xemacs-image-properties):
    (toolbarx-xemacs-button-properties):
    (toolbarx-xemacs-refresh-process-button-or-insert-list):
    (toolbarx-xemacs-refresh): Remove functions.
---
 toolbar-x.el | 608 ++++++-----------------------------------------------------
 1 file changed, 56 insertions(+), 552 deletions(-)

diff --git a/toolbar-x.el b/toolbar-x.el
index bac32c8..f61000d 100644
--- a/toolbar-x.el
+++ b/toolbar-x.el
@@ -275,13 +275,8 @@ command, COMM is returned."
 ;; handle `menu titles' differently) meanwhile in XEmacs, menus are lists of
 ;; vectors
 
-(defmacro toolbarx--if-when-compile (test then else)
-  (declare (indent 1) (debug t))
-  (if (eval test) then else))
-
-(toolbarx--if-when-compile (not (featurep 'xemacs))
 (defun toolbarx-emacs-mount-popup-menu
-  (strings var type &optional title save)
+    (strings var type &optional title save)
   "Return an interactive `lambda'-expression that shows a popup menu.
 This function is the action of `toolbarx-mount-popup-menu' if
 inside Emacs. See documentation of that function for more."
@@ -310,7 +305,7 @@ inside Emacs. See documentation of that function for more."
     (dolist (i strings)
       ;; finding a new symbol
       (let* ((aux-count 0)
-           (i-symb (toolbarx-make-symbol-from-string i)))
+            (i-symb (toolbarx-make-symbol-from-string i)))
        (setq key i-symb)
        (while (memq key used-symbols)
          (setq aux-count (1+ aux-count))
@@ -323,7 +318,7 @@ inside Emacs. See documentation of that function for more."
                         ,(if (eq real-type 'radio)
                              `(setq ,var ,count)
                            `(if (memq ,count ,var)
-                               (setq ,var (delete ,count ,var))
+                                (setq ,var (delete ,count ,var))
                               (setq ,var (sort (cons ,count ,var) '<))))
                         (toolbarx-refresh))
                      (when (eq real-save 'always)
@@ -345,70 +340,11 @@ inside Emacs. See documentation of that function for 
more."
        (setq used-symbols (cons key used-symbols)))
       (define-key-after keymap (vector key)
        `(menu-item "Save state of this menu"
-                  (lambda nil (interactive)
-                    (customize-save-variable (quote ,var) ,var)))))
+                   (lambda nil (interactive)
+                     (customize-save-variable (quote ,var) ,var)))))
     ;; returns a `lambda'-expression
     `(lambda nil (interactive) (popup-menu (quote ,keymap)))))
 
-(defun toolbarx-xemacs-mount-popup-menu
-  (strings var type &optional title save)
-  "Return an interactive `lambda'-expression that shows a popup menu.
-This function is the action of `toolbarx-mount-popup-menu' if
-inside XEmacs. See documentation of that function for more."
-  (let* ((menu (if (and title (stringp title))
-                  (list title)
-                (setq title nil)
-                (list "Dropdown menu")))
-        (count 0)
-        (menu-item)
-        (menu-callback)
-        (real-type (if (eq type 'toggle) 'toggle 'radio))
-        (real-save (when save (if (eq save 'offer) 'offer 'always))))
-    ;; warn if type is not `radio' ot `toggle'; use `radio' if incorrect


reply via email to

[Prev in Thread] Current Thread [Next in Thread]