[Mplayer-cvslog] CVS: main/Gui/wm ws.h,1.24,1.25 wsxdnd.h,1.1,1.2
Moritz Bunkus CVS
mosu at mplayerhq.hu
Wed Jan 15 12:17:00 CET 2003
Update of /cvsroot/mplayer/main/Gui/wm
In directory mail:/var/tmp.root/cvs-serv14644/Gui/wm
Modified Files:
ws.h wsxdnd.h
Log Message:
bunkus: Encapsulated arguments to #define in ( ... ) so that the #defines can be safely used like functions: mydef(flag ? val1 : val2)
Index: ws.h
===================================================================
RCS file: /cvsroot/mplayer/main/Gui/wm/ws.h,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -r1.24 -r1.25
--- ws.h 9 Jan 2003 20:47:12 -0000 1.24
+++ ws.h 15 Jan 2003 11:16:27 -0000 1.25
@@ -254,7 +254,7 @@
extern void wsScreenSaverOn( Display *mDisplay );
extern void wsScreenSaverOff( Display * mDisplay );
-#define wgIsRect( X,Y,tX,tY,bX,bY ) ( ( X > tX )&&( Y > tY )&&( X < bX )&&( Y < bY ) )
+#define wgIsRect( X,Y,tX,tY,bX,bY ) ( ( (X) > (tX) )&&( (Y) > (tY) )&&( (X) < (bX) )&&( (Y) < (bY) ) )
#endif
Index: wsxdnd.h
===================================================================
RCS file: /cvsroot/mplayer/main/Gui/wm/wsxdnd.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- wsxdnd.h 11 Aug 2002 13:12:38 -0000 1.1
+++ wsxdnd.h 15 Jan 2003 11:16:27 -0000 1.2
@@ -17,7 +17,7 @@
#define XDND_ENTER_THREE_TYPES_SET(e,b) (e)->xclient.data.l[1] = ((e)->xclient.data.l[1] & ~0x1UL) | (((b) == 0) ? 0 : 0x1UL)
#define XDND_ENTER_VERSION(e) ((e)->xclient.data.l[1] >> 24)
#define XDND_ENTER_VERSION_SET(e,v) (e)->xclient.data.l[1] = ((e)->xclient.data.l[1] & ~(0xFF << 24)) | ((v) << 24)
-#define XDND_ENTER_TYPE(e,i) ((e)->xclient.data.l[2 + i]) /* i => (0, 1, 2) */
+#define XDND_ENTER_TYPE(e,i) ((e)->xclient.data.l[2 + (i)]) /* i => (0, 1, 2) */
/* XdndPosition */
#define XDND_POSITION_SOURCE_WIN(e) ((e)->xclient.data.l[0])
More information about the MPlayer-cvslog
mailing list