Enlightenment CVS committal

Author  : raster
Project : e17
Module  : libs/ecore

Dir     : e17/libs/ecore/src/lib/ecore_x


Modified Files:
        Ecore_X.h ecore_x.c ecore_x_window.c 


Log Message:


tilman's xcursor patch

===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ecore/src/lib/ecore_x/Ecore_X.h,v
retrieving revision 1.51
retrieving revision 1.52
diff -u -3 -r1.51 -r1.52
--- Ecore_X.h   23 Aug 2004 10:44:22 -0000      1.51
+++ Ecore_X.h   25 Aug 2004 23:41:57 -0000      1.52
@@ -738,6 +738,8 @@
 Ecore_X_Window   ecore_x_window_new(Ecore_X_Window parent, int x, int y, int w, int 
h);
 Ecore_X_Window   ecore_x_window_override_new(Ecore_X_Window parent, int x, int y, int 
w, int h);
 Ecore_X_Window   ecore_x_window_input_new(Ecore_X_Window parent, int x, int y, int w, 
int h);
+void             ecore_x_window_cursor_set(Ecore_X_Window win,
+                                           Ecore_X_Cursor c);
 void             ecore_x_window_del(Ecore_X_Window win);
 void             ecore_x_window_delete_request_send(Ecore_X_Window win);
 void             ecore_x_window_show(Ecore_X_Window win);
@@ -877,10 +879,8 @@
      ecore_x_cursor_new(Ecore_X_Window win, int *pixels, int w, int h, int hot_x, int 
hot_y);
    void
      ecore_x_cursor_free(Ecore_X_Cursor c);
-   void
-     ecore_x_cursor_set(Ecore_X_Window win, Ecore_X_Cursor c);
-   void
-     ecore_x_cursor_shape_set(Ecore_X_Window win, int shape);
+   Ecore_X_Cursor
+     ecore_x_cursor_shape_get(int shape);
    
    int
      ecore_x_pointer_grab(Ecore_X_Window win);
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ecore/src/lib/ecore_x/ecore_x.c,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -3 -r1.36 -r1.37
--- ecore_x.c   22 Aug 2004 21:44:52 -0000      1.36
+++ ecore_x.c   25 Aug 2004 23:41:57 -0000      1.37
@@ -1184,22 +1184,16 @@
    XFreeCursor(_ecore_x_disp, c);
 }
 
-void
-ecore_x_cursor_set(Ecore_X_Window win, Ecore_X_Cursor c)
-{
-   if (c == 0)
-     XUndefineCursor(_ecore_x_disp, win);
-   else
-     XDefineCursor(_ecore_x_disp, win, c);
-}
-
-void
-ecore_x_cursor_shape_set(Ecore_X_Window win, int shape)
+/*
+ * Returns the cursor for the given shape.
+ * Note that the return value must not be freed with
+ * ecore_x_cursor_free()!
+ */
+Ecore_X_Cursor
+ecore_x_cursor_shape_get(int shape)
 {
    /* Shapes are defined in Ecore_X_Cursor.h */
-   Cursor c = XCreateFontCursor(_ecore_x_disp, shape);
-   if (c)
-      ecore_x_cursor_set(win, c);
+   return XCreateFontCursor(_ecore_x_disp, shape);
 }
 
 int
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/ecore/src/lib/ecore_x/ecore_x_window.c,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -3 -r1.23 -r1.24
--- ecore_x_window.c    23 Aug 2004 10:47:20 -0000      1.23
+++ ecore_x_window.c    25 Aug 2004 23:41:57 -0000      1.24
@@ -536,6 +536,15 @@
      }
 }
 
+void
+ecore_x_window_cursor_set(Ecore_X_Window win, Ecore_X_Cursor c)
+{
+   if (c == 0)
+     XUndefineCursor(_ecore_x_disp, win);
+   else
+     XDefineCursor(_ecore_x_disp, win, c);
+}
+
 /**
  * Finds out whether the given window is currently visible.
  * @param   win The given window.




-------------------------------------------------------
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to