diff options
author | emersion <contact@emersion.fr> | 2017-10-28 11:58:34 +0200 |
---|---|---|
committer | emersion <contact@emersion.fr> | 2017-10-28 11:58:34 +0200 |
commit | fb0c9a356e1b9e86f4b29d3be739e8b17c5771e9 (patch) | |
tree | 3c23eec87cff62bb90e856b1f4dc9a2f4ec0d968 /rootston/cursor.c | |
parent | b97160238fa5b61fef81316102559c8c3e137cd2 (diff) |
Enforce resize bounds in rootston
Diffstat (limited to 'rootston/cursor.c')
-rw-r--r-- | rootston/cursor.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/rootston/cursor.c b/rootston/cursor.c index ece115c4..27f97724 100644 --- a/rootston/cursor.c +++ b/rootston/cursor.c @@ -160,6 +160,13 @@ void cursor_update_position(struct roots_input *input, uint32_t time) { width += dx; } + if (width < 0) { + width = 0; + } + if (height < 0) { + height = 0; + } + // TODO we might need one configure event for this if (active_x != input->active_view->x || active_y != input->active_view->y) { |