Traverse the stack's cards and paint their backgrounds.

This commit is contained in:
Murilo Pereira 2011-05-15 15:02:34 -03:00
parent 6a08aad3d3
commit ce99997280

View File

@ -56,17 +56,11 @@ static char *card_value(enum value value) {
} }
void erase_stack(struct stack *stack) { void erase_stack(struct stack *stack) {
WINDOW *empty_stack = NULL; for (; stack; stack = stack->next) {
werase(stack->card->frame->window);
wbkgd(stack->card->frame->window, WHITE_ON_GREEN); wbkgd(stack->card->frame->window, WHITE_ON_GREEN);
wrefresh(stack->card->frame->window); wrefresh(stack->card->frame->window);
empty_stack = newwin(FRAME_HEIGHT, }
FRAME_WIDTH,
stack->card->frame->begin_y,
stack->card->frame->begin_x);
box(empty_stack, 0, 0);
wrefresh(empty_stack);
delwin(empty_stack);
} }
void draw_value(struct card *card) { void draw_value(struct card *card) {