summaryrefslogtreecommitdiff
path: root/lisp/edmacro.el
diff options
context:
space:
mode:
authorBasil L. Contovounesios <contovob@tcd.ie>2021-10-11 19:14:23 +0100
committerBasil L. Contovounesios <contovob@tcd.ie>2021-10-12 22:32:03 +0100
commitbcb43fbc95ad0c635c8f19c391ec90d3f8a74035 (patch)
tree8d3c67e6e4d96c1408f35f6fe1681e28318b6b3c /lisp/edmacro.el
parente47b85a68339063dd3a784e8b90aecbf90b23f41 (diff)
downloademacs-bcb43fbc95ad0c635c8f19c391ec90d3f8a74035.tar.gz
Fix byte-compilation warnings in nox builds
For discussion, see bug#51139. * lisp/edmacro.el (edmacro-fix-menu-commands): Load mwheel to pacify free variable warnings in without-x builds. * lisp/mh-e/mh-compat.el: Declare image.el functions that are not preloaded in without-x builds. * lisp/mh-e/mh-utils.el (mh--with-image-load-path): New macro. (mh-logo-display): * lisp/mh-e/mh-tool-bar.el (mh-tool-bar-folder-buttons-init) (mh-tool-bar-letter-buttons-init): Use it to pacify byte-compilation warnings about image.el definitions not preloaded without-x.
Diffstat (limited to 'lisp/edmacro.el')
-rw-r--r--lisp/edmacro.el6
1 files changed, 6 insertions, 0 deletions
diff --git a/lisp/edmacro.el b/lisp/edmacro.el
index e90b3a006ef..a4eb574a4c2 100644
--- a/lisp/edmacro.el
+++ b/lisp/edmacro.el
@@ -604,6 +604,12 @@ This function assumes that the events can be stored in a string."
(defun edmacro-fix-menu-commands (macro &optional noerror)
(if (vectorp macro)
(let (result)
+ ;; Not preloaded in without-x builds.
+ (require 'mwheel)
+ (defvar mouse-wheel-down-event)
+ (defvar mouse-wheel-left-event)
+ (defvar mouse-wheel-right-event)
+ (defvar mouse-wheel-up-event)
;; Make a list of the elements.
(setq macro (append macro nil))
(dolist (ev macro)