X-Git-Url: http://ncurses.scripts.mit.edu/?p=ncurses.git;a=blobdiff_plain;f=test%2Fchgat.c;h=919b5c9e3b98a2fcf6b0b9eff7b6bcdf1d95d6ab;hp=aee178e16947fbfc4888f10c04c559ed8c53f211;hb=1c551ea75ea57f9186fbe8d79674ac85baa4d358;hpb=3a0d9d27e0cf115ff9dcc6163c251bccaa62bd7d diff --git a/test/chgat.c b/test/chgat.c index aee178e1..919b5c9e 100644 --- a/test/chgat.c +++ b/test/chgat.c @@ -1,5 +1,5 @@ /**************************************************************************** - * Copyright (c) 2006-2008,2009 Free Software Foundation, Inc. * + * Copyright (c) 2006-2010,2012 Free Software Foundation, Inc. * * * * Permission is hereby granted, free of charge, to any person obtaining a * * copy of this software and associated documentation files (the * @@ -26,7 +26,7 @@ * authorization. * ****************************************************************************/ /* - * $Id: chgat.c,v 1.10 2009/10/24 21:32:57 tom Exp $ + * $Id: chgat.c,v 1.12 2012/11/18 01:55:35 tom Exp $ * * test-driver for chgat/wchgat/mvchgat/mvwchgat */ @@ -176,6 +176,8 @@ do_subwindow(WINDOW *win, STATUS * sp, void func(WINDOW *)) delwin(win1); touchwin(win); } else { + if (win1 != 0) + delwin(win1); beep(); } } @@ -221,7 +223,7 @@ show_help(WINDOW *win) getmaxyx(win, y_max, x_max); for (row = 0; row < (int) SIZEOF(table) && row < y_max; ++row) { - mvwprintw(win, row, 0, "%.*s", x_max, table[row]); + MvWPrintw(win, row, 0, "%.*s", x_max, table[row]); } while (wgetch(win) != 'q') beep();