Enlightenment CVS committal

Author  : kwo
Project : e16
Module  : e

Dir     : e16/e/src


Modified Files:
        piximg.c x.c xwin.h 


Log Message:
Eliminate EXCreate/FreePixmap.

===================================================================
RCS file: /cvs/e/e16/e/src/piximg.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -3 -r1.1 -r1.2
--- piximg.c    23 Jun 2007 20:35:51 -0000      1.1
+++ piximg.c    10 Sep 2007 20:13:59 -0000      1.2
@@ -149,7 +149,7 @@
        gcv.subwindow_mode = IncludeInferiors;
        gc = EXCreateGC(root, GCSubwindowMode, &gcv);
 
-       mask = EXCreatePixmap(root, w, h, 1);
+       mask = XCreatePixmap(disp, root, w, h, 1);
        gcm = EXCreateGC(mask, 0, NULL);
        XSetForeground(disp, gcm, 1);
        XFillRectangle(disp, mask, gcm, 0, 0, w, h);
@@ -160,7 +160,7 @@
                          rl[i].height);
        XSetClipMask(disp, gc, mask);
        EXFreeGC(gcm);
-       EXFreePixmap(mask);
+       XFreePixmap(disp, mask);
      }
 
    XSetClipOrigin(disp, gc, x, y);
===================================================================
RCS file: /cvs/e/e16/e/src/x.c,v
retrieving revision 1.163
retrieving revision 1.164
diff -u -3 -r1.163 -r1.164
--- x.c 5 Sep 2007 19:12:56 -0000       1.163
+++ x.c 10 Sep 2007 20:13:59 -0000      1.164
@@ -37,7 +37,8 @@
 #include "eglx.h"
 #endif
 
-#define DEBUG_XWIN 0
+#define DEBUG_XWIN   0
+#define DEBUG_PIXMAP 0
 
 #if USE_COMPOSITE
 static Visual      *argb_visual = NULL;
@@ -1513,14 +1514,24 @@
 ECreatePixmap(Win win, unsigned int width, unsigned int height,
              unsigned int depth)
 {
+   Pixmap              pmap;
+
    if (depth == 0)
       depth = win->depth;
-   return XCreatePixmap(disp, win->xwin, width, height, depth);
+
+   pmap = XCreatePixmap(disp, win->xwin, width, height, depth);
+#if DEBUG_PIXMAP
+   Eprintf("%s: %#lx\n", __func__, pmap);
+#endif
+   return pmap;
 }
 
 void
 EFreePixmap(Pixmap pmap)
 {
+#if DEBUG_PIXMAP
+   Eprintf("%s: %#lx\n", __func__, pmap);
+#endif
    XFreePixmap(disp, pmap);
 }
 
@@ -1531,11 +1542,13 @@
    Pixmap              pmap;
    GC                  gc;
 
-   pmap = EXCreatePixmap(src, w, h, depth);
+   pmap = XCreatePixmap(disp, src, w, h, depth);
    gc = EXCreateGC(src, 0, NULL);
    XCopyArea(disp, src, pmap, gc, 0, 0, w, h, 0, 0);
    EXFreeGC(gc);
-
+#if DEBUG_PIXMAP
+   Eprintf("%s: %#lx\n", __func__, pmap);
+#endif
    return pmap;
 }
 
===================================================================
RCS file: /cvs/e/e16/e/src/xwin.h,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -3 -r1.33 -r1.34
--- xwin.h      28 Aug 2007 17:58:23 -0000      1.33
+++ xwin.h      10 Sep 2007 20:13:59 -0000      1.34
@@ -235,10 +235,6 @@
 
 void                EXWarpPointer(Window xwin, int x, int y);
 
-#define EXCreatePixmap(win, w, h, d) \
-       XCreatePixmap(disp, win, w, h, d)
-#define EXFreePixmap(pmap) \
-       XFreePixmap(disp, pmap)
 Pixmap              EXCreatePixmapCopy(Pixmap src, unsigned int w,
                                       unsigned int h, unsigned int depth);
 



-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to