Elementary els_scroller: Fix a bug with ui-mirroring.

Bug happened when child_w < scroller_w and ui-mirroring was on.
The position calculated was smaller than 0 and thus not correct.

SVN revision: 57194
This commit is contained in:
Tom Hacohen 2011-02-20 16:00:00 +00:00
parent b0d87077a5
commit 83d2421b60
1 changed files with 3 additions and 2 deletions

View File

@ -158,10 +158,11 @@ _elm_smart_scroller_x_mirrored_get(Evas_Object *obj, Evas_Coord x)
{
API_ENTRY return x;
Evas_Coord cw, ch, w;
Evas_Coord cw, ch, w, ret;
elm_smart_scroller_child_viewport_size_get(obj, &w, NULL);
sd->pan_func.child_size_get(sd->pan_obj, &cw, &ch);
return (cw - (x + w));
ret = (cw - (x + w));
return (ret >= 0) ? ret : 0;
}
void