1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-26 05:02:18 +00:00
freebsd-ports/editors/bed/files/patch-src__getfile.h
Alejandro Pulver 4ca1cddb91 - Update to version 0.2.23.
- Rewrite check of 'menubar' feature in x11/rxvt when X11 option is enabled.
- Add dep to ALL_TARGET instead of running ${GMAKE} in post-configure.
- Add OPTIONS.
- Remove BROKEN for amd64 (builds).
- Remove BROKEN for ia64 (let's see what happens now).
- Add WWW line to pkg-descr.
- Added typedef hacks (has a bug that doesn't allow default arguments in
  function pointers, and also doesn't allow arrays of function pointers) to
  allow building with GCC > 2.95 (the problems are known, though).
2007-01-02 18:13:50 +00:00

30 lines
3.1 KiB
C

--- src/getfile.h.orig Thu May 23 16:28:24 2002
+++ src/getfile.h Mon Jan 1 23:48:02 2007
@@ -267,7 +267,7 @@
extern WINDOW *getshowwin(int l,int c,int by,int bx) ;
-#define initdialog(nr) {item **showformsarray;int showformsiter=0,showformsmaxar=(nr); showformsarray=new (item *)[showformsmaxar];
+#define initdialog(nr) {item **showformsarray;int showformsiter=0,showformsmaxar=(nr); showformsarray=new item *[showformsmaxar];
#define dodialog(ant,l,c,sel) if((takescr=getshowwin((l),(c),(thelines-(l))/2,(thecols-(c))/2))){ (ant)=show(showformsarray,showformsiter,(sel));};for(int dodialogiter=0;dodialogiter<showformsiter;dodialogiter++) delete showformsarray[dodialogiter];delete[] showformsarray;};
#define dodialogpost(ant,l,c,sel,post) if((takescr=getshowwin((l),(c),(thelines-(l))/2,(thecols-(c))/2))){(post);(ant)=show(showformsarray,showformsiter,(sel));};for(int dodialogiter=0;dodialogiter<showformsiter;dodialogiter++) delete showformsarray[dodialogiter];delete[] showformsarray;};
#define showdialog(ant,l,c,sel) if((takescr=getshowwin((l),c,(thelines-(l))/2,(thecols-c)/2))){ant=show(showformsarray,showformsiter,sel);};
@@ -278,7 +278,7 @@
#endif
-#define begindialog(l,c,nr) if((takescr=getshowwin((l),(c),(thelines-(l))/2,(thecols-(c))/2))){item **showformsarray;int showformsiter=0,showformsmaxar=nr; showformsarray=new (item *)[showformsmaxar];
+#define begindialog(l,c,nr) if((takescr=getshowwin((l),(c),(thelines-(l))/2,(thecols-(c))/2))){item **showformsarray;int showformsiter=0,showformsmaxar=nr; showformsarray=new item *[showformsmaxar];
#define enddialog(ant,sel) ant=show(showformsarray,showformsiter,(sel));for(int dodialogiter=0;dodialogiter<showformsiter;dodialogiter++) delete showformsarray[dodialogiter];delete[] showformsarray;};
@@ -299,7 +299,7 @@
#define lcsconfig(l,c,sel,...) plcsconfig(l,c,sel,0,__VA_ARGS__)
#define plcsconfig(l,c,sel,post,...) {int throwawayant;palcsconfig(throwawayant,l,c,sel,post,__VA_ARGS__) }
#define alcsconfig(ant,l,c,sel,...) palcsconfig(ant,l,c,sel,0,__VA_ARGS__)
-#define palcsconfig(ant,l,c,sel,post,...) {item **showformsarray;int showformsiter=0; int showformsmaxar=sizeof((item* []){__VA_ARGS__})/sizeof(item *); if((takescr=getshowwin(l,c,(thelines-l)/2,(thecols-c)/2))) { showformsarray=new (item *)[showformsmaxar],__VA_ARGS__;post;ant=show(showformsarray,showformsmaxar,sel);for(showformsiter=0;showformsiter<showformsmaxar;showformsiter++) delete showformsarray[showformsiter];delete[] showformsarray;};}
+#define palcsconfig(ant,l,c,sel,post,...) {item **showformsarray;int showformsiter=0; int showformsmaxar=sizeof((item* []){__VA_ARGS__})/sizeof(item *); if((takescr=getshowwin(l,c,(thelines-l)/2,(thecols-c)/2))) { showformsarray=new item *[showformsmaxar],__VA_ARGS__;post;ant=show(showformsarray,showformsmaxar,sel);for(showformsiter=0;showformsiter<showformsmaxar;showformsiter++) delete showformsarray[showformsiter];delete[] showformsarray;};}
#define options(name,sel,...) {int startformsiter=showformsiter; Common *comptr=new Common(name,0);__VA_ARGS__,comptr->last=(orcheck*)showformsarray[startformsiter+sel];};
#endif