changeset 733:b1f74adcc1ff

[xemacs-hg @ 2002-01-22 20:40:00 by janv] Fix disabled-command-hook
author janv
date Tue, 22 Jan 2002 20:40:03 +0000
parents b9b8621c2439
children 8bd30fae1bce
files src/ChangeLog src/cmdloop.c src/eval.c src/event-stream.c src/lisp.h
diffstat 5 files changed, 16 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/ChangeLog	Tue Jan 22 14:16:39 2002 +0000
+++ b/src/ChangeLog	Tue Jan 22 20:40:03 2002 +0000
@@ -1,3 +1,13 @@
+2002-01-19  Jan Vroonhof  <jan@xemacs.org>
+
+	* cmdloop.c: New variable Qdisabled_command_loop.
+			Move Vdisabled_command_loop declaration here.
+	* cmdloop.c (syms_of_cmdloop): Declare Qdisabled_command_loop.
+	* eval.c (Fcommand_execute): Use the value of the symbol not
+		the value of the value as the hook to run.
+	* event-stream.c: Remove declaration of Vdisabled_command_loop
+	* lisp.h: Declare Qdisabled_command_loop
+
 2002-01-15  Adrian Aichner  <adrian@xemacs.org>
 
 	* event-msw.c (mswindows_wnd_proc): Add handling of WM_SHOWWINDOW
--- a/src/cmdloop.c	Tue Jan 22 14:16:39 2002 +0000
+++ b/src/cmdloop.c	Tue Jan 22 20:40:03 2002 +0000
@@ -50,6 +50,8 @@
 
 Lisp_Object Venter_window_hook, Vleave_window_hook;
 
+Lisp_Object Qdisabled_command_hook, Vdisabled_command_hook;
+
 /* The error handler.  */
 Lisp_Object Qcommand_error;
 
@@ -606,6 +608,7 @@
 void
 syms_of_cmdloop (void)
 {
+  DEFSYMBOL (Qdisabled_command_hook);
   DEFSYMBOL (Qcommand_error);
   DEFSYMBOL (Qreally_early_error_handler);
   DEFSYMBOL (Qtop_level);
--- a/src/eval.c	Tue Jan 22 14:16:39 2002 +0000
+++ b/src/eval.c	Tue Jan 22 20:40:03 2002 +0000
@@ -2894,7 +2894,7 @@
   debug_on_next_call = 0; /* #### from FSFmacs; correct? */
 
   if (SYMBOLP (cmd) && !NILP (Fget (cmd, Qdisabled, Qnil)))
-    return run_hook (Vdisabled_command_hook);
+    return run_hook (Qdisabled_command_hook);
 
   for (;;)
     {
--- a/src/event-stream.c	Tue Jan 22 14:16:39 2002 +0000
+++ b/src/event-stream.c	Tue Jan 22 20:40:03 2002 +0000
@@ -135,7 +135,7 @@
 
 /* Non-nil disable property on a command means
    do not execute it; call disabled-command-hook's value instead. */
-Lisp_Object Qdisabled, Vdisabled_command_hook;
+Lisp_Object Qdisabled;
 
 EXFUN (Fnext_command_event, 2);
 
--- a/src/lisp.h	Tue Jan 22 14:16:39 2002 +0000
+++ b/src/lisp.h	Tue Jan 22 20:40:03 2002 +0000
@@ -3257,7 +3257,7 @@
 extern Lisp_Object Qcrlf, Qcurrent_menubar, Qctext;
 extern Lisp_Object Qcyclic_variable_indirection, Qdecode;
 extern Lisp_Object Qdefun, Qdevice_live_p;
-extern Lisp_Object Qdim, Qdisabled, Qdisplay_table;
+extern Lisp_Object Qdim, Qdisabled, Qdisabled_command_hook, Qdisplay_table;
 extern Lisp_Object Qdomain_error;
 extern Lisp_Object Qediting_error;
 extern Lisp_Object Qencode, Qend_of_buffer, Qend_of_file, Qend_open;