[evolution/gtk3] Use cairo_t for GnomeCanvasItem's draw methods



commit 61f93591779a486f204ac8d7e3656d5ee790cc34
Author: Rodrigo Moya <rodrigo gnome-db org>
Date:   Fri Dec 10 13:16:33 2010 +0100

    Use cairo_t for GnomeCanvasItem's draw methods

 widgets/misc/e-canvas-background.c |    5 +----
 1 files changed, 1 insertions(+), 4 deletions(-)
---
diff --git a/widgets/misc/e-canvas-background.c b/widgets/misc/e-canvas-background.c
index 80b3bf0..cc43b5a 100644
--- a/widgets/misc/e-canvas-background.c
+++ b/widgets/misc/e-canvas-background.c
@@ -188,23 +188,20 @@ ecb_init (ECanvasBackground *ecb)
 
 static void
 ecb_draw (GnomeCanvasItem *item,
-          GdkDrawable *drawable,
+          cairo_t *cr,
           gint x,
           gint y,
           gint width,
           gint height)
 {
 	ECanvasBackground *ecb = E_CANVAS_BACKGROUND (item);
-        cairo_t *cr;
 
-        cr = gdk_cairo_create (drawable);
         cairo_set_source_rgba (cr,
                                ((ecb->priv->rgba >> 24) & 0xff) / 255.0,
                                ((ecb->priv->rgba >> 16) & 0xff) / 255.0,
                                ((ecb->priv->rgba >>  8) & 0xff) / 255.0,
                                ( ecb->priv->rgba        & 0xff) / 255.0);
         cairo_paint (cr);
-        cairo_destroy (cr);
 }
 
 static GnomeCanvasItem *



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]