Update of /cvsroot/netrek/client/cow In directory sc8-pr-cvs7.sourceforge.net:/tmp/cvs-serv27927 Modified Files: defaults.c smessage.c x11sprite.c Added Files: x11window.h defaults.h smessage.h x11sprite.h Log Message: fix compilation warnings --- NEW FILE: x11sprite.h --- void GetPixmaps(Display * d, struct window *win); Index: smessage.c =================================================================== RCS file: /cvsroot/netrek/client/cow/smessage.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- smessage.c 1 Nov 1998 17:24:11 -0000 1.1.1.1 +++ smessage.c 22 May 2006 13:11:58 -0000 1.2 @@ -2,6 +2,9 @@ /* smessage.c * * $Log$ + * Revision 1.2 2006/05/22 13:11:58 quozl + * fix compilation warnings + * * Revision 1.1.1.1 1998/11/01 17:24:11 siegl * COW 3.0 initial revision * */ @@ -16,6 +19,7 @@ #include "defs.h" #include "struct.h" #include "data.h" +#include "smessage.h" static int lcount; static int HUDoffset; --- NEW FILE: smessage.h --- void smessage(char ichar); Index: x11sprite.c =================================================================== RCS file: /cvsroot/netrek/client/cow/x11sprite.c,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- x11sprite.c 11 Jun 1999 16:14:17 -0000 1.3 +++ x11sprite.c 22 May 2006 13:11:58 -0000 1.4 @@ -1,6 +1,9 @@ /* * $Log$ + * Revision 1.4 2006/05/22 13:11:58 quozl + * fix compilation warnings + * * Revision 1.3 1999/06/11 16:14:17 siegl * cambot replay patches * @@ -28,25 +31,8 @@ #include "defs.h" #include "struct.h" #include "data.h" - -struct window - { - Window window; - int type; - char *data; - int mapped; - int width, height; - char *name; - W_Callback handle_keydown; - W_Callback handle_keyup; - W_Callback handle_button; - W_Callback handle_expose; - -#ifdef SHORT_PACKETS - int insensitive; -#endif - Cursor cursor; - }; +#include "x11window.h" +#include "x11sprite.h" #define W_Void2Window(win) ((win) ? ((struct window *) (win)) : (mylocal)) #define NoPixmapError 0 Index: defaults.c =================================================================== RCS file: /cvsroot/netrek/client/cow/defaults.c,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- defaults.c 16 May 2006 06:25:25 -0000 1.5 +++ defaults.c 22 May 2006 13:11:58 -0000 1.6 @@ -8,6 +8,9 @@ /****************************************************************************/ /* * $Log$ + * Revision 1.6 2006/05/22 13:11:58 quozl + * fix compilation warnings + * * Revision 1.5 2006/05/16 06:25:25 quozl * some compilation fixes * @@ -35,6 +38,7 @@ #include "data.h" #include <sys/file.h> #include "playerlist.h" +#include "defaults.h" #include INC_IO #include INC_STRINGS --- NEW FILE: x11window.h --- struct window { Window window; int type; char *data; int mapped; int width, height; char *name; W_Callback handle_keydown; W_Callback handle_keyup; W_Callback handle_button; W_Callback handle_expose; #ifdef SHORT_PACKETS int insensitive; #endif Cursor cursor; }; struct scrollingWindow { int lines; int updated; int topline; struct stringList *head; struct stringList *tail; struct stringList *index; }; /* x11window.c */ int _myerror(Display *d, XErrorEvent *e); void pastebuffer(void); void W_Initialize(char *str); void checkFont(XFontStruct *fontinfo, char *fontname); void GetFonts(void); XFontStruct *find_font(char *oldf, char **fonts); void GetColors(void); void W_RenameWindow(struct window *window, char *str); W_Window W_MakeWindow(char *name, int x, int y, int width, int height, W_Window parent, int border, W_Color color); void W_ChangeBorder(W_Window window, int color); void W_MapWindow(W_Window window); void W_UnmapWindow(W_Window window); int W_IsMapped(W_Window window); void W_FillArea(W_Window window, int x, int y, int width, int height, W_Color color); void W_CacheClearArea(W_Window window, int x, int y, int width, int height); void W_FlushClearAreaCache(W_Window window); void W_ClearArea(W_Window window, int x, int y, int width, int height); void W_ClearWindow(W_Window window); int W_EventsPending(void); void W_NextEvent(W_Event *wevent); int W_SpNextEvent(W_Event *wevent); void W_MakeLine(W_Window window, int x0, int y0, int x1, int y1, W_Color color); void W_CacheLine(W_Window window, int x0, int y0, int x1, int y1, int color); void W_FlushLineCaches(W_Window window); void W_MakeTractLine(W_Window window, int x0, int y0, int x1, int y1, W_Color color); void W_MakePhaserLine(W_Window window, int x0, int y0, int x1, int y1, W_Color color); void W_WriteTriangle(W_Window window, int x, int y, int s, int t, W_Color color); void W_WriteText(W_Window window, int x, int y, W_Color color, char *str, int len, W_Font font); void W_MaskText(W_Window window, int x, int y, W_Color color, char *str, int len, W_Font font); W_Icon W_StoreBitmap(int width, int height, char *data, W_Window window); void W_WriteBitmap(int x, int y, W_Icon bit, W_Color color); void W_TileWindow(W_Window window, W_Icon bit); void W_UnTileWindow(W_Window window); W_Window W_MakeTextWindow(char *name, int x, int y, int width, int height, W_Window parent, int border); struct window *newWindow(Window window, int type); struct window *findWindow(Window window); void addToHash(struct window *win); W_Window W_MakeScrollingWindow(char *name, int x, int y, int width, int height, W_Window parent, int border); void W_FlushScrollingWindow(W_Window window); void W_SetSensitive(W_Window w, int v); W_Window W_MakeMenu(char *name, int x, int y, int width, int height, W_Window parent, int border); void redrawMenu(struct window *win); void redrawMenuItem(struct window *win, int n); void changeMenuItem(struct window *win, int col, int n, char *str, int len, W_Color color); void W_DefineMapcursor(W_Window window); void W_DefineLocalcursor(W_Window window); void W_DefineFedCursor(W_Window window); void W_DefineRomCursor(W_Window window); void W_DefineKliCursor(W_Window window); void W_DefineOriCursor(W_Window window); void W_DefineTrekCursor(W_Window window); void W_DefineWarningCursor(W_Window window); void W_DefineArrowCursor(W_Window window); void W_DefineTextCursor(W_Window window); void W_DefineCursor(W_Window window, int width, int height, char *bits, char *mask, int xhot, int yhot); int W_LoadBitmap(W_Window window, char *path, Pixmap *pixmap, int *width, int *height, int *x_hot, int *y_hot); void W_Beep(void); int W_WindowWidth(W_Window window); int W_WindowHeight(W_Window window); int W_Socket(void); void W_DestroyWindow(W_Window window); void W_SetTransientForHint(W_Window w, W_Window pw); void deleteWindow(struct window *window); void W_SetIconWindow(W_Window main, W_Window icon); void checkParent(char *name, W_Window *parent); int checkMapped(char *name); int checkMappedPref(char *name, int preferred); void W_WarpPointer(W_Window window, int x, int y); void findMouse(int *x, int *y); int findMouseInWin(int *x, int *y, W_Window w); void W_Flush(void); W_Callback W_GetWindowKeyDownHandler(W_Window w); void W_SetWindowKeyDownHandler(W_Window w, W_Callback c); W_Callback W_GetWindowKeyUpHandler(W_Window w); void W_SetWindowKeyUpHandler(W_Window w, W_Callback c); W_Callback W_GetWindowButtonHandler(W_Window w); void W_SetWindowButtonHandler(W_Window w, W_Callback c); W_Callback W_GetWindowExposeHandler(W_Window w); void W_SetWindowExposeHandler(W_Window w, W_Callback c); void W_ResizeWindow(W_Window window, int neww, int newh); void W_ResizeTextWindow(W_Window window, int neww, int newh); int W_Mono(void); int W_EventsQueued(void); int W_EventsQueuedCk(void); int W_ReadEvents(void); void W_OverlayBitmap(int x, int y, W_Icon bit, W_Color color); void W_SetWindowName(W_Window w, char *name); int W_TTSTextHeight(void); int W_TTSTextWidth(char *s, int l); void init_tts(void); void W_EraseTTSText(W_Window window, int max_width, int y, int width); void W_WriteTTSText(W_Window window, int max_width, int y, int width, char *str, int len); void W_Halo(int x, int y, W_Color color); void video_mode_begin(); --- NEW FILE: defaults.h --- /* defaults.c */ int initDefaults(char *deffile); char *getdefault(char *str); int strcmpi(char *str1, char *str2); int strncmpi(char *str1, char *str2, int max); int booleanDefault(char *def, int preferred); int intDefault(char *def, int preferred); int findDefaults(char *deffile, char *file); int resetdefaults(void); int shipchange(int type); int findfile(char *fname, char *found);