edje/calc: clamp part calc size to 0

this could previously have been negative

@fix

Reviewed-by: Cedric BAIL <cedric.bail@free.fr>
Differential Revision: https://phab.enlightenment.org/D9431
This commit is contained in:
Mike Blumenkrantz 2019-07-29 10:58:07 -04:00 committed by Cedric BAIL
parent 36ff0a012c
commit 895ffd93cc
1 changed files with 2 additions and 0 deletions

View File

@ -3018,7 +3018,9 @@ _edje_part_recalc_single(Edje *ed,
params->req.x = TO_INT(params->eval.x);
params->req.y = TO_INT(params->eval.y);
params->req.w = TO_INT(params->eval.w);
if (params->req.w < 0) params->req.w = 0;
params->req.h = TO_INT(params->eval.h);
if (params->req.h < 0) params->req.h = 0;
/* adjust for min size */
_edje_part_recalc_single_min(desc, params, minw, minh, apref);