Allow some post-fire actions to be combined in ways that weren't

possible before.
This commit is contained in:
Jordan K. Hubbard 1996-04-25 13:34:37 +00:00
parent 68832d3037
commit ab112e9f34
3 changed files with 9 additions and 16 deletions

View File

@ -316,6 +316,10 @@ dialog_checklist(unsigned char *title, unsigned char *prompt, int height, int wi
save = dupwin(newscr);
st = ditems[scroll + choice].fire(&ditems[scroll + choice]);
if (st & DITEM_RESTORE) {
touchwin(save);
wrefresh(save);
}
if (st & DITEM_REDRAW) {
wmove(dialog, cur_y, cur_x); /* Restore cursor to previous position */
for (i = 0; i < item_no; i++)
@ -329,10 +333,6 @@ dialog_checklist(unsigned char *title, unsigned char *prompt, int height, int wi
cur_x, cur_y);
wrefresh(dialog);
}
else if (st & DITEM_RESTORE) {
touchwin(save);
wrefresh(save);
}
else if (st & DITEM_RECREATE) {
delwin(save);
delwin(list);

View File

@ -389,7 +389,7 @@ dialog_menu(unsigned char *title, unsigned char *prompt, int height, int width,
touchwin(save);
wrefresh(save);
}
else if (status & DITEM_RECREATE) {
if (status & DITEM_RECREATE) {
delwin(menu);
delwin(dialog);
delwin(save);

View File

@ -321,6 +321,10 @@ dialog_radiolist(unsigned char *title, unsigned char *prompt, int height, int wi
save = dupwin(newscr);
st = ditems[scroll + choice].fire(&ditems[scroll + choice]);
if (st & DITEM_RESTORE) {
touchwin(save);
wrefresh(save);
}
if (st & DITEM_REDRAW) {
for (i = 0; i < item_no; i++)
status[i] = ditems[i].checked ? ditems[i].checked(&ditems[i]) : FALSE;
@ -334,11 +338,6 @@ dialog_radiolist(unsigned char *title, unsigned char *prompt, int height, int wi
wmove(dialog, cur_y, cur_x); /* Restore cursor to previous position */
wrefresh(dialog);
}
else if (st & DITEM_RESTORE) {
touchwin(save);
wrefresh(save);
wmove(dialog, cur_y, cur_x);
}
else if (st & DITEM_RECREATE) {
delwin(save);
delwin(list);
@ -465,12 +464,6 @@ dialog_radiolist(unsigned char *title, unsigned char *prompt, int height, int wi
touchwin(save);
wrefresh(save);
}
else if (st & DITEM_RECREATE) {
delwin(save);
delwin(list);
delwin(dialog);
goto draw;
}
delwin(save);
}
else {