|
@@ -113,18 +113,41 @@ any other entries, and any resulting duplicates will be removed entirely."
|
|
|
|
|
|
;;;; Emacs/XEmacs compatibility
|
|
|
|
|
|
-(defun org-defvaralias (new-alias base-variable &optional docstring)
|
|
|
- "Compatibility function for defvaralias.
|
|
|
+(eval-and-compile
|
|
|
+ (defun org-defvaralias (new-alias base-variable &optional docstring)
|
|
|
+ "Compatibility function for defvaralias.
|
|
|
Don't do the aliasing when `defvaralias' is not bound."
|
|
|
- (declare (indent 1))
|
|
|
- (when (fboundp 'defvaralias)
|
|
|
- (defvaralias new-alias base-variable docstring)))
|
|
|
+ (declare (indent 1))
|
|
|
+ (when (fboundp 'defvaralias)
|
|
|
+ (defvaralias new-alias base-variable docstring)))
|
|
|
|
|
|
-(eval-and-compile
|
|
|
(when (and (not (boundp 'user-emacs-directory))
|
|
|
(boundp 'user-init-directory))
|
|
|
(org-defvaralias 'user-emacs-directory 'user-init-directory)))
|
|
|
|
|
|
+ (when (featurep 'xemacs)
|
|
|
+ (defadvice custom-handle-keyword
|
|
|
+ (around org-custom-handle-keyword (symbol keyword value type)
|
|
|
+ activate preactivate)
|
|
|
+ "Remove custom keywords not recognized to avoid producing an error."
|
|
|
+ (cond
|
|
|
+ ((eq keyword :package-version))
|
|
|
+ (t ad-do-it)))
|
|
|
+ (defadvice define-obsolete-variable-alias
|
|
|
+ (around org-define-obsolete-variable-alias
|
|
|
+ (obsolete-name current-name &optional docstring)
|
|
|
+ activate preactivate)
|
|
|
+ "Declare arguments defined in later versions of Emacs."
|
|
|
+ ad-do-it)
|
|
|
+ (defadvice define-obsolete-function-alias
|
|
|
+ (around org-define-obsolete-function-alias
|
|
|
+ (obsolete-name current-name when &optional docstring)
|
|
|
+ activate preactivate)
|
|
|
+ "Declare arguments defined in later versions of Emacs."
|
|
|
+ ad-do-it)
|
|
|
+ (defvar customize-package-emacs-version-alist nil)
|
|
|
+ (defvar temporary-file-directory (temp-directory)))
|
|
|
+
|
|
|
;; Keys
|
|
|
(defconst org-xemacs-key-equivalents
|
|
|
'(([mouse-1] . [button1])
|