From d873120270cef81f06d607ec9c149e8165b3d80e Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Fri, 23 Mar 2001 04:24:35 +0000 Subject: [PATCH] (init_iterator): Check WINDOWP before using XWINDOW. (string_buffer_position): Use `make_number'. --- src/ChangeLog | 20 +++++++++++++------- src/xdisp.c | 5 +++-- 2 files changed, 16 insertions(+), 9 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index cb5758c1e7d..cc3e004390e 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,10 @@ +2001-03-22 Stefan Monnier + + * xterm.c (note_mouse_highlight): Dec the int, not the Lisp_Object. + + * xdisp.c (init_iterator): Check WINDOWP before using XWINDOW. + (string_buffer_position): Use `make_number'. + 2001-03-22 Gerd Moellmann * xfaces.c (x_update_menu_appearance): Renamed from @@ -9,17 +16,16 @@ * xfaces.c (x_set_menu_resources_from_menu_face) [USE_X_TOOLKIT]: Removed, together with subroutines. (x_set_menu_face_resources) [USE_X_TOOLKIT]: New function. - (realize_basic_faces) [USE_X_TOOLKIT]: Call - x_set_menu_face_resources. + (realize_basic_faces) [USE_X_TOOLKIT]: Call x_set_menu_face_resources. - * dispextern.h (x_set_menu_resources_from_menu_face): Remove - prototype. + * dispextern.h (x_set_menu_resources_from_menu_face): + Remove prototype. - * xmenu.c (update_frame_menubar, set_frame_menubar, xmenu_show): + * xmenu.c (update_frame_menubar, set_frame_menubar, xmenu_show): Remove calls to x_set_menu_resources_from_menu_face. - * xfaces.c (xm_set_menu_resources_from_menu_face): Remove - #ifndef LESSTIF_VERSION. + * xfaces.c (xm_set_menu_resources_from_menu_face): + Remove #ifndef LESSTIF_VERSION. * xmenu.c: Include widget.h. (single_submenu): Return int. Some cleanup. diff --git a/src/xdisp.c b/src/xdisp.c index 274c133aa87..5bef4697058 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -1524,6 +1524,7 @@ init_iterator (it, w, charpos, bytepos, row, base_face_id) /* Or show the region if we are in the mini-buffer and W is the window the mini-buffer refers to. */ || (MINI_WINDOW_P (XWINDOW (selected_window)) + && WINDOWP (Vminibuf_scroll_window) && w == XWINDOW (Vminibuf_scroll_window)))) { int charpos = marker_position (current_buffer->mark); @@ -3093,7 +3094,7 @@ string_buffer_position (w, string, around_charpos) const int MAX_DISTANCE = 1000; int found = 0; - pos = around_charpos; + pos = make_number (around_charpos); limit = make_number (min (XINT (pos) + MAX_DISTANCE, ZV)); while (!found && !EQ (pos, limit)) { @@ -3106,7 +3107,7 @@ string_buffer_position (w, string, around_charpos) if (!found) { - pos = around_charpos; + pos = make_number (around_charpos); limit = make_number (max (XINT (pos) - MAX_DISTANCE, BEGV)); while (!found && !EQ (pos, limit)) { -- 2.39.2