gtk: Fix the relative pointer tracking mode
The relative pointer tracking mode was still buggy even after the previous fix of the motion-notify-event since the events are filtered out when the pointer moves outside the drawing window due to the boundary check for the absolute mode. This patch fixes the issue by moving the unnecessary boundary check into the if block of absolute mode, and keep the coordinate in the relative mode even if it's outside the drawing area. But this makes the coordinate (last_x, last_y) possibly pointing to (-1,-1), introduce a new flag to indicate the last coordinate has been updated. Reference: https://bugzilla.novell.com/show_bug.cgi?id=849587Tested-by: NCole Robinson <crobinso@redhat.com> Reviewed-by: NCole Robinson <crobinso@redhat.com> Tested-by: NMichael S. Tsirkin <mst@redhat.com> Signed-off-by: NTakashi Iwai <tiwai@suse.de> Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
Showing
想要评论请 注册 或 登录