From f553a7fab5b636e66e1ce7b8efcfe8d68acba189 Mon Sep 17 00:00:00 2001 From: Gustavo Sverzut Barbieri Date: Sat, 27 Oct 2007 21:06:58 +0000 Subject: [PATCH] Minor cleanup on software_16, evas_soft16_rectangle.c SVN revision: 32175 --- .../engines/software_16/evas_soft16_rectangle.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/legacy/evas/src/modules/engines/software_16/evas_soft16_rectangle.c b/legacy/evas/src/modules/engines/software_16/evas_soft16_rectangle.c index c91f219a83..c088bd36a2 100644 --- a/legacy/evas/src/modules/engines/software_16/evas_soft16_rectangle.c +++ b/legacy/evas/src/modules/engines/software_16/evas_soft16_rectangle.c @@ -83,7 +83,7 @@ soft16_rectangle_draw(Soft16_Image *dst, RGBA_Draw_Context *dc, Evas_Rectangle dr; Cutout_Rects *rects; Cutout_Rect *r; - int c, cx, cy, cw, ch; + struct RGBA_Draw_Context_clip c_bkp; int i; /* handle cutouts here! */ @@ -103,14 +103,14 @@ soft16_rectangle_draw(Soft16_Image *dst, RGBA_Draw_Context *dc, return; } - /* save out clip info */ - c = dc->clip.use; cx = dc->clip.x; cy = dc->clip.y; cw = dc->clip.w; ch = dc->clip.h; + c_bkp = dc->clip; + evas_common_draw_context_clip_clip(dc, 0, 0, dst->w, dst->h); evas_common_draw_context_clip_clip(dc, x, y, w, h); /* our clip is 0 size.. abort */ if ((dc->clip.w <= 0) || (dc->clip.h <= 0)) { - dc->clip.use = c; dc->clip.x = cx; dc->clip.y = cy; dc->clip.w = cw; dc->clip.h = ch; + dc->clip = c_bkp; return; } rects = evas_common_draw_context_apply_cutouts(dc); @@ -121,7 +121,6 @@ soft16_rectangle_draw(Soft16_Image *dst, RGBA_Draw_Context *dc, _soft16_rectangle_draw_int(dst, dc, dr); } evas_common_draw_context_apply_clear_cutouts(rects); - /* restore clip info */ - dc->clip.use = c; dc->clip.x = cx; dc->clip.y = cy; dc->clip.w = cw; dc->clip.h = ch; + dc->clip = c_bkp; }