diff options
author | Daniel Friesel <derf@derf.homelinux.org> | 2010-04-10 13:12:14 +0200 |
---|---|---|
committer | Daniel Friesel <derf@derf.homelinux.org> | 2010-04-10 13:13:36 +0200 |
commit | f7168c8684e7c05cb66307f11ea79e93a8b539ab (patch) | |
tree | d5fa20e9f7f6bd4b0c58be5d1c3f86ef2cf65fd0 /src/events.c | |
parent | 1657b7cedc9021a0b641ba6422bd6d4d3a795246 (diff) |
events.c: Make pointer warping work for zoomed images
Diffstat (limited to 'src/events.c')
-rw-r--r-- | src/events.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/events.c b/src/events.c index 92c01cd..a5af3f2 100644 --- a/src/events.c +++ b/src/events.c @@ -473,7 +473,7 @@ static void feh_event_handle_MotionNotify(XEvent * ev) winwid->click_offset_x -= winwid->w - 4; } else if ((ev->xmotion.x <= 1) && (winwid->click_offset_x - <= winwid->im_w - winwid->w - 3)) + <= (winwid->im_w * winwid->zoom) - winwid->w - 3)) { XWarpPointer(disp, None, winwid->win, 0, 0, 0, 0, winwid->w - 4, ev->xmotion.y); @@ -487,7 +487,7 @@ static void feh_event_handle_MotionNotify(XEvent * ev) winwid->click_offset_y -= winwid->h - 4; } else if ((ev->xmotion.y <= 1) && (winwid->click_offset_y - <= winwid->im_h - winwid->h - 3)) + <= (winwid->im_h * winwid->zoom) - winwid->h - 3)) { XWarpPointer(disp, None, winwid->win, 0, 0, 0, 0, ev->xmotion.x, winwid->h - 4); |