Merge pull request #1014 from RyanDwyer/fix-wlr-box-contains-point

Fix wlr_box_contains_point comparison
This commit is contained in:
emersion 2018-05-29 19:03:29 +01:00 committed by GitHub
commit 87fe9f3466
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -61,8 +61,8 @@ bool wlr_box_contains_point(const struct wlr_box *box, double x, double y) {
if (wlr_box_empty(box)) { if (wlr_box_empty(box)) {
return false; return false;
} else { } else {
return x >= box->x && x <= box->x + box->width && return x >= box->x && x < box->x + box->width &&
y >= box->y && y <= box->y + box->height; y >= box->y && y < box->y + box->height;
} }
} }