From 02013850f638520bed0d6c3f77eb9c80e0f73983 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 11 Jan 2014 13:54:08 +0200 Subject: [PATCH] Fix bug #16347 with updating redisplay of company-mode's "tooltip". src/xdisp.c (try_window_id): Don't use this function's optimizations if overlays in the buffer displayed by the window have changed since last redisplay. (message_dolog): Fix indentation. --- src/ChangeLog | 7 +++++++ src/xdisp.c | 8 +++++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index f258f38afbb..556fcce5fa5 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,10 @@ +2014-01-11 Eli Zaretskii + + * xdisp.c (try_window_id): Don't use this function's optimizations + if overlays in the buffer displayed by the window have changed + since last redisplay. (Bug#16347) + (message_dolog): Fix indentation. + 2014-01-11 Martin Rudalics * frame.c (frame_resize_pixelwise): Fix doc-string. diff --git a/src/xdisp.c b/src/xdisp.c index 99471d1df19..8efe3492db0 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -9854,7 +9854,7 @@ message_dolog (const char *m, ptrdiff_t nbytes, bool nlflag, bool multibyte) incrementing windows_or_buffers_changed even if *Messages* is shown in some window. So we must manually set windows_or_buffers_changed here to make up for that. */ - windows_or_buffers_changed = old_windows_or_buffers_changed; + windows_or_buffers_changed = old_windows_or_buffers_changed; bset_redisplay (current_buffer); set_buffer_internal (oldbuf); @@ -17417,6 +17417,12 @@ try_window_id (struct window *w) if (windows_or_buffers_changed || f->cursor_type_changed) GIVE_UP (2); + /* This function's optimizations cannot be used if overlays have + changed in the buffer displayed by the window, so give up if they + have. */ + if (w->last_overlay_modified != OVERLAY_MODIFF) + GIVE_UP (21); + /* Verify that narrowing has not changed. Also verify that we were not told to prevent redisplay optimizations. It would be nice to further -- 2.39.2