elm_bg: handle alpha value in elm_obj_bg_color_set/get APIs for Eo.

No ChangeLog and NEWS for eo.
This commit is contained in:
Daniel Juyung Seo 2013-08-29 12:35:13 +09:00
parent 01c42920f2
commit 56c66418a1
2 changed files with 10 additions and 6 deletions

View File

@ -296,7 +296,7 @@ elm_bg_color_set(Evas_Object *obj,
int b)
{
ELM_BG_CHECK(obj);
eo_do(obj, elm_obj_bg_color_set(r, g, b));
eo_do(obj, elm_obj_bg_color_set(r, g, b, 255));
}
static void
@ -305,6 +305,7 @@ _color_set(Eo *obj, void *_pd, va_list *list)
int r = va_arg(*list, int);
int g = va_arg(*list, int);
int b = va_arg(*list, int);
int a = va_arg(*list, int);
Elm_Bg_Smart_Data *sd = _pd;
Elm_Widget_Smart_Data *wd = eo_data_scope_get(obj, ELM_OBJ_WIDGET_CLASS);
@ -325,7 +326,7 @@ _color_set(Eo *obj, void *_pd, va_list *list)
elm_layout_sizing_eval(obj);
}
evas_object_color_set(sd->rect, r, g, b, 255);
evas_object_color_set(sd->rect, r, g, b, a);
}
EAPI void
@ -335,7 +336,7 @@ elm_bg_color_get(const Evas_Object *obj,
int *b)
{
ELM_BG_CHECK(obj);
eo_do((Eo *) obj, elm_obj_bg_color_get(r, g, b));
eo_do((Eo *) obj, elm_obj_bg_color_get(r, g, b, NULL));
}
static void
@ -344,9 +345,10 @@ _color_get(Eo *obj EINA_UNUSED, void *_pd, va_list *list)
int *r = va_arg(*list, int *);
int *g = va_arg(*list, int *);
int *b = va_arg(*list, int *);
int *a = va_arg(*list, int *);
Elm_Bg_Smart_Data *sd = _pd;
evas_object_color_get(sd->rect, r, g, b, NULL);
evas_object_color_get(sd->rect, r, g, b, a);
}
EAPI void

View File

@ -88,12 +88,13 @@ enum
* @param[in] r
* @param[in] g
* @param[in] b
* @param[in] a
*
* @see elm_bg_color_set
*
* @ingroup Bg
*/
#define elm_obj_bg_color_set(r, g, b) ELM_OBJ_BG_ID(ELM_OBJ_BG_SUB_ID_COLOR_SET), EO_TYPECHECK(int, r), EO_TYPECHECK(int, g), EO_TYPECHECK(int, b)
#define elm_obj_bg_color_set(r, g, b, a) ELM_OBJ_BG_ID(ELM_OBJ_BG_SUB_ID_COLOR_SET), EO_TYPECHECK(int, r), EO_TYPECHECK(int, g), EO_TYPECHECK(int, b), EO_TYPECHECK(int, a)
/**
* @def elm_obj_bg_color_get
@ -104,12 +105,13 @@ enum
* @param[out] r
* @param[out] g
* @param[out] b
* @param[out] a
*
* @see elm_bg_color_get
*
* @ingroup Bg
*/
#define elm_obj_bg_color_get(r, g, b) ELM_OBJ_BG_ID(ELM_OBJ_BG_SUB_ID_COLOR_GET), EO_TYPECHECK(int *, r), EO_TYPECHECK(int *, g), EO_TYPECHECK(int *, b)
#define elm_obj_bg_color_get(r, g, b, a) ELM_OBJ_BG_ID(ELM_OBJ_BG_SUB_ID_COLOR_GET), EO_TYPECHECK(int *, r), EO_TYPECHECK(int *, g), EO_TYPECHECK(int *, b), EO_TYPECHECK(int *, a)
/**
* @def elm_obj_bg_load_size_set