Merge pull request #235 from acrisci/bug/subsurface-location

bug: subsurface location calculation
This commit is contained in:
Drew DeVault 2017-10-07 17:03:14 -04:00 committed by GitHub
commit 906ed92e31

View file

@ -91,7 +91,7 @@ static struct wlr_subsurface *subsurface_at(struct wlr_surface *surface,
int sub_width = subsurface->surface->current->buffer_width;
int sub_height = subsurface->surface->current->buffer_height;
if ((sx > _sub_x && sx < _sub_x + sub_width) &&
(sy > _sub_y && sub_y < sub_y + sub_height)) {
(sy > _sub_y && sy < _sub_y + sub_height)) {
*sub_x = _sub_x;
*sub_y = _sub_y;
return subsurface;