From: Paul Eggert Date: Thu, 18 Jul 2013 21:16:33 +0000 (-0700) Subject: * keyboard.c: Try to fix typos in previous change. X-Git-Tag: emacs-24.3.90~173^2^2~42^2~45^2~387^2~1759^2~17 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=4d19d194070f508faeddcbbd4c31fd4ce720825a;p=emacs.git * keyboard.c: Try to fix typos in previous change. (DISPLAY_LIST_INFO): New macro. (kbd_buffer_get_event): Do not access members that are not present in X11. Revert nadvertent change of "!=" to "=". --- diff --git a/src/ChangeLog b/src/ChangeLog index de80ac168bd..164445432ec 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,10 @@ +2013-07-18 Paul Eggert + + * keyboard.c: Try to fix typos in previous change. + (DISPLAY_LIST_INFO): New macro. + (kbd_buffer_get_event): Do not access members that are not present + in X11. Revert nadvertent change of "!=" to "=". + 2013-07-18 Juanma Barranquero * keyboard.c (kbd_buffer_get_event): diff --git a/src/keyboard.c b/src/keyboard.c index f025d6c5dfa..fce466eca2f 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -4066,7 +4066,12 @@ kbd_buffer_get_event (KBOARD **kbp, } else if (event->kind == FOCUS_OUT_EVENT) { -#if defined (HAVE_NS) || defined (HAVE_X11) || defined (WINDOWSNT) +#if defined HAVE_X11 || defined HAVE_NS +# define DISPLAY_LIST_INFO(di) (di) +#elif defined WINDOWSNT +# define DISPLAY_LIST_INFO(di) FRAME_X_DISPLAY_INFO (di) +#endif +#ifdef DISPLAY_LIST_INFO #ifdef HAVE_NS struct ns_display_info *di; @@ -4076,11 +4081,13 @@ kbd_buffer_get_event (KBOARD **kbp, Lisp_Object frame = event->frame_or_window; bool focused = false; - for (di = x_display_list; di && ! focused; di = FRAME_X_DISPLAY_INFO (di)->next) - focused = FRAME_X_DISPLAY_INFO (di)->x_highlight_frame = 0; + for (di = x_display_list; + di && ! focused; + di = DISPLAY_LIST_INFO (di)->next) + focused = DISPLAY_LIST_INFO (di)->x_highlight_frame != 0; if (! focused) obj = make_lispy_focus_out (frame); -#endif /* HAVE_NS || HAVE_X11 || WINDOWSNT */ +#endif /* DISPLAY_LIST_INFO */ kbd_fetch_ptr = event + 1; }