# HG changeset patch # User Mikael Berthe # Date 1152365575 -7200 # Node ID 97e6a6da2b2cfeb3295a908069809f79b79955e5 # Parent a09bf67d1dfb3f68dd9bd849e968b86a82735391 Fix ncurses #include (again) diff -r a09bf67d1dfb -r 97e6a6da2b2c mcabber/src/screen.c --- a/mcabber/src/screen.c Sat Jul 08 12:47:54 2006 +0200 +++ b/mcabber/src/screen.c Sat Jul 08 15:32:55 2006 +0200 @@ -30,16 +30,6 @@ #include #include -#if HAVE_NCURSESW_NCURSES_H -# include -#elif HAVE_NCURSES_NCURSES_H -# include -#elif HAVE_NCURSES_H -# include -#else -# include -#endif - #include "screen.h" #include "utf8.h" #include "hbuf.h" @@ -490,7 +480,7 @@ return NULL; } -bool scr_BuddyBufferExists(const char *jid) +int scr_BuddyBufferExists(const char *jid) { return (scr_SearchWindow(jid, FALSE) != NULL); } @@ -1290,7 +1280,7 @@ scr_ShowWindow(jidto, FALSE); } -inline void set_autoaway(bool setaway) +static inline void set_autoaway(bool setaway) { static enum imstatus oldstatus; static char *oldmsg; @@ -1321,7 +1311,7 @@ } // Check if we should enter/leave automatic away status -void scr_CheckAutoAway(bool activity) +void scr_CheckAutoAway(int activity) { static time_t LastActivity; enum imstatus cur_st; diff -r a09bf67d1dfb -r 97e6a6da2b2c mcabber/src/screen.h --- a/mcabber/src/screen.h Sat Jul 08 12:47:54 2006 +0200 +++ b/mcabber/src/screen.h Sat Jul 08 15:32:55 2006 +0200 @@ -1,9 +1,18 @@ #ifndef __SCREEN_H__ #define __SCREEN_H__ 1 -#include #include +#if HAVE_NCURSESW_NCURSES_H +# include +#elif HAVE_NCURSES_NCURSES_H +# include +#elif HAVE_NCURSES_H +# include +#else +# include +#endif + #include "logprint.h" // Length of the timestamp & flag prefix in the chat buffer window @@ -67,7 +76,7 @@ time_t timestamp, guint prefix); void scr_WriteOutgoingMessage(const char *jidto, const char *text); void scr_ShowBuddyWindow(void); -bool scr_BuddyBufferExists(const char *jid); +int scr_BuddyBufferExists(const char *jid); inline void scr_UpdateBuddyWindow(void); inline void scr_set_chatmode(int enable); inline void scr_set_multimode(int enable, char *subject); @@ -79,7 +88,7 @@ inline void scr_Beep(void); -void scr_CheckAutoAway(bool activity); +void scr_CheckAutoAway(int activity); // For commands... void scr_RosterTop(void);