On Mon, Nov 10, 2003 at 07:15:46AM +0100, Christian Perrier wrote: > Quoting Joey Hess ([EMAIL PROTECTED]): > > Leaving aside the cdebconf progress bar resize bug, if I were doing any > > number of installs over slow serial (more than 1..), I would switch d-i > > The redraw problem is, btw, also a problem for VmWare installs. Screen > drawing is really slow on some VmWare setups (mine for instance....) > and the flashing boxes mentioned in this thread are indeed a bit > annoying.
Could someone please test the attached patch? I cannot test it myself at the moment, but I believe that it eliminates those flashing boxes. Denis
Index: debian/changelog =================================================================== RCS file: /cvs/debian-boot/debian-installer/tools/cdebconf/debian/changelog,v retrieving revision 1.251 diff -u -r1.251 changelog --- debian/changelog 10 Nov 2003 18:40:08 -0000 1.251 +++ debian/changelog 11 Nov 2003 00:11:18 -0000 @@ -5,6 +5,9 @@ * Denis Barbier - Fix navigation with arrow keys in the newt frontend. Closes: #218844. - Provide a better example in src/test/backup.config + - Do not call newtInit/newtFinished when displaying progress bars, + these functions should only be called when starting and stopping + the interface, and caused flashing effects. * Chris Tillman - s/debconf/cdebconf/ in man pages. Index: src/modules/frontend/newt/newt.c =================================================================== RCS file: /cvs/debian-boot/debian-installer/tools/cdebconf/src/modules/frontend/newt/newt.c,v retrieving revision 1.40 diff -u -r1.40 newt.c --- src/modules/frontend/newt/newt.c 8 Nov 2003 22:39:41 -0000 1.40 +++ src/modules/frontend/newt/newt.c 11 Nov 2003 00:11:19 -0000 @@ -901,17 +901,18 @@ obj->interactive = 1; obj->data = calloc(1, sizeof(struct newt_data)); newtInit(); + newtCls(); newtGetScreenSize(&width, &height); // Fill the screen so people can shift-pgup properly for (i = 0; i < height; i++) putchar('\n'); - newtFinished(); return DC_OK; } static int newt_shutdown(struct frontend *obj) { + newtFinished(); return DC_OK; } @@ -926,26 +927,19 @@ static int newt_go(struct frontend *obj) { - struct newt_data *data = (struct newt_data *)obj->data; struct question *q = obj->questions; - int i, ret = DC_OK, cleared; + int i, ret = DC_OK; - cleared = 0; while (q != NULL) { for (i = 0; i < DIM(question_handlers); i++) { if (strcmp(q->template->type, question_handlers[i].type) == 0) { - if (!cleared && !data->scale_form) { - cleared = 1; - newtInit(); - newtCls(); - } ret = question_handlers[i].handler(obj, q); if (ret == DC_OK) obj->qdb->methods.set(obj->qdb, q); else if (ret == DC_GOBACK && q->prev != NULL) q = q->prev; else { - newtFinished(); + newtCls(); return ret; } break; @@ -954,8 +948,7 @@ if (ret == DC_OK) q = q->next; } - if (cleared && !data->scale_form) - newtFinished(); + newtCls(); return DC_OK; } @@ -981,8 +974,6 @@ obj->progress_min = min; obj->progress_max = max; obj->progress_cur = min; - newtInit(); - newtCls(); newtGetScreenSize(&width, NULL); win_width = width-7; newtCenteredWindow(win_width, 5, title); @@ -1070,7 +1061,6 @@ if (data->scale_form != NULL) { newtFormDestroy(data->scale_form); newtPopWindow(); - newtFinished(); data->scale_form = data->scale_bar = data->perc_label = data->scale_textbox = NULL; } }