forked from enlightenment/efl
in order to fix some horridibubble things. i had to add 4 api's. ugh.
done. working. now... still 1 more bug. seems to be a changed flag bug too in dlip 2 test in scrolling list after map anim finished. smaller bug to deal with now. ugh. bug one bug to the other SVN revision: 51849
This commit is contained in:
parent
b5dc226bc1
commit
4c63db37f8
|
@ -641,7 +641,9 @@ typedef void (*Evas_Async_Events_Put_Cb)(void *target, Evas_Callback_Type t
|
|||
EAPI void evas_focus_in (Evas *e);
|
||||
EAPI void evas_focus_out (Evas *e);
|
||||
EAPI Eina_Bool evas_focus_state_get (const Evas *e) EINA_PURE;
|
||||
|
||||
EAPI void evas_nochange_push (Evas *e);
|
||||
EAPI void evas_nochange_pop (Evas *e);
|
||||
|
||||
EAPI void evas_data_attach_set (Evas *e, void *data) EINA_ARG_NONNULL(1);
|
||||
EAPI void *evas_data_attach_get (const Evas *e) EINA_WARN_UNUSED_RESULT EINA_ARG_NONNULL(1) EINA_PURE;
|
||||
|
||||
|
@ -1020,6 +1022,9 @@ typedef void (*Evas_Async_Events_Put_Cb)(void *target, Evas_Callback_Type t
|
|||
EAPI void evas_object_precise_is_inside_set (Evas_Object *obj, Eina_Bool precise) EINA_ARG_NONNULL(1);
|
||||
EAPI Eina_Bool evas_object_precise_is_inside_get (const Evas_Object *obj) EINA_WARN_UNUSED_RESULT EINA_ARG_NONNULL(1) EINA_PURE;
|
||||
|
||||
EAPI void evas_object_static_clip_set (Evas_Object *obj, Eina_Bool is_static_clip) EINA_ARG_NONNULL(1);
|
||||
EAPI Eina_Bool evas_object_static_clip_get (const Evas_Object *obj) EINA_WARN_UNUSED_RESULT EINA_ARG_NONNULL(1) EINA_PURE;
|
||||
|
||||
/**
|
||||
* @defgroup Evas_Object_Group_Find Finding Objects
|
||||
*
|
||||
|
@ -1729,7 +1734,7 @@ struct _Evas_Smart_Cb_Description
|
|||
EAPI void *evas_smart_data_get (const Evas_Smart *s) EINA_WARN_UNUSED_RESULT EINA_ARG_NONNULL(1) EINA_PURE;
|
||||
EAPI const Evas_Smart_Cb_Description *evas_smart_callback_description_find(const Evas_Smart *s, const char *name) EINA_ARG_NONNULL(1, 2) EINA_PURE;
|
||||
|
||||
EAPI Eina_Bool evas_smart_class_inherit_full (Evas_Smart_Class *sc, const Evas_Smart_Class *parent_sc, unsigned int parent_sc_size) EINA_ARG_NONNULL(1, 2);
|
||||
EAPI Eina_Bool evas_smart_class_inherit_full (Evas_Smart_Class *sc, const Evas_Smart_Class *parent_sc, unsigned int parent_sc_size) EINA_ARG_NONNULL(1, 2);
|
||||
/**
|
||||
* @def evas_smart_class_inherit
|
||||
* Easy to use version of evas_smart_class_inherit_full().
|
||||
|
@ -1772,7 +1777,7 @@ struct _Evas_Smart_Cb_Description
|
|||
|
||||
EAPI Eina_Bool evas_object_smart_callbacks_descriptions_set(Evas_Object *obj, const Evas_Smart_Cb_Description *descriptions) EINA_ARG_NONNULL(1);
|
||||
EAPI void evas_object_smart_callbacks_descriptions_get(const Evas_Object *obj, const Evas_Smart_Cb_Description ***class_descriptions, unsigned int *class_count, const Evas_Smart_Cb_Description ***instance_descriptions, unsigned int *instance_count) EINA_ARG_NONNULL(1);
|
||||
EAPI void evas_object_smart_callback_description_find(const Evas_Object *obj, const char *name, const Evas_Smart_Cb_Description **class_description, const Evas_Smart_Cb_Description **instance_description) EINA_ARG_NONNULL(1, 2);
|
||||
EAPI void evas_object_smart_callback_description_find(const Evas_Object *obj, const char *name, const Evas_Smart_Cb_Description **class_description, const Evas_Smart_Cb_Description **instance_description) EINA_ARG_NONNULL(1, 2);
|
||||
|
||||
EAPI void evas_object_smart_changed (Evas_Object *obj) EINA_ARG_NONNULL(1);
|
||||
EAPI void evas_object_smart_need_recalculate_set(Evas_Object *obj, Eina_Bool value) EINA_ARG_NONNULL(1);
|
||||
|
|
|
@ -1114,6 +1114,36 @@ evas_focus_state_get(const Evas *e)
|
|||
return e->focus;
|
||||
}
|
||||
|
||||
/**
|
||||
* Push the nochange flag up 1
|
||||
*
|
||||
* This tells evas, that while the nochange flag is greater than 0, do not
|
||||
* mark objects as "changed" when making changes.
|
||||
*
|
||||
* @param e The evas to change information.
|
||||
* @ingroup Evas_Canvas
|
||||
*/
|
||||
EAPI void
|
||||
evas_nochange_push(Evas *e)
|
||||
{
|
||||
e->nochange++;
|
||||
}
|
||||
|
||||
/**
|
||||
* Pop the nochange flag down 1
|
||||
*
|
||||
* This tells evas, that while the nochange flag is greater than 0, do not
|
||||
* mark objects as "changed" when making changes.
|
||||
*
|
||||
* @param e The evas to change information.
|
||||
* @ingroup Evas_Canvas
|
||||
*/
|
||||
EAPI void
|
||||
evas_nochange_pop(Evas *e)
|
||||
{
|
||||
e->nochange--;
|
||||
}
|
||||
|
||||
void
|
||||
_evas_walk(Evas *e)
|
||||
{
|
||||
|
@ -1275,4 +1305,3 @@ evas_data_argb_unpremul(unsigned int *data, unsigned int len)
|
|||
if (!data || (len < 1)) return;
|
||||
evas_common_convert_argb_unpremul(data, len);
|
||||
}
|
||||
|
||||
|
|
|
@ -85,6 +85,13 @@ evas_object_change(Evas_Object *obj)
|
|||
Eina_List *l;
|
||||
Evas_Object *obj2;
|
||||
|
||||
if (obj->layer->evas->nochange)
|
||||
{
|
||||
// printf("nochange %p\n", obj);
|
||||
return;
|
||||
}
|
||||
// else
|
||||
// printf("ch %p\n", obj);
|
||||
obj->layer->evas->changed = 1;
|
||||
if (obj->changed) return;
|
||||
// obj->changed = 1;
|
||||
|
@ -1672,3 +1679,42 @@ evas_object_precise_is_inside_get(const Evas_Object *obj)
|
|||
MAGIC_CHECK_END();
|
||||
return obj->precise_is_inside;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set a hint flag on the object that this is used as a static "clipper".
|
||||
*
|
||||
* This is a hint to evas that this object is used as a big static clipper
|
||||
* andshouldnt be moved with children and otherwise considered specially. The
|
||||
* Default is off.
|
||||
*
|
||||
* @param obj The given object.
|
||||
* @param is_static_clip The static clip flag (on or off)
|
||||
* @ingroup Evas_Object_Group_Extras
|
||||
*/
|
||||
EAPI void
|
||||
evas_object_static_clip_set(Evas_Object *obj, Eina_Bool is_static_clip)
|
||||
{
|
||||
MAGIC_CHECK(obj, Evas_Object, MAGIC_OBJ);
|
||||
return;
|
||||
MAGIC_CHECK_END();
|
||||
obj->is_static_clip = is_static_clip;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get static "clipper" hint flag.
|
||||
*
|
||||
* @see evas_object_static_clip_set()
|
||||
*
|
||||
* @param obj The given object.
|
||||
* @return The static clip flag (on or off)
|
||||
* @ingroup Evas_Object_Group_Extras
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
evas_object_static_clip_get(const Evas_Object *obj)
|
||||
{
|
||||
MAGIC_CHECK(obj, Evas_Object, MAGIC_OBJ);
|
||||
return 0;
|
||||
MAGIC_CHECK_END();
|
||||
return obj->is_static_clip;
|
||||
}
|
||||
|
||||
|
|
|
@ -31,7 +31,12 @@ evas_object_smart_move_children_relative(Evas_Object *obj, Evas_Coord dx, Evas_C
|
|||
{
|
||||
Evas_Coord orig_x, orig_y;
|
||||
|
||||
evas_object_geometry_get(child, &orig_x, &orig_y, NULL, NULL);
|
||||
// shortcut as we are in evas
|
||||
// evas_object_geometry_get(child, &orig_x, &orig_y, NULL, NULL);
|
||||
if (child->delete_me) continue;
|
||||
if (child->is_static_clip) continue;
|
||||
orig_x = child->cur.geometry.x;
|
||||
orig_y = child->cur.geometry.y;
|
||||
evas_object_move(child, orig_x + dx, orig_y + dy);
|
||||
}
|
||||
|
||||
|
@ -68,6 +73,7 @@ evas_object_smart_clipped_smart_add(Evas_Object *obj)
|
|||
|
||||
cso->evas = evas_object_evas_get(obj);
|
||||
clipper = evas_object_rectangle_add(cso->evas);
|
||||
evas_object_static_clip_set(clipper, 1);
|
||||
cso->clipper = NULL;
|
||||
evas_object_smart_member_add(clipper, obj);
|
||||
cso->clipper = clipper;
|
||||
|
|
|
@ -576,10 +576,10 @@ pending_change(void *data, void *gdata __UNUSED__)
|
|||
if (obj->delete_me) return EINA_FALSE;
|
||||
if (obj->pre_render_done)
|
||||
{
|
||||
RD(" OBJ [%p] pending change %i -> 0, pre %i\n", obj, obj->changed, obj->pre_render_done);
|
||||
obj->pre_render_done = 0;
|
||||
RD(" OBJ [%p] pending change %i -> 0, pre %i\n", obj, obj->changed, obj->pre_render_done);
|
||||
obj->pre_render_done = 0;
|
||||
//// FIXME: this wipes out changes
|
||||
obj->changed = 0;
|
||||
obj->changed = 0;
|
||||
}
|
||||
return obj->changed ? EINA_TRUE : EINA_FALSE;
|
||||
}
|
||||
|
@ -683,12 +683,18 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface,
|
|||
if (obj->smart.smart)
|
||||
{
|
||||
Evas_Object *obj2;
|
||||
|
||||
|
||||
EINA_INLIST_FOREACH(evas_object_smart_members_get_direct(obj), obj2)
|
||||
{
|
||||
if (!evas_object_is_visible(obj2) &&
|
||||
!evas_object_was_visible(obj2))
|
||||
{
|
||||
obj2->changed = 0;
|
||||
continue;
|
||||
}
|
||||
if (obj2->changed)
|
||||
{
|
||||
obj2->changed = 0;
|
||||
obj2->changed = 0;
|
||||
changed = 1;
|
||||
break;
|
||||
}
|
||||
|
@ -699,8 +705,8 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface,
|
|||
{
|
||||
if (obj->changed)
|
||||
{
|
||||
changed = 1;
|
||||
obj->changed = 0;
|
||||
changed = 1;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -802,20 +808,6 @@ evas_render_mapped(Evas *e, Evas_Object *obj, void *context, void *surface,
|
|||
e->engine.data.context,
|
||||
x + off_x, y + off_y, w, h);
|
||||
}
|
||||
if ((obj->cur.cache.clip.r == 255) &&
|
||||
(obj->cur.cache.clip.g == 255) &&
|
||||
(obj->cur.cache.clip.b == 255) &&
|
||||
(obj->cur.cache.clip.a == 255))
|
||||
obj->layer->evas->engine.func->context_multiplier_unset
|
||||
(e->engine.data.output, e->engine.data.context);
|
||||
else
|
||||
obj->layer->evas->engine.func->context_multiplier_set
|
||||
(e->engine.data.output, e->engine.data.context,
|
||||
obj->cur.cache.clip.r, obj->cur.cache.clip.g,
|
||||
obj->cur.cache.clip.b, obj->cur.cache.clip.a);
|
||||
obj->layer->evas->engine.func->context_render_op_set
|
||||
(e->engine.data.output, e->engine.data.context,
|
||||
obj->cur.render_op);
|
||||
}
|
||||
if (obj->cur.cache.clip.visible)
|
||||
obj->layer->evas->engine.func->image_map4_draw
|
||||
|
@ -1501,7 +1493,7 @@ evas_render_object_recalc(Evas_Object *obj)
|
|||
#ifndef EVAS_FRAME_QUEUING
|
||||
if ((!obj->changed) && (obj->delete_me < 2))
|
||||
#else
|
||||
if ((!obj->changed) )
|
||||
if ((!obj->changed))
|
||||
#endif
|
||||
{
|
||||
Evas *e;
|
||||
|
@ -1509,7 +1501,7 @@ evas_render_object_recalc(Evas_Object *obj)
|
|||
e = obj->layer->evas;
|
||||
if ((!e) || (e->cleanup)) return;
|
||||
#ifdef EVAS_FRAME_QUEUING
|
||||
if (obj->delete_me >= evas_common_frameq_get_frameq_sz() + 2) return;
|
||||
if (obj->delete_me >= evas_common_frameq_get_frameq_sz() + 2) return;
|
||||
#endif
|
||||
eina_array_push(&e->pending_objects, obj);
|
||||
obj->changed = 1;
|
||||
|
|
|
@ -226,24 +226,6 @@ struct _Evas_Callbacks
|
|||
Eina_Inlist *callbacks;
|
||||
int walking_list;
|
||||
unsigned char deletions_waiting : 1;
|
||||
/*
|
||||
Eina_Inlist *down;
|
||||
Eina_Inlist *up;
|
||||
Eina_Inlist *move;
|
||||
Eina_Inlist *in;
|
||||
Eina_Inlist *out;
|
||||
Eina_Inlist *wheel;
|
||||
Eina_Inlist *key_down;
|
||||
Eina_Inlist *key_up;
|
||||
Eina_Inlist *free;
|
||||
Eina_Inlist *obj_focus_in;
|
||||
Eina_Inlist *obj_focus_out;
|
||||
Eina_Inlist *obj_show;
|
||||
Eina_Inlist *obj_hide;
|
||||
Eina_Inlist *obj_move;
|
||||
Eina_Inlist *obj_resize;
|
||||
Eina_Inlist *obj_restack;
|
||||
*/
|
||||
};
|
||||
|
||||
struct _Evas
|
||||
|
@ -257,9 +239,6 @@ struct _Evas
|
|||
int mouse_grabbed;
|
||||
DATA32 button;
|
||||
Evas_Coord x, y;
|
||||
|
||||
//// Evas_Coord canvas_x, canvas_y;
|
||||
|
||||
struct {
|
||||
Eina_List *in;
|
||||
} object;
|
||||
|
@ -329,6 +308,7 @@ struct _Evas
|
|||
unsigned int last_timestamp;
|
||||
int last_mouse_down_counter;
|
||||
int last_mouse_up_counter;
|
||||
int nochange;
|
||||
Evas_Font_Hinting_Flags hinting;
|
||||
unsigned char changed : 1;
|
||||
unsigned char delete_me : 1;
|
||||
|
@ -403,66 +383,60 @@ struct _Evas_Object
|
|||
{
|
||||
EINA_INLIST;
|
||||
|
||||
DATA32 magic;
|
||||
DATA32 magic;
|
||||
|
||||
const char *type;
|
||||
Evas_Layer *layer;
|
||||
const char *type;
|
||||
Evas_Layer *layer;
|
||||
|
||||
struct {
|
||||
Evas_Map *map;
|
||||
Evas_Object *clipper;
|
||||
Evas_Object *map_parent;
|
||||
double scale;
|
||||
Evas_Coord_Rectangle geometry;
|
||||
struct {
|
||||
/*
|
||||
struct {
|
||||
int x, y, w, h;
|
||||
int validity;
|
||||
} geometry;
|
||||
*/
|
||||
struct {
|
||||
int x, y, w, h;
|
||||
unsigned char r, g, b, a;
|
||||
Eina_Bool visible : 1;
|
||||
Eina_Bool dirty : 1;
|
||||
Evas_Coord x, y, w, h;
|
||||
unsigned char r, g, b, a;
|
||||
Eina_Bool visible : 1;
|
||||
Eina_Bool dirty : 1;
|
||||
} clip;
|
||||
} cache;
|
||||
double scale;
|
||||
Evas_Map *map;
|
||||
Evas_Coord_Rectangle geometry;
|
||||
short layer;
|
||||
struct {
|
||||
unsigned char r, g, b, a;
|
||||
unsigned char r, g, b, a;
|
||||
} color;
|
||||
Evas_Object *clipper;
|
||||
Evas_Object *map_parent;
|
||||
short layer;
|
||||
Eina_Bool usemap : 1;
|
||||
Eina_Bool visible : 1;
|
||||
Eina_Bool have_clipees : 1;
|
||||
Eina_Bool anti_alias : 1;
|
||||
Evas_Render_Op render_op : 4;
|
||||
Eina_Bool usemap : 1;
|
||||
Eina_Bool visible : 1;
|
||||
Eina_Bool have_clipees : 1;
|
||||
Eina_Bool anti_alias : 1;
|
||||
Evas_Render_Op render_op : 4;
|
||||
} cur, prev;
|
||||
|
||||
char *name;
|
||||
|
||||
Evas_Intercept_Func *interceptors;
|
||||
Evas_Intercept_Func *interceptors;
|
||||
|
||||
struct {
|
||||
Eina_List *elements;
|
||||
Eina_List *elements;
|
||||
} data;
|
||||
|
||||
Eina_List *grabs;
|
||||
Eina_List *grabs;
|
||||
|
||||
Evas_Callbacks *callbacks;
|
||||
Evas_Callbacks *callbacks;
|
||||
|
||||
struct {
|
||||
Eina_List *clipees;
|
||||
Eina_List *changes;
|
||||
Eina_List *clipees;
|
||||
Eina_List *changes;
|
||||
} clip;
|
||||
|
||||
const Evas_Object_Func *func;
|
||||
const Evas_Object_Func *func;
|
||||
|
||||
void *object_data;
|
||||
void *object_data;
|
||||
|
||||
struct {
|
||||
Evas_Smart *smart;
|
||||
Evas_Object *parent;
|
||||
Evas_Smart *smart;
|
||||
Evas_Object *parent;
|
||||
} smart;
|
||||
|
||||
Evas_Size_Hints *size_hints;
|
||||
|
@ -473,6 +447,8 @@ struct _Evas_Object
|
|||
|
||||
int last_event;
|
||||
|
||||
unsigned char delete_me;
|
||||
|
||||
Evas_Object_Pointer_Mode pointer_mode : 1;
|
||||
|
||||
Eina_Bool store : 1;
|
||||
|
@ -482,6 +458,7 @@ struct _Evas_Object
|
|||
Eina_Bool repeat_events : 1;
|
||||
Eina_Bool restack : 1;
|
||||
Eina_Bool changed : 1;
|
||||
Eina_Bool changed_move : 1;
|
||||
Eina_Bool is_active : 1;
|
||||
|
||||
Eina_Bool render_pre : 1;
|
||||
|
@ -495,8 +472,7 @@ struct _Evas_Object
|
|||
|
||||
Eina_Bool precise_is_inside : 1;
|
||||
Eina_Bool havemap_parent : 1;
|
||||
|
||||
unsigned char delete_me;
|
||||
Eina_Bool is_static_clip : 1;
|
||||
};
|
||||
|
||||
struct _Evas_Func_Node
|
||||
|
|
Loading…
Reference in New Issue