[mcclim-devel] [PATCH] fix undefined-variable warnings in commands.lisp
Nikodemus Siivola
nikodemus at random-state.net
Mon Jan 21 18:34:22 UTC 2008
...for once, these are mostly really undefined variables,
left over from some refactoring or another...
---
commands.lisp | 16 ++++++++--------
frames.lisp | 7 ++++---
2 files changed, 12 insertions(+), 11 deletions(-)
diff --git a/commands.lisp b/commands.lisp
index 66db758..5d163a9 100644
--- a/commands.lisp
+++ b/commands.lisp
@@ -332,7 +332,7 @@
(command-name-from-symbol command-name))
(errorp
(error 'command-not-accessible :command-table-name
- (command-table-designator-as-name table)))
+ (command-table-designator-as-name command-table)))
(t nil)))
(defun find-menu-item (menu-name command-table &key (errorp t))
@@ -436,7 +436,7 @@
(in-table (position gesture keystroke-accelerators :test #'equal)))
(when (and in-table errorp)
(error 'command-already-present :command-table-name
- (command-table-designator-as-name table)))
+ (command-table-designator-as-name command-table)))
(if in-table
(setf (nth in-table keystroke-items) item)
(progn
@@ -474,7 +474,7 @@
(setf (cdr items-tail) (cddr items-tail))))
(when errorp
(error 'command-not-present :command-table-name
- (command-table-designator-as-name table)))))))
+ (command-table-designator-as-name command-table)))))))
nil)
(defun map-over-command-table-keystrokes (function command-table)
@@ -499,7 +499,7 @@
do (return-from find-keystroke-item (values item command-table)))
(if errorp
(error 'command-not-present :command-table-name
- (command-table-designator-as-name table))
+ (command-table-designator-as-name command-table))
nil)))
(defun lookup-keystroke-item (gesture command-table
@@ -522,11 +522,11 @@
(values sub-item sub-command-table))))))
command-table))))
-(defun partial-command-from-name (command-name)
+(defun partial-command-from-name (command-name command-table)
(let ((parser (gethash command-name *command-parser-table*)))
(if (null parser)
(error 'command-not-present :command-table-name
- (command-table-designator-as-name table))
+ (command-table-designator-as-name command-table))
(cons command-name
(mapcar #'(lambda (foo)
(declare (ignore foo))
@@ -549,7 +549,7 @@
(if item
(let* ((value (command-menu-item-value item))
(command (case (command-menu-item-type item)
- (:command
+ (:command
value)
(:function
(funcall value gesture numeric-arg))
@@ -558,7 +558,7 @@
(if command
; Return a literal command, or create a partial command from a command-name
(substitute-numeric-argument-marker (if (symbolp command)
- (partial-command-from-name command)
+ (partial-command-from-name command command-table)
command)
numeric-arg)
gesture))
diff --git a/frames.lisp b/frames.lisp
index 92376d3..ce7a551 100644
--- a/frames.lisp
+++ b/frames.lisp
@@ -521,13 +521,14 @@ documentation produced by presentations.")
(object)
(call-next-method)
(menu-item
- (let ((command (command-menu-item-value object)))
+ (let ((command (command-menu-item-value object))
+ (table (frame-command-table frame)))
(unless (listp command)
- (setq command (partial-command-from-name command)))
+ (setq command (partial-command-from-name command table)))
(if (and (typep stream 'interactor-pane)
(partial-command-p command))
(command-line-read-remaining-arguments-for-partial-command
- (frame-command-table frame) stream command 0)
+ table stream command 0)
command)))))
(defmethod read-frame-command ((frame application-frame)
--
1.5.3.1-dirty
More information about the mcclim-devel
mailing list