diff options
author | Vincent Sanders <vince@netsurf-browser.org> | 2010-12-04 14:30:08 +0000 |
---|---|---|
committer | Vincent Sanders <vince@netsurf-browser.org> | 2010-12-04 14:30:08 +0000 |
commit | 7a3a96045ccc061b9d0bce59d2bc3532f2268660 (patch) | |
tree | 5ad9e6d57e4261b75b805eb53a50faa448f20f43 /framebuffer/fbtk/event.c | |
parent | 4cf27ef3387e52676483b4272072acf4d5ebcf29 (diff) | |
download | netsurf-7a3a96045ccc061b9d0bce59d2bc3532f2268660.tar.gz netsurf-7a3a96045ccc061b9d0bce59d2bc3532f2268660.tar.bz2 |
fix off by 1 in previous commit
svn path=/trunk/netsurf/; revision=10958
Diffstat (limited to 'framebuffer/fbtk/event.c')
-rw-r--r-- | framebuffer/fbtk/event.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/framebuffer/fbtk/event.c b/framebuffer/fbtk/event.c index 8dc1b02b3..d108af193 100644 --- a/framebuffer/fbtk/event.c +++ b/framebuffer/fbtk/event.c @@ -137,12 +137,12 @@ fbtk_warp_pointer(fbtk_widget_t *widget, int x, int y, bool relative) /* ensure cursor location lies within the root widget */ if (cloc.x0 < root->x) cloc.x0 = root->x; - if (cloc.x0 > (root->x + root->width)) - cloc.x0 = (root->x + root->width); + if (cloc.x0 >= (root->x + root->width)) + cloc.x0 = (root->x + root->width) - 1; if (cloc.y0 < root->y) cloc.y0 = root->y; - if (cloc.y0 > (root->y + root->height)) - cloc.y0 = (root->y + root->height); + if (cloc.y0 >= (root->y + root->height)) + cloc.y0 = (root->y + root->height) - 1; if (root->u.root.grabbed == NULL) { /* update the pointer cursor */ |