forked from enlightenment/efl
ecore_animator: Ensure correct start/end values are returned.
Make sure pos_map(0) == 0 and pos_map(1) == 1 Signed-off-by: Daniel Willmann <d.willmann@samsung.com>
This commit is contained in:
parent
62325dd693
commit
04829b9244
|
@ -337,9 +337,9 @@ ecore_animator_pos_map(double pos,
|
||||||
double v2)
|
double v2)
|
||||||
{
|
{
|
||||||
/* purely functional - locking not required */
|
/* purely functional - locking not required */
|
||||||
if (pos > 1.0) pos = 1.0;
|
if (pos >= 1.0) return 1.0;
|
||||||
else if (pos < 0.0)
|
else if (pos <= 0.0)
|
||||||
pos = 0.0;
|
return 0.0;
|
||||||
switch (map)
|
switch (map)
|
||||||
{
|
{
|
||||||
case ECORE_POS_MAP_LINEAR:
|
case ECORE_POS_MAP_LINEAR:
|
||||||
|
@ -390,6 +390,7 @@ ecore_animator_pos_map(double pos,
|
||||||
default:
|
default:
|
||||||
return pos;
|
return pos;
|
||||||
}
|
}
|
||||||
|
|
||||||
return pos;
|
return pos;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue