}
}
+
+EOLIAN void
+_evas_canvas_image_cache_flush(Eo *eo_e EINA_UNUSED, Evas_Public_Data *e)
+{
+ evas_canvas_async_block(e);
+ evas_render_rendering_wait(e);
+ if (_evas_engine_context(e))
+ e->engine.func->image_cache_flush(_evas_engine_context(e));
+}
+
+EOLIAN void
+_evas_canvas_image_cache_reload(Eo *eo_e, Evas_Public_Data *e)
+{
+ Evas_Layer *layer;
+
+ evas_canvas_async_block(e);
+ evas_image_cache_flush(eo_e);
+ EINA_INLIST_FOREACH(e->layers, layer)
+ {
+ Evas_Object_Protected_Data *obj;
+
+ layer->walking_objects++;
+ EINA_INLIST_FOREACH(layer->objects, obj)
+ {
+ if (efl_isa(obj->object, MY_CLASS))
+ {
+ _evas_image_unload(obj->object, obj, 1);
+ evas_object_inform_call_image_unloaded(obj->object);
+ }
+ }
+ layer->walking_objects--;
+ _evas_layer_flush_removes(layer);
+ }
+ evas_image_cache_flush(eo_e);
+ EINA_INLIST_FOREACH(e->layers, layer)
+ {
+ Evas_Object_Protected_Data *obj;
+
+ layer->walking_objects++;
+ EINA_INLIST_FOREACH(layer->objects, obj)
+ {
+ if (efl_isa(obj->object, MY_CLASS))
+ {
+ Evas_Image_Data *o = efl_data_scope_get(obj->object, MY_CLASS);
+ _evas_image_load(obj->object, obj, o);
+ o->changed = EINA_TRUE;
+ evas_object_change(obj->object, obj);
+ }
+ }
+ layer->walking_objects--;
+ _evas_layer_flush_removes(layer);
+ }
+ evas_image_cache_flush(eo_e);
+}
+
+EOLIAN static void
+_evas_canvas_image_cache_set(Eo *eo_e EINA_UNUSED, Evas_Public_Data *e, int size)
+{
+ if (size < 0) size = 0;
+ evas_canvas_async_block(e);
+ evas_render_rendering_wait(e);
+ if (_evas_engine_context(e))
+ e->engine.func->image_cache_set(_evas_engine_context(e), size);
+}
+
+EOLIAN static int
+_evas_canvas_image_cache_get(Eo *eo_e EINA_UNUSED, Evas_Public_Data *e)
+{
+ if (_evas_engine_context(e))
+ return e->engine.func->image_cache_get(_evas_engine_context(e));
+ return -1;
+}
+
+EOLIAN static Eina_Bool
+_evas_canvas_image_max_size_get(Eo *eo_e EINA_UNUSED, Evas_Public_Data *e, Eina_Size2D *max)
+{
+ int w = 0, h = 0;
+
+ 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);
+ *max = EINA_SIZE2D(w, h);
+ return EINA_TRUE;
+}
+
/* Legacy deprecated functions */
EAPI void
return o->content_hint;
}
-EOLIAN void
-_evas_canvas_image_cache_flush(Eo *eo_e EINA_UNUSED, Evas_Public_Data *e)
-{
- evas_canvas_async_block(e);
- evas_render_rendering_wait(e);
- if (_evas_engine_context(e))
- e->engine.func->image_cache_flush(_evas_engine_context(e));
-}
-
-EOLIAN void
-_evas_canvas_image_cache_reload(Eo *eo_e, Evas_Public_Data *e)
-{
- Evas_Layer *layer;
-
- evas_canvas_async_block(e);
- evas_image_cache_flush(eo_e);
- EINA_INLIST_FOREACH(e->layers, layer)
- {
- Evas_Object_Protected_Data *obj;
-
- layer->walking_objects++;
- EINA_INLIST_FOREACH(layer->objects, obj)
- {
- if (efl_isa(obj->object, MY_CLASS))
- {
- _evas_image_unload(obj->object, obj, 1);
- evas_object_inform_call_image_unloaded(obj->object);
- }
- }
- layer->walking_objects--;
- _evas_layer_flush_removes(layer);
- }
- evas_image_cache_flush(eo_e);
- EINA_INLIST_FOREACH(e->layers, layer)
- {
- Evas_Object_Protected_Data *obj;
-
- layer->walking_objects++;
- EINA_INLIST_FOREACH(layer->objects, obj)
- {
- if (efl_isa(obj->object, MY_CLASS))
- {
- Evas_Image_Data *o = efl_data_scope_get(obj->object, MY_CLASS);
- _evas_image_load(obj->object, obj, o);
- o->changed = EINA_TRUE;
- evas_object_change(obj->object, obj);
- }
- }
- layer->walking_objects--;
- _evas_layer_flush_removes(layer);
- }
- evas_image_cache_flush(eo_e);
-}
-
-EOLIAN void
-_evas_canvas_image_cache_set(Eo *eo_e EINA_UNUSED, Evas_Public_Data *e, int size)
-{
- if (size < 0) size = 0;
- evas_canvas_async_block(e);
- evas_render_rendering_wait(e);
- if (_evas_engine_context(e))
- e->engine.func->image_cache_set(_evas_engine_context(e), size);
-}
-
-EOLIAN int
-_evas_canvas_image_cache_get(Eo *eo_e EINA_UNUSED, Evas_Public_Data *e)
-{
- if (_evas_engine_context(e))
- return e->engine.func->image_cache_get(_evas_engine_context(e));
- return -1;
-}
-
-EOLIAN Eina_Bool
-_evas_canvas_image_max_size_get(Eo *eo_e EINA_UNUSED, Evas_Public_Data *e, Eina_Size2D *max)
-{
- int w = 0, h = 0;
-
- 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);
- *max = EINA_SIZE2D(w, h);
- return EINA_TRUE;
-}
-
void
_evas_image_unload(Evas_Object *eo_obj, Evas_Object_Protected_Data *obj, Eina_Bool dirty)
{