static XMotionEvent last_mouse_motion_event;
static Lisp_Object last_mouse_motion_frame;
-static void
+static int
note_mouse_movement (frame, event)
FRAME_PTR frame;
XMotionEvent *event;
frame->mouse_moved = 1;
last_mouse_scroll_bar = Qnil;
note_mouse_highlight (frame, -1, -1);
+ return 1;
}
/* Has the mouse moved off the glyph it was on at the last sighting? */
- else if (event->x < last_mouse_glyph.x
+ if (event->x < last_mouse_glyph.x
|| event->x >= last_mouse_glyph.x + last_mouse_glyph.width
|| event->y < last_mouse_glyph.y
|| event->y >= last_mouse_glyph.y + last_mouse_glyph.height)
note_mouse_highlight (frame, event->x, event->y);
/* Remember which glyph we're now on. */
remember_mouse_glyph (frame, event->x, event->y, &last_mouse_glyph);
+ return 1;
}
+
+ return 0;
}
\f
case MotionNotify:
{
previous_help_echo_string = help_echo_string;
- help_echo_string = help_echo_object = help_echo_window = Qnil;
- help_echo_pos = -1;
+ help_echo_string = Qnil;
if (dpyinfo->grabbed && last_mouse_frame
&& FRAME_LIVE_P (last_mouse_frame))
last_window=window;
}
- note_mouse_movement (f, &event.xmotion);
+ if (!note_mouse_movement (f, &event.xmotion))
+ help_echo_string = previous_help_echo_string;
}
else
{