return: bool; [[$true on success, $false otherwise]]
}
values {
- maxw: int; [[Pointer to hold the return value in pixels of the maximum width.]]
- maxh: int; [[Pointer to hold the return value in pixels of the maximum height.]]
+ max: Eina.Size2D; [[The maximum image size (in pixels).]]
}
}
smart_objects_calculate {
}
EOLIAN static Eina_Bool
-_efl_ui_win_efl_canvas_image_max_size_get(Eo *obj EINA_UNUSED, Efl_Ui_Win_Data *sd, int *maxw, int *maxh)
+_efl_ui_win_efl_canvas_image_max_size_get(Eo *obj EINA_UNUSED, Efl_Ui_Win_Data *sd, Eina_Size2D *max)
{
- return evas_image_max_size_get(sd->evas, maxw, maxh);
+ return efl_canvas_image_max_size_get(sd->evas, max);
}
EOLIAN static void
}
EOLIAN Eina_Bool
-_evas_canvas_image_max_size_get(Eo *eo_e EINA_UNUSED, Evas_Public_Data *e, int *maxw, int *maxh)
+_evas_canvas_image_max_size_get(Eo *eo_e EINA_UNUSED, Evas_Public_Data *e, Eina_Size2D *max)
{
int w = 0, h = 0;
- if (maxw) *maxw = 0xffff;
- if (maxh) *maxh = 0xffff;
+ if (max) *max = EINA_SIZE2D(0xffff, 0xffff);
if (!e->engine.func->image_max_size_get) return EINA_FALSE;
+ if (!max) return EINA_TRUE;
e->engine.func->image_max_size_get(_evas_engine_context(e), &w, &h);
- if (maxw) *maxw = w;
- if (maxh) *maxh = h;
+ *max = EINA_SIZE2D(w, h);
return EINA_TRUE;
}