Use -1, -1 where is possible
This commit is contained in:
parent
afba98eb13
commit
ba821de391
@ -6,7 +6,7 @@
|
||||
* this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
|
||||
* ----------------------------------------------------------------------------
|
||||
*
|
||||
* $Id: main.c,v 1.14 1994/11/11 23:22:56 jkh Exp $
|
||||
* $Id: main.c,v 1.15 1994/11/12 05:40:26 phk Exp $
|
||||
*
|
||||
*/
|
||||
|
||||
@ -45,7 +45,7 @@ handle_intr(int sig)
|
||||
dialog_update();
|
||||
dialog_msgbox("User Interrupt",
|
||||
"User interrupted. Aborting the installation",
|
||||
10, 72, 1);
|
||||
-1, -1, 1);
|
||||
ExitSysinstall();
|
||||
}
|
||||
|
||||
|
@ -257,7 +257,7 @@ edit_mbr(struct mbr *mbr, struct disklabel *label)
|
||||
{
|
||||
|
||||
dialog_msgbox("DOS partition table editor",
|
||||
"This editor is still under construction :-)", 10, 75, 1);
|
||||
"This editor is still under construction :-)", -1, -1, 1);
|
||||
show_mbr(mbr);
|
||||
}
|
||||
|
||||
|
@ -46,7 +46,7 @@ stage0()
|
||||
{
|
||||
evil_goto:
|
||||
if (dialog_menu("Welcome to FreeBSD!",
|
||||
"Use ALT-F2 and ALT-F1 to toggle between debugging\ninformation screen (ALT-F2) or this dialog screen (ALT-F1)\n\nPlease select one of the following options:", 18, 75, 7, 7, welcome, selection))
|
||||
"Use ALT-F2 and ALT-F1 to toggle between debugging\ninformation screen (ALT-F2) or this dialog screen (ALT-F1)\n\nPlease select one of the following options:", -1, -1, 7, 7, welcome, selection))
|
||||
ExitSysinstall();
|
||||
|
||||
switch (atoi(selection)) {
|
||||
@ -75,7 +75,7 @@ evil_goto:
|
||||
|
||||
case 6:
|
||||
dialog_msgbox("Sorry!", "This feature is not currently implemented.",
|
||||
6, 75, 1);
|
||||
-1, -1, 1);
|
||||
goto evil_goto;
|
||||
break;
|
||||
|
||||
|
@ -198,7 +198,7 @@ select_disk()
|
||||
avail_disknames[i]);
|
||||
}
|
||||
|
||||
if (dialog_menu("FreeBSD Installation", scratch, 10, 75, 5, no_disks,
|
||||
if (dialog_menu("FreeBSD Installation", scratch, -1, -1, 5, no_disks,
|
||||
options, selection)) {
|
||||
dialog_clear();
|
||||
sprintf(scratch,"\n\n\nYou did not select a valid disk.\n\n");
|
||||
@ -232,7 +232,7 @@ select_partition(int disk)
|
||||
mbr->dospart[i].dp_size * 512 / (1024 * 1024));
|
||||
}
|
||||
if (dialog_menu(TITLE,
|
||||
scratch, 10, 75, 5, 5, options, selection)) {
|
||||
scratch, -1, -1, 5, 5, options, selection)) {
|
||||
sprintf(scratch,"You did not select a valid partition");
|
||||
dialog_clear();
|
||||
AskAbort(scratch);
|
||||
@ -243,7 +243,7 @@ select_partition(int disk)
|
||||
if (choice == -1) {
|
||||
whole_disk = 1;
|
||||
choice = 0;
|
||||
if (dialog_yesno(TITLE, "\n\nInstalling to the whole disk will erase all its current data.\n\nAre you sure you want to do this?", 10, 75)) {
|
||||
if (dialog_yesno(TITLE, "\n\nInstalling to the whole disk will erase all its current data.\n\nAre you sure you want to do this?", -1, -1)) {
|
||||
valid = 0;
|
||||
whole_disk = 0;
|
||||
}
|
||||
@ -387,7 +387,7 @@ leave:
|
||||
AskAbort(scratch);
|
||||
if (!dialog_yesno(TITLE,
|
||||
"Are you sure you wish to proceed?",
|
||||
10, 75)) {
|
||||
-1, -1)) {
|
||||
dialog_clear();
|
||||
if (clear_mbr(mbr, boot1) == -1) {
|
||||
sprintf(scratch, "\n\nCouldn't create new master boot record.\n\n%s", errmsg);
|
||||
@ -400,7 +400,7 @@ leave:
|
||||
}
|
||||
if (custom_install)
|
||||
if (!dialog_yesno(TITLE, "Do you wish to edit the DOS partition table?",
|
||||
10, 75)) {
|
||||
-1, -1)) {
|
||||
dialog_clear();
|
||||
edit_mbr(mbr, &avail_disklabels[inst_disk]);
|
||||
}
|
||||
@ -415,7 +415,7 @@ leave:
|
||||
ok = 1;
|
||||
} else {
|
||||
sprintf(scratch, "The DOS partition table is inconsistent.\n\n%s\nDo you wish to edit it by hand?", errmsg);
|
||||
if (!dialog_yesno(TITLE, scratch, 10, 75)) {
|
||||
if (!dialog_yesno(TITLE, scratch, -1, -1)) {
|
||||
dialog_clear();
|
||||
edit_mbr(mbr, &avail_disklabels[inst_disk]);
|
||||
} else {
|
||||
@ -432,7 +432,7 @@ leave:
|
||||
default_disklabel(&avail_disklabels[inst_disk],
|
||||
mbr->dospart[inst_part].dp_size,
|
||||
mbr->dospart[inst_part].dp_start);
|
||||
dialog_msgbox(TITLE, "This is an experimental disklabel configuration\nmenu. It doesn't perform any validation of the entries\nas yet so BE SURE YOU TYPE THINGS CORRECTLY.\n\n Hit escape to quit the editor.\n\nThere may be some delay exiting because of a dialog bug", 20,70,1);
|
||||
dialog_msgbox(TITLE, "This is an experimental disklabel configuration\nmenu. It doesn't perform any validation of the entries\nas yet so BE SURE YOU TYPE THINGS CORRECTLY.\n\n Hit escape to quit the editor.\n\nThere may be some delay exiting because of a dialog bug", -1,-1,1);
|
||||
dialog_clear();
|
||||
edit_disklabel(&avail_disklabels[inst_disk]);
|
||||
|
||||
@ -443,7 +443,7 @@ leave:
|
||||
|
||||
/* ready could have been reset above */
|
||||
if (ready) {
|
||||
if (dialog_yesno(TITLE, "We are now ready to format the hard disk for FreeBSD.\n\nSome or all of the disk will be overwritten during this process.\n\nAre you sure you wish to proceed ?", 10, 75)) {
|
||||
if (dialog_yesno(TITLE, "We are now ready to format the hard disk for FreeBSD.\n\nSome or all of the disk will be overwritten during this process.\n\nAre you sure you wish to proceed ?", -1, -1)) {
|
||||
dialog_clear();
|
||||
AskAbort("Do you want to quit?");
|
||||
ready = 0;
|
||||
|
@ -6,7 +6,7 @@
|
||||
* this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
|
||||
* ----------------------------------------------------------------------------
|
||||
*
|
||||
* $Id: stage2.c,v 1.13 1994/11/06 01:16:29 jkh Exp $
|
||||
* $Id: stage2.c,v 1.14 1994/11/11 07:58:08 jkh Exp $
|
||||
*
|
||||
*/
|
||||
|
||||
@ -36,7 +36,7 @@ stage2()
|
||||
FILE *f1;
|
||||
int i, j;
|
||||
|
||||
if (dialog_yesno("Last Chance!", "Are you sure you want to proceed with the installation?\nLast chance before wiping your hard disk!", 8, 72))
|
||||
if (dialog_yesno("Last Chance!", "Are you sure you want to proceed with the installation?\nLast chance before wiping your hard disk!", -1, -1))
|
||||
exit(0);
|
||||
/* Sort in mountpoint order */
|
||||
memset(Fsize, 0, sizeof Fsize);
|
||||
@ -133,6 +133,6 @@ stage2()
|
||||
/* Don't do error-check, we reboot anyway... */
|
||||
unmount(dbuf, 0);
|
||||
}
|
||||
dialog_msgbox(TITLE,"Remove the floppy from the drive and hit return to reboot from the hard disk",6, 75, 1);
|
||||
dialog_msgbox(TITLE,"Remove the floppy from the drive and hit return to reboot from the hard disk", -1, -1, 1);
|
||||
dialog_clear();
|
||||
}
|
||||
|
@ -6,7 +6,7 @@
|
||||
* this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
|
||||
* ----------------------------------------------------------------------------
|
||||
*
|
||||
* $Id: stage4.c,v 1.6 1994/11/17 14:12:37 jkh Exp $
|
||||
* $Id: stage4.c,v 1.7 1994/11/17 14:18:43 jkh Exp $
|
||||
*
|
||||
*/
|
||||
|
||||
@ -38,7 +38,7 @@ stage4()
|
||||
|
||||
while (1) {
|
||||
dialog_msgbox(TITLE,
|
||||
"Insert CPIO floppy in floppy drive 0", 6, 75, 1);
|
||||
"Insert CPIO floppy in floppy drive 0", -1, -1, 1);
|
||||
ffd = open("/dev/fd0a",O_RDONLY);
|
||||
if (ffd > 0)
|
||||
break;
|
||||
|
@ -6,7 +6,7 @@
|
||||
* this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
|
||||
* ----------------------------------------------------------------------------
|
||||
*
|
||||
* $Id: stage5.c,v 1.14 1994/11/08 14:04:19 jkh Exp $
|
||||
* $Id: stage5.c,v 1.15 1994/11/11 07:58:09 jkh Exp $
|
||||
*
|
||||
*/
|
||||
|
||||
@ -36,7 +36,7 @@ stage5()
|
||||
{
|
||||
int exec_sh = 1;
|
||||
|
||||
if (!dialog_yesno("End of initial installation", msg, 11, 76))
|
||||
if (!dialog_yesno("End of initial installation", msg, -1, -1))
|
||||
exec_sh = 0;
|
||||
end_dialog();
|
||||
dialog_active=0;
|
||||
|
@ -6,7 +6,7 @@
|
||||
* this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
|
||||
* ----------------------------------------------------------------------------
|
||||
*
|
||||
* $Id: utils.c,v 1.27 1994/11/16 14:42:22 ache Exp $
|
||||
* $Id: utils.c,v 1.28 1994/11/17 14:12:38 jkh Exp $
|
||||
*
|
||||
*/
|
||||
|
||||
@ -101,7 +101,7 @@ AskAbort(char *fmt, ...)
|
||||
vsnprintf(p, 2048, fmt, ap);
|
||||
va_end(ap);
|
||||
strcat(p, "\n\nDo you wish to abort the installation?");
|
||||
if (!dialog_yesno("Abort", p, 15, 60)) {
|
||||
if (!dialog_yesno("Abort", p, -1, -1)) {
|
||||
dialog_clear();
|
||||
Abort();
|
||||
}
|
||||
@ -113,7 +113,7 @@ void
|
||||
Abort()
|
||||
{
|
||||
if (dialog_yesno("Exit sysinstall","\n\nAre you sure you want to quit?",
|
||||
10, 40)) {
|
||||
-1, -1)) {
|
||||
dialog_clear();
|
||||
return;
|
||||
}
|
||||
@ -132,7 +132,7 @@ ExitSysinstall()
|
||||
if (dialog_active) {
|
||||
clear();
|
||||
dialog_msgbox(TITLE, "\n\nCan't reboot machine -- hit reset button",
|
||||
5,30,0);
|
||||
-1,-1,0);
|
||||
} else
|
||||
fprintf(stderr, "Can't reboot the machine -- hit the reset button");
|
||||
while(1);
|
||||
|
Loading…
x
Reference in New Issue
Block a user