From: Karoly Lorentey Date: Mon, 27 Jun 2005 00:57:09 +0000 (+0000) Subject: New C function `push_display_kboard'. X-Git-Tag: emacs-pretest-23.0.90~11236^2~141^2~236 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=e589efa546443ad7a61ec3867b46cda884d22de5;p=emacs.git New C function `push_display_kboard'. * src/keyboard.c (push_display_kboard): New function. * src/keyboard.h (push_display_kboard): Declare it. git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-364 --- diff --git a/src/keyboard.c b/src/keyboard.c index 6fb95f5d815..a906146df4a 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -1111,6 +1111,22 @@ struct kboard_stack static struct kboard_stack *kboard_stack; +void +push_display_kboard (d) + struct display *d; +{ +#ifdef MULTI_KBOARD + struct kboard_stack *p + = (struct kboard_stack *) xmalloc (sizeof (struct kboard_stack)); + + p->next = kboard_stack; + p->kboard = current_kboard; + kboard_stack = p; + + current_kboard = d->kboard; +#endif +} + void push_frame_kboard (f) FRAME_PTR f; @@ -10803,7 +10819,7 @@ delete_kboard (kb) && FRAMEP (selected_frame) && FRAME_LIVE_P (XFRAME (selected_frame))) { - current_kboard = XFRAME (selected_frame)->kboard; + current_kboard = XFRAME (selected_frame)->display->kboard; if (current_kboard == kb) abort (); } diff --git a/src/keyboard.h b/src/keyboard.h index de2254952b4..91226ce6e65 100644 --- a/src/keyboard.h +++ b/src/keyboard.h @@ -315,6 +315,7 @@ extern void init_kboard P_ ((KBOARD *)); extern void delete_kboard P_ ((KBOARD *)); extern void single_kboard_state P_ ((void)); extern void not_single_kboard_state P_ ((KBOARD *)); +extern void push_display_kboard P_ ((struct display *)); extern void push_frame_kboard P_ ((struct frame *)); extern void pop_frame_kboard P_ ((void)); extern void record_asynch_buffer_change P_ ((void));