forked from enlightenment/efl
edje: Edje_Edit - add edje_edit_part_precide_is_inside functions.
Summary: Add two main functions - edje_edit_part_precise_is_inside_get - edje_edit_part_precise_is_inside_set Also support precise_is_inside into part's source code generation. @feature Reviewers: cedric, seoz, Hermet, raster CC: reutskiy.v.v, cedric Differential Revision: https://phab.enlightenment.org/D945 Signed-off-by: Cedric BAIL <c.bail@partner.samsung.com>
This commit is contained in:
parent
184720bf16
commit
30885daafa
|
@ -1215,6 +1215,25 @@ EAPI Eina_Bool edje_edit_part_repeat_events_get(Evas_Object *obj, const char *pa
|
|||
*/
|
||||
EAPI Eina_Bool edje_edit_part_repeat_events_set(Evas_Object *obj, const char *part, Eina_Bool repeat_events);
|
||||
|
||||
/** Get precise_is_inside for part.
|
||||
*
|
||||
* @param obj Object being edited.
|
||||
* @param part Part to get if it will enable point collision detection for the part.
|
||||
*
|
||||
* @return EINA_TRUE if point collision detection for the part is enabled, EINA_FALSE otherwise
|
||||
*/
|
||||
EAPI Eina_Bool edje_edit_part_precise_is_inside_get(Evas_Object *obj, const char *part);
|
||||
|
||||
/** Set precise_is_inside for part.
|
||||
*
|
||||
* @param obj Object being edited.
|
||||
* @param part Part to set if it will enable point collision detection for the part.
|
||||
* @param precise_is_inside EINA_TRUE if point collision detection for the part is enabled, EINA_FALSE otherwise
|
||||
*
|
||||
* @return EINA_TRUE if successful, EINA_FALSE otherwise.
|
||||
*/
|
||||
EAPI Eina_Bool edje_edit_part_precise_is_inside_set(Evas_Object *obj, const char *part, Eina_Bool precise_is_inside);
|
||||
|
||||
/** Get ignore_flags for part.
|
||||
*
|
||||
* @param obj Object being edited.
|
||||
|
|
|
@ -2895,6 +2895,26 @@ edje_edit_part_repeat_events_set(Evas_Object *obj, const char *part, Eina_Bool r
|
|||
return EINA_TRUE;
|
||||
}
|
||||
|
||||
|
||||
EAPI Eina_Bool
|
||||
edje_edit_part_precise_is_inside_get(Evas_Object *obj, const char *part)
|
||||
{
|
||||
GET_RP_OR_RETURN(0);
|
||||
|
||||
return rp->part->precise_is_inside;
|
||||
}
|
||||
|
||||
EAPI Eina_Bool
|
||||
edje_edit_part_precise_is_inside_set(Evas_Object *obj, const char *part, Eina_Bool precise_is_inside)
|
||||
{
|
||||
GET_RP_OR_RETURN(EINA_FALSE);
|
||||
|
||||
if (!rp->object) return EINA_FALSE;
|
||||
|
||||
rp->part->precise_is_inside = precise_is_inside;
|
||||
return EINA_TRUE;
|
||||
}
|
||||
|
||||
EAPI Evas_Event_Flags
|
||||
edje_edit_part_ignore_flags_get(Evas_Object *obj, const char *part)
|
||||
{
|
||||
|
@ -8094,7 +8114,8 @@ _edje_generate_source_of_part(Evas_Object *obj, Edje_Part *ep, Eina_Strbuf *buf)
|
|||
//TODO Support ignore_flags
|
||||
if (edje_edit_part_pointer_mode_get(obj, part) == EVAS_OBJECT_POINTER_MODE_NOGRAB)
|
||||
BUF_APPEND(I4"pointer_mode: NOGRAB;\n");
|
||||
//TODO Support precise_is_inside
|
||||
if (edje_edit_part_precise_is_inside_get(obj, part))
|
||||
BUF_APPEND(I4"precise_is_inside: 1;\n");
|
||||
//TODO Support use_alternate_font_metrics
|
||||
if ((str = edje_edit_part_clip_to_get(obj, part)))
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue