Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

fix compilation warnings & more changes for Emacs 24.1

  • Loading branch information...
commit cddcf61fffe38d48e3def512f2aa127b3c03f5b8 1 parent 375f6c2
@alexott alexott authored
View
19 ecb-buffertab.el
@@ -51,19 +51,23 @@
(require 'ecb-compilation)
(defface ecb-buffertab-primary-face '((t (:bold t :foreground "black")))
- "Face used to highlight the annotation lines to the left of the annotate buffer.")
+ "Face used to highlight the annotation lines to the left of the annotate buffer."
+ :group 'ecb)
(defface ecb-buffertab-secondary-face '((t (:bold nil :foreground "black")))
- "Face used to highlight the annotation lines to the left of the annotate buffer.")
+ "Face used to highlight the annotation lines to the left of the annotate buffer."
+ :group 'ecb)
(defface ecb-buffertab-secondary-mouse-face '((t (:bold nil :foreground "black" :italic t)))
- "Face used to highlight the annotation lines to the left of the annotate buffer.")
+ "Face used to highlight the annotation lines to the left of the annotate buffer."
+ :group 'ecb)
(defcustom ecb-buffertab-map (let ((map (make-sparse-keymap)))
(define-key map [header-line down-mouse-2] 'ecb-buffertab-popup-menu)
map)
- "Key map used for buffertab navigation")
+ "Key map used for buffertab navigation"
+ :group 'ecb)
(defun ecb-buffertab-popup-menu()
"Popup a menu for selecting an ECB buffer."
@@ -92,10 +96,7 @@
(interactive)
(let((ecb-prefix " ECB: " ))
- (save-excursion
-
- (set-buffer (get-buffer ecb-speedbar-buffer-name))
-
+ (with-current-buffer (get-buffer ecb-speedbar-buffer-name)
;;FIXME: figure out what modeline tab to use
(setq header-line-format (concat ecb-prefix "/ " (buffer-name)" "))
@@ -111,4 +112,4 @@
(silentcomp-provide 'ecb-buffertab)
-;;; ecb-buffertab.el ends here
+;;; ecb-buffertab.el ends here
View
15 ecb-create-layout.el
@@ -52,7 +52,6 @@
(silentcomp-defvar vertical-divider-map)
(silentcomp-defvar modeline-map)
;; Emacs 21.X stuff
-(silentcomp-defvar automatic-hscrolling)
(silentcomp-defvar before-make-frame-hook)
(silentcomp-defvar after-make-frame-functions)
;; First loaded during activated ECB
@@ -260,9 +259,9 @@ other other frame!"
"Cancel layout-creation without saving the layout."
(interactive)
(when (ecb-create-layout-frame-ok)
- (ecb-create-layout-clear-all (interactive-p))
+ (ecb-create-layout-clear-all (called-interactively-p 'interactive))
(message "ECB Layout Creation canceled - the layout is not saved!")
- (and (interactive-p) (ecb-activate))))
+ (and (called-interactively-p 'interactive) (ecb-activate))))
(defun ecb-create-layout-clear-all (&optional delete-frame)
"Resets all stuff to state before `ecb-create-new-layout' was called. If
@@ -285,7 +284,7 @@ DELETE-FRAME is not nil then the new created frame will be deleted and the
ecb-create-layout-old-minor-mode-map-alist))
;; restore horiz. scrolling
(unless ecb-running-xemacs
- (setq automatic-hscrolling ecb-create-layout-old-hscroll))
+ (setq auto-hscroll-mode ecb-create-layout-old-hscroll))
;; for XEmacs restore these maps
(if ecb-running-xemacs
(progn
@@ -313,7 +312,7 @@ DELETE-FRAME is not nil then the new created frame will be deleted and the
(interactive)
(when (ecb-create-layout-frame-ok)
(if (ecb-create-layout-ready-for-save-p)
- (let ((delete-frame (interactive-p)))
+ (let ((delete-frame (called-interactively-p 'interactive)))
;; if an error occurs during `ecb-create-layout-save-layout' or the
;; user hits C-q we must clean the layout creation stuff!
(unwind-protect
@@ -465,7 +464,7 @@ DELETE-FRAME is not nil then the new created frame will be deleted and the
(concat "ECB " new-type) nil t)
;; setting the new buffer type in the buffer itself
(ecb-create-layout-set-buffer-type new-type)
- (when (interactive-p)
+ (when (called-interactively-p 'interactive)
(ecb-create-layout-gen-lisp-for-buffer-type new-type)
(ecb-create-layout-next-window))
new-type)))
@@ -783,8 +782,8 @@ never selects the edit-window."
;; horiz. scrolling
(unless ecb-running-xemacs
- (setq ecb-create-layout-old-hscroll automatic-hscrolling)
- (setq automatic-hscrolling nil))
+ (setq ecb-create-layout-old-hscroll auto-hscroll-mode)
+ (setq auto-hscroll-mode nil))
;; for XEmacs modeline- and vertical-divider maps
(when ecb-running-xemacs
View
20 ecb-layout.el
@@ -1681,7 +1681,7 @@ arguments. Do never set this variable; it is only set by
;; ECB and if `ecb-compile-window-temporally-enlarge' is either
;; after-selection or nil then we shrink to the
;; ecb-compile-window-height! Otherwise we run the normal job!
- (if (and (not (interactive-p))
+ (if (and (not (called-interactively-p 'interactive))
(equal (ad-get-arg 0) ecb-compile-window)
(member ecb-compile-window-temporally-enlarge
'(after-selection nil))
@@ -1697,7 +1697,7 @@ arguments. Do never set this variable; it is only set by
;; `ecb-compile-window-height'
(let ((window-min-height (if (and (equal (ad-get-arg 0) ecb-compile-window)
(and ecb-compile-window-prevent-shrink-below-height
- (not (interactive-p)))
+ (not (called-interactively-p 'interactive)))
window-min-height
ecb-compile-window-height-lines
(< window-min-height
@@ -1796,7 +1796,7 @@ for current layout."
;; `ecb-compile-window-height'
(window-min-height (if (and (equal (ad-get-arg 0) ecb-compile-window)
(and ecb-compile-window-prevent-shrink-below-height
- (not (interactive-p)))
+ (not (called-interactively-p 'interactive)))
window-min-height
ecb-compile-window-height-lines
(< window-min-height
@@ -3141,7 +3141,7 @@ If called for other frames it works like the original version."
;; algorithm of `ecb-toggle-compile-window-height' fails
;; (e.g. during `compile-internal'!).
(unless pop-up-frames
- (if (interactive-p)
+ (if (called-interactively-p 'interactive)
(ecb-set-compile-window-height)
(if (save-excursion
(set-buffer (ad-get-arg 0))
@@ -3367,7 +3367,7 @@ If called for other frames it works like the original version."
;; ;; algorithm of `ecb-toggle-compile-window-height' fails
;; ;; (e.g. during `compile-internal'!).
;; (unless pop-up-frames
-;; (if (interactive-p)
+;; (if (called-interactively-p 'interactive)
;; (ecb-set-compile-window-height)
;; (if (save-excursion
;; (set-buffer (ad-get-arg 0))
@@ -3800,7 +3800,7 @@ compile-window then it will be hidden and otherwise the behavior depends on
(ecb-with-original-basic-functions
ad-do-it)
(ecb-do-with-unfixed-ecb-buffers
- (when (and (interactive-p)
+ (when (and (called-interactively-p 'interactive)
(null (ad-get-arg 0))
(member 'delete-window ecb-layout-always-operate-in-edit-window)
(not (ecb-point-in-compile-window))
@@ -3903,7 +3903,7 @@ behavior depends on `ecb-advice-window-functions-signal-error'."
(ecb-with-original-basic-functions
ad-do-it)
(ecb-do-with-unfixed-ecb-buffers
- (when (and (interactive-p)
+ (when (and (called-interactively-p 'interactive)
(null (ad-get-arg 0))
(member 'delete-other-windows
ecb-layout-always-operate-in-edit-window)
@@ -4027,7 +4027,7 @@ version."
;; used) then we maybe must first go to the edit-window.
;; The check for interactiv-p prevents that we jump to the edit-window if
;; called from within `split-window-vertically' for example.
- (when (and (interactive-p)
+ (when (and (called-interactively-p 'interactive)
(null (ad-get-arg 0))
(member 'split-window
ecb-layout-always-operate-in-edit-window)
@@ -6226,7 +6226,7 @@ if no compile-window is visible."
)
;; return the new compile-window height
(ecb-window-full-height))))
- (if (interactive-p)
+ (if (called-interactively-p 'interactive)
(ecb-info-message "No compile-window in current ECB-layout!"))
nil))
@@ -6293,7 +6293,7 @@ you have to quit with `C-g')."
(new-win nil))
(if new-state
(let ((height (or ecb-compile-window-height
- (and (interactive-p)
+ (and (called-interactively-p 'interactive)
(or (ecb-option-get-value 'ecb-compile-window-height
'saved-value)
(ecb-read-number "Insert height of the compile-window: " 6))))))
View
3  ecb-semantic-wrapper.el
@@ -224,8 +224,7 @@ unloaded buffer representation."
"Attempt to calculate the parent-tag of TAG."
(if (fboundp 'semantic-tag-calculate-parent)
(apply 'semantic-tag-calculate-parent (list tag))
- (save-excursion
- (set-buffer (ecb--semantic-tag-buffer tag))
+ (with-current-buffer (ecb--semantic-tag-buffer tag)
(goto-char (ecb--semantic-tag-start tag))
(ecb--semantic-current-tag-parent))))
View
4 ecb-speedbar.el
@@ -203,7 +203,7 @@ after clicking onto a filename in the speedbar."
(defecb-advice speedbar-frame-mode around ecb-speedbar-adviced-functions
"During running speedbar within ECB this command is disabled!"
(if ecb-minor-mode
- (when (interactive-p)
+ (when (called-interactively-p 'interactive)
(ecb-info-message "speedbar-frame-mode takes no effect when running within ECB!"))
ad-do-it))
@@ -272,7 +272,7 @@ the point was not set by `mouse-set-point'."
(set-window-buffer (selected-window)
(get-buffer-create ecb-speedbar-buffer-name))
(unless ecb-running-xemacs
- (set (make-local-variable 'automatic-hscrolling) nil)))
+ (set (make-local-variable 'auto-hscroll-mode) nil)))
View
2  ecb-tod.el
@@ -124,7 +124,7 @@
(defun ecb-show-tip-of-the-day ()
"Show tip of the day if `ecb-tip-of-the-day' is not nil."
(interactive)
- (when (or (interactive-p) ecb-tip-of-the-day)
+ (when (or (called-interactively-p 'interactive) ecb-tip-of-the-day)
(ignore-errors (load-file ecb-tip-of-the-day-file))
(let* ((cursor (if (boundp 'ecb-tod-cursor)
ecb-tod-cursor
View
4 ecb-upgrade.el
@@ -1048,7 +1048,7 @@ your customization-file!"
;; now we display only the choice to save the ecb-options-version but only
;; if ecb-options-version != ecb-version and (either the command is called
;; interactively or first-time called by program)
- (when (and (or (interactive-p)
+ (when (and (or (called-interactively-p 'interactive)
(not (get 'ecb-display-upgraded-options
'ecb-options-version-save-displayed)))
(not (ecb-options-version=ecb-version-p)))
@@ -1111,7 +1111,7 @@ If FULL-NEWS is not nil then the NEWS-file is displayed in another window."
(if (and ecb-old-ecb-version
(or (not (get 'ecb-display-news-for-upgrade
'ecb-news-for-upgrade-displayed))
- (interactive-p)))
+ (called-interactively-p 'interactive)))
(progn
(with-output-to-temp-buffer "*News for the new ECB-version*"
(princ (format "You have upgraded ECB from version %s to %s.\n\n"
View
2  tree-buffer.el
@@ -2580,7 +2580,7 @@ Example for the usage of this macro:
"then the current node at point in the currently selected tree-buffer is used.\n"
"REST-ARG-LIST is a list of zero or more extra arguments passed to this command.")
(interactive)
- (let ((node (if (and (interactive-p) (null node))
+ (let ((node (if (and (called-interactively-p 'interactive) (null node))
(tree-buffer-get-node-at-point)
node)))
(when node
Please sign in to comment.
Something went wrong with that request. Please try again.