}
static void
-_edje_real_part_image_set(Edje *ed, Edje_Real_Part *ep, FLOAT_T pos)
+_edje_real_part_image_set(Edje *ed, Edje_Real_Part *ep, Edje_Real_Part_Set **set, FLOAT_T pos)
{
int image_id;
int image_count, image_num;
&ep->param1.set,
(Edje_Part_Description_Image*) ep->param1.description,
NULL);
+ *set = ep->param1.set;
if (image_id < 0)
{
Edje_Image_Directory_Entry *ie;
&ep->param1.set,
(Edje_Part_Description_Image*) ep->param1.description,
NULL);
+ *set = ep->param1.set;
}
else
if (ep->param2)
&ep->param2->set,
(Edje_Part_Description_Image*) ep->param2->description,
NULL);
+ *set = ep->param2->set;
}
else
{
imid = ((Edje_Part_Description_Image*) ep->param2->description)->image.tweens[image_num - 1];
image_id = _edje_image_find(ep->object, ed, NULL, NULL, imid);
+ *set = NULL;
}
}
if (image_id < 0)
/* We only need pose to find the right image that would be displayed,
and the right aspect ratio in that case */
- _edje_real_part_image_set(ed, ep, pos);
+ _edje_real_part_image_set(ed, ep, NULL, pos);
evas_object_image_size_get(ep->object, &w, &h);
amin = amax = DIV(FROM_INT(w), FROM_INT(h));
}
Edje_Real_Part_Set *set;
Edje_Part_Description_Image *img_desc = (Edje_Part_Description_Image*) desc;
- _edje_real_part_image_set(ed, ep, pos);
+ _edje_real_part_image_set(ed, ep, &set, pos);
/* border */
params->type.common.spec.image.l = img_desc->image.border.l;
params->type.common.spec.image.border_scale_by = img_desc->image.border.scale_by;
- set = ep->param1.set;
if (set && set->set)
{
#define SET_BORDER_DEFINED(Result, Value) Result = Value ? Value : Result;
/* Yes, if someone set aspect preference to SOURCE and also max,min
to SOURCE, it will be under efficient, but who cares at the
moment. */
- _edje_real_part_image_set(ed, ep, pos);
+ _edje_real_part_image_set(ed, ep, NULL, pos);
evas_object_image_size_get(ep->object, &w, &h);
if (chosen_desc->min.limit)
_edje_image_recalc_apply(Edje *ed, Edje_Real_Part *ep, Edje_Calc_Params *p3, Edje_Part_Description_Image *chosen_desc, FLOAT_T pos)
{
FLOAT_T sc;
+ Edje_Real_Part_Set *set;
sc = DIV(ed->scale, ed->file->base_scale);
if (sc == ZERO) sc = DIV(_edje_scale, ed->file->base_scale);
+
+ _edje_real_part_image_set(ed, ep, &set, pos);
+ if (set && set->set)
+ {
+#define SET_BORDER_DEFINED(Result, Value) Result = Value ? Value : Result;
+ SET_BORDER_DEFINED(p3->type.common.spec.image.l, set->entry->border.l);
+ SET_BORDER_DEFINED(p3->type.common.spec.image.r, set->entry->border.r);
+ SET_BORDER_DEFINED(p3->type.common.spec.image.t, set->entry->border.t);
+ SET_BORDER_DEFINED(p3->type.common.spec.image.b, set->entry->border.b);
+
+ SET_BORDER_DEFINED(p3->type.common.spec.image.border_scale_by, set->entry->border.scale_by);
+ }
+
eo_do(ep->object,
evas_obj_image_fill_set(p3->type.common.fill.x, p3->type.common.fill.y,
p3->type.common.fill.w, p3->type.common.fill.h),
evas_object_image_border_center_fill_set(ep->object, EVAS_BORDER_FILL_NONE);
else if (chosen_desc->image.border.no_fill == 2)
evas_object_image_border_center_fill_set(ep->object, EVAS_BORDER_FILL_SOLID);
-
- _edje_real_part_image_set(ed, ep, pos);
}
static Edje_Real_Part *