aboutsummaryrefslogtreecommitdiffstats
path: root/legacy/evas/src/lib/canvas/evas_clip.c
diff options
context:
space:
mode:
authorIván Briano <sachieru@gmail.com>2010-02-01 19:50:01 +0000
committerIván Briano <sachieru@gmail.com>2010-02-01 19:50:01 +0000
commit27eccf03327608635863f017f840835ebabedf22 (patch)
treef72b15de26c6fb11928af652bf37c4ec9434ab2d /legacy/evas/src/lib/canvas/evas_clip.c
parentFix init checks so that there is no more seg fault. (diff)
downloadefl-27eccf03327608635863f017f840835ebabedf22.tar.gz
When a clipper is no more, redraw the portion of the canvas it takes.
SVN revision: 45781
Diffstat (limited to 'legacy/evas/src/lib/canvas/evas_clip.c')
-rw-r--r--legacy/evas/src/lib/canvas/evas_clip.c21
1 files changed, 19 insertions, 2 deletions
diff --git a/legacy/evas/src/lib/canvas/evas_clip.c b/legacy/evas/src/lib/canvas/evas_clip.c
index feea51bc8c..fa2951a5b3 100644
--- a/legacy/evas/src/lib/canvas/evas_clip.c
+++ b/legacy/evas/src/lib/canvas/evas_clip.c
@@ -118,7 +118,16 @@ evas_object_clip_set(Evas_Object *obj, Evas_Object *clip)
{
/* unclip */
obj->cur.clipper->clip.clipees = eina_list_remove(obj->cur.clipper->clip.clipees, obj);
- if (!obj->cur.clipper->clip.clipees) obj->cur.clipper->cur.have_clipees = 0;
+ if (!obj->cur.clipper->clip.clipees)
+ {
+ obj->cur.clipper->cur.have_clipees = 0;
+ if (obj->cur.clipper->cur.visible)
+ evas_damage_rectangle_add(obj->cur.clipper->layer->evas,
+ obj->cur.clipper->cur.geometry.x,
+ obj->cur.clipper->cur.geometry.y,
+ obj->cur.clipper->cur.geometry.w,
+ obj->cur.clipper->cur.geometry.h);
+ }
evas_object_change(obj->cur.clipper);
evas_object_change(obj);
obj->cur.clipper = NULL;
@@ -226,7 +235,15 @@ evas_object_clip_unset(Evas_Object *obj)
{
obj->cur.clipper->clip.clipees = eina_list_remove(obj->cur.clipper->clip.clipees, obj);
if (!obj->cur.clipper->clip.clipees)
- obj->cur.clipper->cur.have_clipees = 0;
+ {
+ obj->cur.clipper->cur.have_clipees = 0;
+ if (obj->cur.clipper->cur.visible)
+ evas_damage_rectangle_add(obj->cur.clipper->layer->evas,
+ obj->cur.clipper->cur.geometry.x,
+ obj->cur.clipper->cur.geometry.y,
+ obj->cur.clipper->cur.geometry.w,
+ obj->cur.clipper->cur.geometry.h);
+ }
evas_object_change(obj->cur.clipper);
}
obj->cur.clipper = NULL;