Remove explicit calls to curses.h in other files

This commit is contained in:
Hisham Muhammad 2013-02-26 16:50:21 +00:00
parent 8d5dd51cf2
commit 43a7231615
7 changed files with 4 additions and 7 deletions

View File

@ -12,7 +12,6 @@ in the source distribution for its full text.
#include <assert.h> #include <assert.h>
#include <stdlib.h> #include <stdlib.h>
#include <curses.h>
#include <string.h> #include <string.h>
#include <math.h> #include <math.h>

3
CRT.c
View File

@ -9,8 +9,9 @@ in the source distribution for its full text.
#include "config.h" #include "config.h"
#include "String.h" #include "String.h"
#include "RichString.h"
#include <curses.h> #include <stdio.h>
#include <errno.h> #include <errno.h>
#include <signal.h> #include <signal.h>
#include <stdlib.h> #include <stdlib.h>

View File

@ -13,7 +13,6 @@ in the source distribution for its full text.
#include <string.h> #include <string.h>
#include <stdlib.h> #include <stdlib.h>
#include <stdbool.h> #include <stdbool.h>
#include <curses.h>
/*{ /*{
#include "Object.h" #include "Object.h"

View File

@ -9,7 +9,6 @@ in the source distribution for its full text.
#include "CRT.h" #include "CRT.h"
#include <curses.h>
#include <assert.h> #include <assert.h>
/*{ /*{

View File

@ -11,7 +11,6 @@ in the source distribution for its full text.
#include "ProcessList.h" #include "ProcessList.h"
#include <stdlib.h> #include <stdlib.h>
#include <curses.h>
#include <string.h> #include <string.h>
#include <math.h> #include <math.h>
#include <sys/param.h> #include <sys/param.h>

View File

@ -18,7 +18,6 @@ in the source distribution for its full text.
#include <ctype.h> #include <ctype.h>
#include <string.h> #include <string.h>
#include <assert.h> #include <assert.h>
#include <curses.h>
//#link curses //#link curses
@ -295,6 +294,7 @@ void Panel_draw(Panel* this, bool focus) {
for(int i = first, j = 0; j < this->h && i < last; i++, j++) { for(int i = first, j = 0; j < this->h && i < last; i++, j++) {
Object* itemObj = Vector_get(this->items, i); Object* itemObj = Vector_get(this->items, i);
assert(itemObj); if(!itemObj) continue;
RichString_begin(item); RichString_begin(item);
Object_display(itemObj, &item); Object_display(itemObj, &item);
int itemLen = RichString_sizeVal(item); int itemLen = RichString_sizeVal(item);
@ -319,6 +319,7 @@ void Panel_draw(Panel* this, bool focus) {
} else { } else {
Object* oldObj = Vector_get(this->items, this->oldSelected); Object* oldObj = Vector_get(this->items, this->oldSelected);
assert(oldObj);
RichString_begin(old); RichString_begin(old);
Object_display(oldObj, &old); Object_display(oldObj, &old);
int oldLen = RichString_sizeVal(old); int oldLen = RichString_sizeVal(old);

View File

@ -11,7 +11,6 @@ in the source distribution for its full text.
#include "ProcessList.h" #include "ProcessList.h"
#include <stdlib.h> #include <stdlib.h>
#include <curses.h>
#include <string.h> #include <string.h>
#include <math.h> #include <math.h>
#include <sys/param.h> #include <sys/param.h>