Mercurial > emacs
changeset 47348:7e9809c820b0
(end_kbd_macro): New function.
(Fend_kbd_macro): Use it.
author | Kim F. Storm <storm@cua.dk> |
---|---|
date | Mon, 09 Sep 2002 22:33:51 +0000 |
parents | 28bab21524d4 |
children | 5c37672e24c8 |
files | src/macros.c |
diffstat | 1 files changed, 14 insertions(+), 6 deletions(-) [+] |
line wrap: on
line diff
--- a/src/macros.c Mon Sep 09 22:33:36 2002 +0000 +++ b/src/macros.c Mon Sep 09 22:33:51 2002 +0000 @@ -131,6 +131,19 @@ return Qnil; } +/* Finish defining the current keyboard macro. */ + +void +end_kbd_macro () +{ + current_kboard->defining_kbd_macro = Qnil; + update_mode_lines++; + current_kboard->Vlast_kbd_macro + = make_event_array ((current_kboard->kbd_macro_end + - current_kboard->kbd_macro_buffer), + current_kboard->kbd_macro_buffer); +} + DEFUN ("end-kbd-macro", Fend_kbd_macro, Send_kbd_macro, 0, 2, "p", doc: /* Finish defining a keyboard macro. The definition was started by \\[start-kbd-macro]. @@ -157,12 +170,7 @@ if (!NILP (current_kboard->defining_kbd_macro)) { - current_kboard->defining_kbd_macro = Qnil; - update_mode_lines++; - current_kboard->Vlast_kbd_macro - = make_event_array ((current_kboard->kbd_macro_end - - current_kboard->kbd_macro_buffer), - current_kboard->kbd_macro_buffer); + end_kbd_macro (); message ("Keyboard macro defined"); }