[evas_map.c] 1 bug-- ... when maps got enabled and disabled you'd find in softwarre
that you'd get dirty areas that didnt re-rneder. fixed with nasty hack
- force a full update if anyone in the evas object tree changed maps
from on to off and vice-versa
[evas_object_main.c] !! once
[evas_render.c] fix nasty uncaught clip + map bug! fix fix fix!!!!!
[evas_font_draw.c] Do kerning correctly for word cache.
Technically this should speed it up a little. That's a nice change for a bug
fix ;-)
[Evas_Engine_DirectFB.h] Fix header include
The current way of including directfb.h makes it hard for people with multiple
versions of DirectFB installed.
This is the correct way to include that header, and it's the way
ecore_directfb does it.
Patch by: Eduardo Felipe <eduardofelipe87@>
if (!evas_map_coords_get(obj->cur.map, x, y,
&(obj->cur.map->mx),
&(obj->cur.map->my), 0))
- {
- inside = 0;
- }
+ inside = 0;
else
- {
- parmap = 1;
- }
+ parmap = 1;
}
else
inside = 0;
copy = evas_event_list_copy(e->pointer.object.in);
EINA_LIST_FOREACH(copy, l, obj)
{
+ if (obj->delete_me) continue;
+
ev.canvas.x = e->pointer.x;
ev.canvas.y = e->pointer.y;
_evas_event_havemap_adjust(obj, &ev.canvas.x, &ev.canvas.y);
obj->mouse_grabbed--;
e->pointer.mouse_grabbed--;
}
- if (e->events_frozen <= 0)
- evas_object_event_callback_call(obj, EVAS_CALLBACK_MOUSE_UP, &ev);
+ if (!obj->delete_me)
+ {
+ if (e->events_frozen <= 0)
+ evas_object_event_callback_call(obj, EVAS_CALLBACK_MOUSE_UP, &ev);
+ }
if (e->delete_me) break;
}
if (copy) copy = eina_list_free(copy);
if ((!eina_list_data_find(ins, obj)) ||
(!e->pointer.inside))
{
-
obj->mouse_in = 0;
if (e->events_frozen <= 0)
evas_object_event_callback_call(obj, EVAS_CALLBACK_MOUSE_OUT, &ev);
_evas_event_havemap_adjust(obj, &ev.canvas.x, &ev.canvas.y);
if (!eina_list_data_find(e->pointer.object.in, obj))
{
-
obj->mouse_in = 1;
if (e->events_frozen <= 0)
evas_object_event_callback_call(obj, EVAS_CALLBACK_MOUSE_IN, &ev);
_evas_event_havemap_adjust(obj, &ev.canvas.x, &ev.canvas.y);
e->pointer.object.in = eina_list_remove(e->pointer.object.in, obj);
obj->mouse_in = 0;
- if (e->events_frozen <= 0)
- evas_object_event_callback_call(obj, EVAS_CALLBACK_MOUSE_OUT, &ev);
+ if (!obj->delete_me)
+ {
+ if (e->events_frozen <= 0)
+ evas_object_event_callback_call(obj, EVAS_CALLBACK_MOUSE_OUT, &ev);
+ }
}
}
_evas_post_event_callback_call(e);
if (!eina_list_data_find(e->pointer.object.in, obj))
{
obj->mouse_in = 1;
-
if (e->events_frozen <= 0)
evas_object_event_callback_call(obj, EVAS_CALLBACK_MOUSE_IN, &ev3);
}
_evas_event_havemap_adjust(obj, &ev.canvas.x, &ev.canvas.y);
if (!eina_list_data_find(e->pointer.object.in, obj))
{
-
obj->mouse_in = 1;
if (e->events_frozen <= 0)
evas_object_event_callback_call(obj, EVAS_CALLBACK_MOUSE_IN, &ev);
ev.canvas.y = e->pointer.y;
_evas_event_havemap_adjust(obj, &ev.canvas.x, &ev.canvas.y);
obj->mouse_in = 0;
- if (e->events_frozen <= 0)
- evas_object_event_callback_call(obj, EVAS_CALLBACK_MOUSE_OUT, &ev);
-
+ if (!obj->delete_me)
+ {
+ if (e->events_frozen <= 0)
+ evas_object_event_callback_call(obj, EVAS_CALLBACK_MOUSE_OUT, &ev);
+ }
if (e->delete_me) break;
}
if (copy) copy = eina_list_free(copy);
MAGIC_CHECK(obj, Evas_Object, MAGIC_OBJ);
return;
MAGIC_CHECK_END();
+ pass = !!pass;
+ if (obj->pass_events == pass) return;
obj->pass_events = pass;
evas_object_smart_member_cache_invalidate(obj);
if (evas_object_is_in_output_rect(obj,
MAGIC_CHECK(obj, Evas_Object, MAGIC_OBJ);
return;
MAGIC_CHECK_END();
+ repeat = !!repeat;
+ if (obj->repeat_events == repeat) return;
obj->repeat_events = repeat;
if (evas_object_is_in_output_rect(obj,
obj->layer->evas->pointer.x,
MAGIC_CHECK(obj, Evas_Object, MAGIC_OBJ);
return;
MAGIC_CHECK_END();
- if (obj->cur.usemap == !!enabled) return;
- obj->cur.usemap = !!enabled;
+ enabled = !!enabled;
+ if (obj->cur.usemap == enabled) return;
+ obj->cur.usemap = enabled;
if (enabled)
{
if (!obj->cur.map)
}
obj->layer->evas->pointer.mouse_grabbed -= obj->mouse_grabbed;
obj->mouse_grabbed = 0;
+ obj->mouse_in = 0;
evas_object_hide(obj);
evas_object_grabs_cleanup(obj);
while (obj->clip.clipees) evas_object_clip_unset(obj->clip.clipees->data);
evas_object_recalc_clippees(obj);
if (!evas_event_passes_through(obj))
{
- if (!obj->smart.smart)
+ if ((!obj->smart.smart) ||
+ ((obj->cur.map) && (obj->cur.map->count == 4) && (obj->cur.usemap)))
{
if (evas_object_is_in_output_rect(obj,
obj->layer->evas->pointer.x,
return;
MAGIC_CHECK_END();
if (obj->delete_me) return;
- if (obj->cur.anti_alias == !!anti_alias)
- return;
- obj->cur.anti_alias = !!anti_alias;
+ anti_alias = !!anti_alias;
+ if (obj->cur.anti_alias == anti_alias)return;
+ obj->cur.anti_alias = anti_alias;
evas_object_change(obj);
}
return;
MAGIC_CHECK_END();
if (obj->delete_me) return;
- if (obj->cur.scale == scale)
- return;
+ if (obj->cur.scale == scale) return;
obj->cur.scale = scale;
evas_object_change(obj);
if (obj->func->scale_update) obj->func->scale_update(obj);
static Eina_Bool
_evas_render_had_map(Evas_Object *obj)
{
- return ((!obj->cur.map) && (obj->prev.usemap));
+ return ((!obj->prev.map) && (obj->prev.usemap));
}
static Eina_Bool
Eina_Array *restack_objects,
Eina_Array *delete_objects,
Eina_Array *render_objects,
- int restack, int map
+ int restack, int map,
+ int *redraw_all
#ifdef REND_DGB
, int level
#endif
Eina_Bool clean_them = EINA_FALSE;
Evas_Object *obj2;
int is_active;
-
+ Eina_Bool hmap;
+
obj->rect_del = 0;
obj->render_pre = 0;
}
#endif
- if (_evas_render_has_map(obj)) map = 1;
+ map = _evas_render_has_map(obj);
+ hmap = _evas_render_had_map(obj);
if ((restack) && (!map))
{
RD(" obj mapped\n");
if (obj->changed)
{
+ if (map != hmap)
+ *redraw_all = 1;
evas_object_clip_recalc(obj);
if ((obj->restack) &&
(is_active) && (!obj->clip.clipees) &&
RD(" had map - restack objs\n");
// eina_array_push(restack_objects, obj);
_evas_render_prev_cur_clip_cache_add(e, obj);
+ if (obj->changed)
+ {
+ if (map != hmap) *redraw_all = 1;
+ }
}
/* handle normal rendering. this object knows how to handle maps */
-
if (obj->changed)
{
if (obj->smart.smart)
delete_objects,
render_objects,
obj->restack,
- map
+ map,
+ redraw_all
#ifdef REND_DGB
, level + 1
#endif
restack_objects,
delete_objects,
render_objects,
- restack, map
+ restack, map,
+ redraw_all
#ifdef REND_DGB
, level + 1
#endif
restack_objects,
delete_objects,
render_objects,
- restack, map
+ restack, map,
+ redraw_all
#ifdef REND_DGB
, level + 1
#endif
Eina_Array *active_objects,
Eina_Array *restack_objects,
Eina_Array *delete_objects,
- Eina_Array *render_objects)
+ Eina_Array *render_objects,
+ int *redraw_all)
{
Evas_Layer *lay;
Eina_Bool clean_them = EINA_FALSE;
{
clean_them |= _evas_render_phase1_object_process
(e, obj, active_objects, restack_objects, delete_objects,
- render_objects, 0, 0
+ render_objects, 0, 0, redraw_all
#ifdef REND_DGB
, 1
#endif
}
}
RD(" ---]\n");
-
return clean_them;
}
obj->cur.geometry.y + off_y,
obj->cur.geometry.w,
obj->cur.geometry.h);
+ RECTS_CLIP_TO_RECT(x, y, w, h,
+ obj->cur.cache.clip.x + off_x,
+ obj->cur.cache.clip.y + off_y,
+ obj->cur.cache.clip.w,
+ obj->cur.cache.clip.h);
e->engine.func->context_clip_set(e->engine.data.output,
ctx, x, y, w, h);
obj->func->render(obj, e->engine.data.output, ctx,
}
}
else
- obj->func->render(obj, e->engine.data.output, ctx,
- surface, off_x, off_y);
+ {
+ e->engine.func->context_clip_set(e->engine.data.output,
+ ctx,
+ obj->cur.cache.clip.x + off_x,
+ obj->cur.cache.clip.y + off_y,
+ obj->cur.cache.clip.w,
+ obj->cur.cache.clip.h);
+ obj->func->render(obj, e->engine.data.output, ctx,
+ surface, off_x, off_y);
+ }
e->engine.func->context_free(e->engine.data.output, ctx);
}
else
int cx, cy, cw, ch;
unsigned int i, j;
int haveup = 0;
+ int redraw_all = 0;
MAGIC_CHECK(e, Evas, MAGIC_EVAS);
return NULL;
/* phase 1. add extra updates for changed objects */
if (e->invalidate || e->render_objects.count <= 0)
- clean_them = _evas_render_phase1_process(e, &e->active_objects, &e->restack_objects, &e->delete_objects, &e->render_objects);
+ clean_them = _evas_render_phase1_process(e,
+ &e->active_objects,
+ &e->restack_objects,
+ &e->delete_objects,
+ &e->render_objects,
+ &redraw_all);
_evas_render_phase1_direct(e, &e->active_objects, &e->restack_objects, &e->delete_objects, &e->render_objects);
{
ERR("viewport size != output size!");
}
+ if (redraw_all)
+ {
+ e->engine.func->output_redraws_rect_add(e->engine.data.output,
+ 0, 0,
+ e->output.w, e->output.h);
+ }
/* phase 5. add obscures */
EINA_LIST_FOREACH(e->obscures, ll, r)
{
gl = *text;
- if (gl == 0) break;
index = evas_common_font_glyph_search(fn, &fi, gl);
LKL(fi->ft_mutex);
if (fi->src->current_size != fi->size)
fi->src->current_size = fi->size;
}
fg = evas_common_font_int_cache_glyph_get(fi, index);
- if (!fg)
+ if (!fg)
{
LKU(fi->ft_mutex);
continue;
for (char_index = 0, c = 0, chr = 0 ; *text ; text++, char_index ++){
struct cinfo *ci = metrics + char_index;
ci->gl = *text;
- if (ci->gl == 0) break;
ci->index = evas_common_font_glyph_search(fn, &fi, ci->gl);
LKL(fi->ft_mutex);
if (fi->src->current_size != fi->size)
fi->src->current_size = fi->size;
}
ci->fg = evas_common_font_int_cache_glyph_get(fi, ci->index);
- LKU(fi->ft_mutex);
- if (!ci->fg) continue;
+ if (!ci->fg)
+ {
+ LKU(fi->ft_mutex);
+ continue;
+ }
- /* hmmm kerning means i can't sanely do my own cached metric tables! */
- /* grrr - this means font face sharing is kinda... not an option if */
- /* you want performance */
if ((use_kerning) && (prev_index) && (ci->index) &&
(pface == fi->src->ft.face))
{
int kern = 0;
# ifdef BIDI_SUPPORT
/* if it's rtl, the kerning matching should be reversed, i.e prev
- * index is now the index and the other way around.
+ * index is now the index and the other way around.
* There is a slight exception when there are compositing chars
* involved.*/
- if (intl_props &&
+ if (intl_props && intl_props->props &&
evas_bidi_is_rtl_char(intl_props->props->embedding_levels, char_index) &&
ci->fg->glyph->advance.x >> 16 > 0)
{
if (evas_common_font_query_kerning(fi, ci->index, prev_index, &kern))
- ci->pos.x += kern;
+ pen_x += kern;
}
else
# endif
{
if (evas_common_font_query_kerning(fi, prev_index, ci->index, &kern))
- ci->pos.x += kern;
+ pen_x += kern;
}
}
pface = fi->src->ft.face;
+
+ LKU(fi->ft_mutex);
if (gl){
ci->fg->ext_dat =dc->font_ext.func.gl_new(dc->font_ext.data,ci->fg);
ci->fg->ext_dat_free = dc->font_ext.func.gl_free;
#define _EVAS_ENGINE_DIRECTFB_H
#include <Evas.h>
-#include <directfb/directfb.h>
+#include <directfb.h>
typedef struct _Evas_Engine_Info_DirectFB Evas_Engine_Info_DirectFB;