forked from enlightenment/efl
efl ui image - fix scal to fill - broken with non-rect src images
@fix
This commit is contained in:
parent
5ed0161564
commit
87bcc82976
|
@ -242,12 +242,9 @@ _image_sizing_eval(Eo *obj, Efl_Ui_Image_Data *sd, Evas_Object *img)
|
|||
w = ((double)iw * h) / (double)ih;
|
||||
break;
|
||||
case EFL_GFX_IMAGE_SCALE_METHOD_EXPAND:
|
||||
if ((iw - ow) < (ih - oh))
|
||||
{
|
||||
w = ow;
|
||||
h = ((double)ih * w) / (double)iw;
|
||||
}
|
||||
else
|
||||
w = ow;
|
||||
h = ((double)ih * w) / (double)iw;
|
||||
if (h < oh)
|
||||
{
|
||||
h = oh;
|
||||
w = ((double)iw * h) / (double)ih;
|
||||
|
|
Loading…
Reference in New Issue