aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRichard M. Stallman1993-06-11 17:14:31 +0000
committerRichard M. Stallman1993-06-11 17:14:31 +0000
commitc5074d8cad1f82ba7887322bf85f52589c7cbede (patch)
treee0e3d5ce97731f575ca86d23ecd13a7435a45a67 /src
parentb25b6c3402ba93ea12fc369585cf9f6de0e09d25 (diff)
downloademacs-c5074d8cad1f82ba7887322bf85f52589c7cbede.tar.gz
emacs-c5074d8cad1f82ba7887322bf85f52589c7cbede.zip
(Fmouse_position): Set up defaults before calling the hook.
Diffstat (limited to 'src')
-rw-r--r--src/frame.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/frame.c b/src/frame.c
index 290fb18ee6b..2287710e87f 100644
--- a/src/frame.c
+++ b/src/frame.c
@@ -754,19 +754,18 @@ and nil for X and Y.")
754 Lisp_Object x, y; 754 Lisp_Object x, y;
755 unsigned long long_dummy; 755 unsigned long long_dummy;
756 756
757 f = selected_frame;
758 x = y = Qnil;
759
760 /* It's okay for the hook to refrain from storing anything. */
757 if (mouse_position_hook) 761 if (mouse_position_hook)
758 (*mouse_position_hook) (&f, 762 (*mouse_position_hook) (&f,
759 &lispy_dummy, &party_dummy, 763 &lispy_dummy, &party_dummy,
760 &x, &y, 764 &x, &y,
761 &long_dummy); 765 &long_dummy);
762 else
763 {
764 f = selected_frame;
765 x = y = Qnil;
766 }
767 766
768 XSET (lispy_dummy, Lisp_Frame, f); 767 XSET (lispy_dummy, Lisp_Frame, f);
769 return Fcons (lispy_dummy, Fcons (make_number (x), make_number (y))); 768 return Fcons (lispy_dummy, Fcons (x, y));
770} 769}
771 770
772DEFUN ("set-mouse-position", Fset_mouse_position, Sset_mouse_position, 3, 3, 0, 771DEFUN ("set-mouse-position", Fset_mouse_position, Sset_mouse_position, 3, 3, 0,