edje - add new color class apply func to force cc to apply now

v-1.26.0
Carsten Haitzler 2 years ago
parent 694136e4c8
commit 2b91c4d9b8
  1. 10
      src/lib/edje/Edje_Common.h
  2. 16
      src/lib/edje/edje_util.c

@ -1452,6 +1452,16 @@ EAPI void edje_password_show_last_timeout_set(double password_show_last_timeout)
*/
EAPI Eina_Bool edje_color_class_set (const char *color_class, int r, int g, int b, int a, int r2, int g2, int b2, int a2, int r3, int g3, int b3, int a3);
/**
* @brief Applies changes mad when setting Edje color classes.
*
* This forces all changes to color classes made by (for example)
* edje_color_class_set() to actually take effect.
*
* @since 1.26
*/
EAPI void edje_color_class_apply (void);
/**
* @brief Gets Edje color class.
*

@ -712,6 +712,22 @@ edje_color_class_set(const char *color_class, int r, int g, int b, int a, int r2
return result;
}
EAPI void
edje_color_class_apply(void)
{
Edje *ed;
EINA_INLIST_FOREACH(_edje_edjes, ed)
{
ed->dirty = EINA_TRUE;
ed->recalc_call = EINA_TRUE;
#ifdef EDJE_CALC_CACHE
ed->all_part_change = EINA_TRUE;
#endif
_edje_recalc(ed);
}
}
EOLIAN Eina_Bool
_edje_global_efl_gfx_color_class_color_class_set(Eo *obj EINA_UNUSED, void *pd EINA_UNUSED,
const char *color_class, Efl_Gfx_Color_Class_Layer layer, int r, int g, int b, int a)

Loading…
Cancel
Save