Changeset 497 in MondoRescue for branches/stable/mondo/mondo/mondorestore/mondo-rstr-newt.c
- Timestamp:
- Apr 28, 2006, 12:34:03 AM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/stable/mondo/mondo/mondorestore/mondo-rstr-newt.c
r273 r497 156 156 157 157 newtPushHelpLine 158 ( " Add one of the following unallocated RAID partitions to this RAID device.");159 sprintf(tmp, "%-26s %s", "Device", "Size");158 (_(" Add one of the following unallocated RAID partitions to this RAID device.")); 159 sprintf(tmp, "%-26s %s", _("Device"), _("Size")); 160 160 headerMsg = newtLabel(1, 1, tmp); 161 161 partitionsListbox = … … 164 164 partitionsListbox); 165 165 i = 7; 166 bOK = newtCompactButton(i, 9, " OK ");167 bCancel = newtCompactButton(i += 9, 9, "Cancel");168 newtOpenWindow(22, 6, 36, 10, "Unallocated RAID partitions");166 bOK = newtCompactButton(i, 9, _(" OK ")); 167 bCancel = newtCompactButton(i += 9, 9, _("Cancel")); 168 newtOpenWindow(22, 6, 36, 10, _("Unallocated RAID partitions")); 169 169 myForm = newtForm(NULL, NULL, 0); 170 170 newtFormAddComponents(myForm, headerMsg, partitionsListbox, bOK, … … 258 258 size_str[0] = '\0'; 259 259 /* sprintf(size_str,""); */ 260 newtOpenWindow(20, 5, 48, 10, "Add entry");261 label0 = newtLabel(2, 1, "Device: ");262 label1 = newtLabel(2, 2, "Mountpoint:");263 label2 = newtLabel(2, 3, "Size (MB): ");264 label3 = newtLabel(2, 4, "Format: ");260 newtOpenWindow(20, 5, 48, 10, _("Add entry")); 261 label0 = newtLabel(2, 1, _("Device: ")); 262 label1 = newtLabel(2, 2, _("Mountpoint:")); 263 label2 = newtLabel(2, 3, _("Size (MB): ")); 264 label3 = newtLabel(2, 4, _("Format: ")); 265 265 deviceComp = 266 266 newtEntry(14, 1, device_str, 30, (void *) &device_here, 0); … … 270 270 newtEntry(14, 4, format_str, 15, (void *) &format_here, 0); 271 271 sizeComp = newtEntry(14, 3, size_str, 10, (void *) &size_here, 0); 272 bOK = newtButton(5, 6, " OK ");273 bCancel = newtButton(17, 6, "Cancel");272 bOK = newtButton(5, 6, _(" OK ")); 273 bCancel = newtButton(17, 6, _("Cancel")); 274 274 newtPushHelpLine 275 ( "To add an entry to the mountlist, please fill in these fields and then hit 'OK'");275 (_("To add an entry to the mountlist, please fill in these fields and then hit 'OK'")); 276 276 myForm = newtForm(NULL, NULL, 0); 277 277 newtFormAddComponents(myForm, deviceComp, mountpointComp, sizeComp, … … 292 292 if (b_res == bOK) { 293 293 if (device_str[strlen(device_str) - 1] == '/') { 294 popup_and_OK( "You left the device nearly blank!");294 popup_and_OK(_("You left the device nearly blank!")); 295 295 b_res = NULL; 296 296 } 297 297 if (size_of_specific_device_in_mountlist(mountlist, device_str) 298 298 >= 0) { 299 popup_and_OK( "Can't add this - you've got one already!");299 popup_and_OK(_("Can't add this - you've got one already!")); 300 300 b_res = NULL; 301 301 } … … 346 346 sz_out[0] = '\0'; 347 347 if (popup_and_get_string 348 ("Add variable", "Enter the name of the variable to add", sz_out,348 ("Add variable", _("Enter the name of the variable to add"), sz_out, 349 349 MAX_STR_LEN)) { 350 350 strip_spaces(sz_out); … … 355 355 if (i < items) { 356 356 popup_and_OK 357 ( "No need to add that variable. It is already listed here.");357 (_("No need to add that variable. It is already listed here.")); 358 358 } else { 359 359 strcpy(raidrec->additional_vars.el[items].label, sz_out); … … 555 555 556 556 sprintf(prompt, 557 "Please enter the RAID level you want. (concat, striped, raid5)");557 _("Please enter the RAID level you want. (concat, striped, raid5)")); 558 558 if (raidrec->raidlevel == -1) { 559 559 strcpy(tmp, "concat"); … … 608 608 strcpy(personalities, 609 609 last_line_of_file("/tmp/raid-personalities.txt")); 610 sprintf(prompt, "Please enter the RAID level you want. %s",610 sprintf(prompt, _("Please enter the RAID level you want. %s"), 611 611 personalities); 612 612 if (raidrec->raid_level == -1) { … … 618 618 out != -1 && out != 0 && out != 1 && out != 4 && out != 5 619 619 && out != 10;) { 620 res = popup_and_get_string( "Specify RAID level", prompt, tmp, 10);620 res = popup_and_get_string(_("Specify RAID level"), prompt, tmp, 10); 621 621 if (!res) { 622 622 return; … … 641 641 } else { 642 642 if (ask_me_yes_or_no 643 ( "You have chosen a RAID personality which is not registered with the kernel. Make another selection?"))643 (_("You have chosen a RAID personality which is not registered with the kernel. Make another selection?"))) 644 644 { 645 645 out = 999; … … 720 720 assert_string_is_neither_NULL_nor_zerolength(raid_device); 721 721 722 sprintf(tmp, "Delete %s from RAID device %s - are you sure?",722 sprintf(tmp, _("Delete %s from RAID device %s - are you sure?"), 723 723 disklist->el[currline].device, raid_device); 724 724 if (!ask_me_yes_or_no(tmp)) { … … 768 768 device); 769 769 if (pos >= 0) { 770 sprintf(tmp, "Cannot delete %s: it is in use by RAID device %s",770 sprintf(tmp, _("Cannot delete %s: it is in use by RAID device %s"), 771 771 mountlist->el[currline].device, 772 772 raidlist->el[pos].OSSWAP(raid_device, volname)); … … 774 774 return; 775 775 } 776 sprintf(tmp, "Delete %s - are you sure?",776 sprintf(tmp, _("Delete %s - are you sure?"), 777 777 mountlist->el[currline].device); 778 778 if (!ask_me_yes_or_no(tmp)) { … … 829 829 return; 830 830 } 831 sprintf(tmp, "Do you want me to delete %s's partitions, too?", device);831 sprintf(tmp, _("Do you want me to delete %s's partitions, too?"), device); 832 832 delete_partitions_too = ask_me_yes_or_no(tmp); 833 833 if (delete_partitions_too) { … … 896 896 897 897 av = &raidrec->additional_vars; 898 sprintf(tmp, "Delete %s - are you sure?", av->el[lino].label);898 sprintf(tmp, _("Delete %s - are you sure?"), av->el[lino].label); 899 899 if (ask_me_yes_or_no(tmp)) { 900 900 if (!strcmp(av->el[lino].label, "persistent-superblock") 901 901 || !strcmp(av->el[lino].label, "chunk-size")) { 902 sprintf(tmp, "%s must not be deleted. It would be bad.",902 sprintf(tmp, _("%s must not be deleted. It would be bad."), 903 903 av->el[lino].label); 904 904 popup_and_OK(tmp); … … 967 967 warned_already = TRUE; 968 968 sprintf(tmp, 969 "Too many lines. Displaying first %d entries only. Close a directory to see more.",969 _("Too many lines. Displaying first %d entries only. Close a directory to see more."), 970 970 ARBITRARY_MAXIMUM); 971 971 popup_and_OK(tmp); … … 1105 1105 assert(filelist != NULL); 1106 1106 1107 log_to_screen( "Editing filelist");1107 log_to_screen(_("Editing filelist")); 1108 1108 newtPushHelpLine 1109 ( " Please edit the filelist to your satisfaction, then click OK or Cancel.");1109 (_(" Please edit the filelist to your satisfaction, then click OK or Cancel.")); 1110 1110 j = 4; 1111 bLess = newtCompactButton(j, 17, " Less ");1112 bMore = newtCompactButton(j += 12, 17, " More ");1113 bToggle = newtCompactButton(j += 12, 17, "Toggle");1114 bRegex = newtCompactButton(j += 12, 17, "RegEx");1115 bCancel = newtCompactButton(j += 12, 17, "Cancel");1116 bOK = newtCompactButton(j += 12, 17, " OK ");1111 bLess = newtCompactButton(j, 17, _(" Less ")); 1112 bMore = newtCompactButton(j += 12, 17, _(" More ")); 1113 bToggle = newtCompactButton(j += 12, 17, _("Toggle")); 1114 bRegex = newtCompactButton(j += 12, 17, _("RegEx")); 1115 bCancel = newtCompactButton(j += 12, 17, _("Cancel")); 1116 bOK = newtCompactButton(j += 12, 17, _(" OK ")); 1117 1117 filelistListbox = 1118 1118 newtListbox(2, 1, 15, NEWT_FLAG_SCROLL | NEWT_FLAG_RETURNEXIT); … … 1120 1120 lines_in_flist_window = 1121 1121 redraw_filelist(filelist, keylist, filelistListbox); 1122 newtOpenWindow(1, 3, 77, 18, "Editing filelist");1122 newtOpenWindow(1, 3, 77, 18, _("Editing filelist")); 1123 1123 myForm = newtForm(NULL, NULL, 0); 1124 1124 newtFormAddComponents(myForm, filelistListbox, bLess, bMore, bToggle, … … 1129 1129 finished = 1130 1130 ask_me_yes_or_no 1131 ( "Are you happy with your file selection?");1131 (_("Are you happy with your file selection?")); 1132 1132 } else if (b_res == bCancel) { 1133 1133 finished = TRUE; 1134 1134 } else if (b_res == bRegex) { 1135 popup_and_OK( "I haven't implemented this yet...");1135 popup_and_OK(_("I haven't implemented this yet...")); 1136 1136 } else { 1137 1137 curr_choice = newtListboxGetCurrent(filelistListbox); … … 1269 1269 sprintf(size_str, "%lld", mountlist->el[currline].size / 1024); 1270 1270 newtOpenWindow(20, 5, 48, 10, "Edit entry"); 1271 label0 = newtLabel(2, 1, "Device:");1272 label1 = newtLabel(2, 2, "Mountpoint:");1273 label2 = newtLabel(2, 3, "Size (MB): ");1274 label3 = newtLabel(2, 4, "Format: ");1271 label0 = newtLabel(2, 1, _("Device:")); 1272 label1 = newtLabel(2, 2, _("Mountpoint:")); 1273 label2 = newtLabel(2, 3, _("Size (MB): ")); 1274 label3 = newtLabel(2, 4, _("Format: ")); 1275 1275 deviceComp = 1276 1276 newtEntry(14, 1, device_str, 30, (void *) &device_here, 0); … … 1285 1285 sizeComp = newtEntry(14, 3, size_str, 10, (void *) &size_here, 0); 1286 1286 } 1287 bOK = newtButton(2, 6, " OK ");1288 bCancel = newtButton(14, 6, "Cancel");1287 bOK = newtButton(2, 6, _(" OK ")); 1288 bCancel = newtButton(14, 6, _("Cancel")); 1289 1289 if (strstr(mountlist->el[currline].device, RAID_DEVICE_STUB)) { 1290 1290 b_raid = newtButton(26, 6, "RAID.."); 1291 1291 } 1292 1292 newtPushHelpLine 1293 ( " Edit this partition's mountpoint, size and format; then click 'OK'.");1293 (_(" Edit this partition's mountpoint, size and format; then click 'OK'.")); 1294 1294 myForm = newtForm(NULL, NULL, 0); 1295 1295 newtFormAddComponents(myForm, deviceComp, mountpointComp, sizeComp, … … 1307 1307 && strstr(device_used_to_be, RAID_DEVICE_STUB) 1308 1308 && strcmp(device_str, device_used_to_be)) { 1309 popup_and_OK( "You can't change /dev/mdX to /dev/mdY.");1309 popup_and_OK(_("You can't change /dev/mdX to /dev/mdY.")); 1310 1310 b_res = NULL; 1311 1311 continue; 1312 1312 } else if (b_res == bOK && !strcmp(mountpoint_str, "image") 1313 1313 && strcmp(mountpt_used_to_be, "image")) { 1314 popup_and_OK( "You can't change a regular device to an image.");1314 popup_and_OK(_("You can't change a regular device to an image.")); 1315 1315 b_res = NULL; 1316 1316 continue; … … 1335 1335 */ 1336 1336 popup_and_OK 1337 ( "You cannot edit the RAID settings until you have OK'd your change to the device node.");1337 (_("You cannot edit the RAID settings until you have OK'd your change to the device node.")); 1338 1338 } else { 1339 1339 j = find_raid_device_in_raidlist(raidlist, … … 1342 1342 if (j < 0) { 1343 1343 sprintf(tmp, 1344 "/etc/raidtab does not have an entry for %s; please delete it and add it again",1344 _("/etc/raidtab does not have an entry for %s; please delete it and add it again"), 1345 1345 mountlist->el[currline].device); 1346 1346 popup_and_OK(tmp); 1347 1347 } else { 1348 log_it( "edit_raidlist_entry - calling");1348 log_it(_("edit_raidlist_entry - calling")); 1349 1349 edit_raidlist_entry(mountlist, raidlist, 1350 1350 &raidlist->el[j], currline); … … 1396 1396 else if (strcmp(device_used_to_be, device_str)) { 1397 1397 popup_and_OK 1398 ( "You are renaming a RAID device as another RAID device. I don't like it but I'll allow it.");1398 (_("You are renaming a RAID device as another RAID device. I don't like it but I'll allow it.")); 1399 1399 } 1400 1400 #endif … … 1506 1506 int currline2 = 0; 1507 1507 1508 log_it( "Started edit_raidlist_entry");1508 log_it(_("Started edit_raidlist_entry")); 1509 1509 memcpy((void *) &bkp_raidrec, (void *) raidrec, 1510 1510 sizeof(struct vinum_volume)); 1511 sprintf(title_of_editraidForm_window, "Plexes on %s",1511 sprintf(title_of_editraidForm_window, _("Plexes on %s"), 1512 1512 raidrec->volname); 1513 newtPushHelpLine( " Please select a plex to edit");1513 newtPushHelpLine(_(" Please select a plex to edit")); 1514 1514 newtOpenWindow(13, 5, 54, 15, title_of_editraidForm_window); 1515 1515 for (;;) { … … 1517 1517 char headerstr[MAX_STR_LEN]; 1518 1518 snprintf(headerstr, MAX_STR_LEN, "%-14s %-8s %11s %8s", 1519 "Plex", "Level", "Stripe Size", "Subdisks");1520 1521 bOK = newtCompactButton(2, 13, " OK ");1522 bCancel = newtCompactButton(12, 13, "Cancel");1523 bAdd = newtCompactButton(22, 13, " Add ");1524 bEdit = newtCompactButton(32, 13, " Edit ");1525 bDelete = newtCompactButton(42, 13, "Delete");1519 _("Plex"), _("Level",) _("Stripe Size"), _("Subdisks")); 1520 1521 bOK = newtCompactButton(2, 13, _(" OK ")); 1522 bCancel = newtCompactButton(12, 13, _("Cancel")); 1523 bAdd = newtCompactButton(22, 13, _(" Add ")); 1524 bEdit = newtCompactButton(32, 13, _(" Edit ")); 1525 bDelete = newtCompactButton(42, 13, _("Delete")); 1526 1526 1527 1527 plexesListbox = … … 1583 1583 if (b_res == bDelete) { 1584 1584 char msg[MAX_STR_LEN]; 1585 sprintf(msg, "Are you sure you want to delete %s.p%i?",1585 sprintf(msg, _("Are you sure you want to delete %s.p%i?"), 1586 1586 raidrec->volname, currline2); 1587 1587 if (ask_me_yes_or_no(msg)) { 1588 log_it( "Deleting RAID plex");1588 log_it(_("Deleting RAID plex")); 1589 1589 memcpy((void *) &raidrec->plex[currline2], 1590 1590 (void *) &raidrec->plex[raidrec->plexes - 1], … … 1660 1660 for (;;) { 1661 1661 log_msg(2, "Main loop"); 1662 sprintf(title_of_editraidForm_window, "Edit %s",1662 sprintf(title_of_editraidForm_window, _("Edit %s"), 1663 1663 raidrec->raid_device); 1664 1664 strcpy(sz_raid_level, … … 1666 1666 strcpy(sz_data_disks, 1667 1667 number_of_disks_as_string(raidrec->data_disks.entries, 1668 "data"));1668 _("data"))); 1669 1669 strcpy(sz_spare_disks, 1670 1670 number_of_disks_as_string(raidrec->spare_disks.entries, 1671 "spare"));1671 _("spare"))); 1672 1672 strcpy(sz_parity_disks, 1673 1673 number_of_disks_as_string(raidrec->parity_disks.entries, 1674 "parity"));1674 _("parity"))); 1675 1675 strcpy(sz_failed_disks, 1676 1676 number_of_disks_as_string(raidrec->failed_disks.entries, 1677 "failed"));1677 _("failed"))); 1678 1678 bSelectData = newtButton(1, 1, sz_data_disks); 1679 1679 bSelectSpare = newtButton(20, 1, sz_spare_disks); … … 1681 1681 bSelectFailed = newtButton(20, 5, sz_failed_disks); 1682 1682 bChangeRaid = newtButton(1, 9, sz_raid_level); 1683 bOK = newtButton(16 + (raidrec->raid_level == -1), 9, " OK ");1684 bCancel = newtButton(28, 9, "Cancel");1683 bOK = newtButton(16 + (raidrec->raid_level == -1), 9, _(" OK ")); 1684 bCancel = newtButton(28, 9, _("Cancel")); 1685 1685 bAdditional = 1686 1686 newtCompactButton(1, 13, 1687 "Additional settings and information");1687 _("Additional settings and information")); 1688 1688 newtPushHelpLine 1689 ( " Edit the RAID device's settings to your heart's content, then hit OK/Cancel.");1689 (_(" Edit the RAID device's settings to your heart's content, then hit OK/Cancel.")); 1690 1690 editraidForm = newtForm(NULL, NULL, 0); 1691 1691 newtFormAddComponents(editraidForm, bSelectData, bSelectParity, … … 1696 1696 choose_raid_level(raidrec); 1697 1697 } else if (b_res == bSelectData) { 1698 select_raid_disks(mountlist, raidlist, raidrec, "data",1698 select_raid_disks(mountlist, raidlist, raidrec, _("data"), 1699 1699 &raidrec->data_disks); 1700 1700 } else if (b_res == bSelectSpare) { 1701 select_raid_disks(mountlist, raidlist, raidrec, "spare",1701 select_raid_disks(mountlist, raidlist, raidrec, _("spare"), 1702 1702 &raidrec->spare_disks); 1703 1703 } else if (b_res == bSelectParity) { 1704 select_raid_disks(mountlist, raidlist, raidrec, "parity",1704 select_raid_disks(mountlist, raidlist, raidrec, _("parity"), 1705 1705 &raidrec->parity_disks); 1706 1706 } else if (b_res == bSelectFailed) { 1707 select_raid_disks(mountlist, raidlist, raidrec, "failed",1707 select_raid_disks(mountlist, raidlist, raidrec, _("failed"), 1708 1708 &raidrec->failed_disks); 1709 1709 } else if (b_res == bAdditional) { … … 1786 1786 raidlist->el[currline].volname, currline2); 1787 1787 newtPushHelpLine 1788 ( " Please select a subdisk to edit, or edit this plex's parameters");1788 (_(" Please select a subdisk to edit, or edit this plex's parameters")); 1789 1789 newtOpenWindow(13, 3, 54, 18, title_of_editraidForm_window); 1790 1790 for (;;) { … … 1792 1792 char headerstr[MAX_STR_LEN]; 1793 1793 char tmp[64]; 1794 snprintf(headerstr, MAX_STR_LEN, "%-24s %s", "Subdisk", "Device");1794 snprintf(headerstr, MAX_STR_LEN, "%-24s %s", _("Subdisk"), _("Device")); 1795 1795 1796 1796 … … 1806 1806 break; 1807 1807 default: 1808 sprintf(tmp, "unknown (%i)", raidrec->raidlevel);1808 sprintf(tmp, _("unknown (%i)"), raidrec->raidlevel); 1809 1809 break; 1810 1810 } 1811 bLevel = newtCompactButton(2, 2, " RAID level ");1811 bLevel = newtCompactButton(2, 2, _(" RAID level ")); 1812 1812 sLevel = newtLabel(19, 2, tmp); 1813 1813 1814 1814 if (raidrec->raidlevel >= 0) { 1815 1815 sprintf(tmp, "%ik", raidrec->stripesize); 1816 bStripeSize = newtCompactButton(2, 4, " Stripe size ");1816 bStripeSize = newtCompactButton(2, 4, _(" Stripe size ")); 1817 1817 } else { 1818 1818 strcpy(tmp, "N/A"); 1819 bStripeSize = newtLabel(2, 4, "Stripe size:");1819 bStripeSize = newtLabel(2, 4, _("Stripe size:")); 1820 1820 } 1821 1821 sStripeSize = newtLabel(19, 4, tmp); 1822 1822 1823 bOK = newtCompactButton(2, 16, " OK ");1824 bCancel = newtCompactButton(12, 16, "Cancel");1825 bAdd = newtCompactButton(22, 16, " Add ");1826 bEdit = newtCompactButton(32, 16, " Edit ");1827 bDelete = newtCompactButton(42, 16, "Delete");1823 bOK = newtCompactButton(2, 16, _(" OK ")); 1824 bCancel = newtCompactButton(12, 16, _("Cancel")); 1825 bAdd = newtCompactButton(22, 16, _(" Add ")); 1826 bEdit = newtCompactButton(32, 16, _(" Edit ")); 1827 bDelete = newtCompactButton(42, 16, _("Delete")); 1828 1828 1829 1829 … … 1911 1911 sprintf(tmp, "%i", raidrec->stripesize); 1912 1912 if (popup_and_get_string 1913 ( "Stripe size",1914 "Please enter the stripe size in kilobytes.", tmp, 20)) {1913 (_("Stripe size"), 1914 _("Please enter the stripe size in kilobytes."), tmp, 20)) { 1915 1915 raidrec->stripesize = atoi(tmp); 1916 1916 } … … 1963 1963 1964 1964 strcpy(sz_out, raidrec->additional_vars.el[lino].value); 1965 sprintf(header, "Edit %s", raidrec->additional_vars.el[lino].label);1966 sprintf(comment, "Please set %s's value (currently '%s')",1965 sprintf(header, _("Edit %s"), raidrec->additional_vars.el[lino].label); 1966 sprintf(comment, _("Please set %s's value (currently '%s')"), 1967 1967 raidrec->additional_vars.el[lino].label, sz_out); 1968 1968 if (popup_and_get_string(header, comment, sz_out, MAX_STR_LEN)) { … … 2026 2026 strcpy(flaws_str_C, "xxxxxxxxx"); 2027 2027 if (mountlist->entries > ARBITRARY_MAXIMUM) { 2028 log_to_screen( "Arbitrary limits suck, man!");2028 log_to_screen(_("Arbitrary limits suck, man!")); 2029 2029 finish(1); 2030 2030 } 2031 2031 newtPushHelpLine 2032 ( " Please edit the mountlist to your satisfaction, then click OK or Cancel.");2032 (_(" Please edit the mountlist to your satisfaction, then click OK or Cancel.")); 2033 2033 i = 4; 2034 bAdd = newtCompactButton(i, 17, " Add ");2035 bEdit = newtCompactButton(i += 11, 17, " Edit ");2036 bDelete = newtCompactButton(i += 12, 17, "Delete");2037 bReload = newtCompactButton(i += 12, 17, "Reload");2038 bCancel = newtCompactButton(i += 12, 17, "Cancel");2039 bOK = newtCompactButton(i += 12, 17, " OK ");2040 sprintf(tmp, "%-24s %-24s %-8s %s", "Device", "Mountpoint", "Format",2041 "Size (MB)");2034 bAdd = newtCompactButton(i, 17, _(" Add ")); 2035 bEdit = newtCompactButton(i += 11, 17, _(" Edit ")); 2036 bDelete = newtCompactButton(i += 12, 17, _("Delete")); 2037 bReload = newtCompactButton(i += 12, 17, _("Reload")); 2038 bCancel = newtCompactButton(i += 12, 17, _("Cancel")); 2039 bOK = newtCompactButton(i += 12, 17, _(" OK ")); 2040 sprintf(tmp, "%-24s %-24s %-8s %s", _("Device"), _("Mountpoint"), _("Format"), 2041 _("Size (MB)")); 2042 2042 headerMsg = newtLabel(2, 1, tmp); 2043 2043 flawsLabelA = newtLabel(2, 13, flaws_str_A); … … 2047 2047 newtListbox(2, 2, 10, NEWT_FLAG_SCROLL | NEWT_FLAG_RETURNEXIT); 2048 2048 redraw_mountlist(mountlist, keylist, partitionsListbox); 2049 newtOpenWindow(1, 3, 77, 18, "Editing mountlist");2049 newtOpenWindow(1, 3, 77, 18, _("Editing mountlist")); 2050 2050 myForm = newtForm(NULL, NULL, 0); 2051 2051 newtFormAddComponents(myForm, headerMsg, partitionsListbox, … … 2064 2064 finished = 2065 2065 ask_me_yes_or_no 2066 ( "Your mountlist might not work. Continue anyway?");2066 (_("Your mountlist might not work. Continue anyway?")); 2067 2067 } else { 2068 2068 finished = 2069 2069 ask_me_yes_or_no 2070 ( "Are you sure you want to save your mountlist and continue? (No changes will be made to your partition table at this time.)");2070 (_("Are you sure you want to save your mountlist and continue? (No changes will be made to your partition table at this time.)")); 2071 2071 } 2072 2072 } else if (b_res == bCancel) { 2073 2073 finished = TRUE; 2074 2074 } else if (b_res == bReload) { 2075 if (ask_me_yes_or_no( "Reload original mountlist?")) {2075 if (ask_me_yes_or_no(_("Reload original mountlist?"))) { 2076 2076 /* 2077 2077 This would be really dumb. RAIDTAB_FNAME is #define'd. --- Hugo, 2003/04/24 … … 2091 2091 i < mountlist->entries && keylist[i] != curr_choice; i++); 2092 2092 if (i == mountlist->entries && mountlist->entries > 0) { 2093 log_to_screen( "I don't know what that button does!");2093 log_to_screen(_("I don't know what that button does!")); 2094 2094 } else { 2095 2095 currline = i; … … 2109 2109 } else { 2110 2110 popup_and_OK 2111 ( "Please add an entry. Then press ENTER to edit it.");2111 (_("Please add an entry. Then press ENTER to edit it.")); 2112 2112 } 2113 2113 } … … 2119 2119 newtPopHelpLine(); 2120 2120 if (b_res == bOK) { 2121 log_it( "You pushed 'OK'. I shall now continue.");2121 log_it(_("You pushed 'OK'. I shall now continue.")); 2122 2122 return (0); 2123 2123 } else { … … 2198 2198 sprintf(title_of_window, "Additional variables"); 2199 2199 newtPushHelpLine 2200 ( " Edit the additional fields to your heart's content, then click OK or Cancel.");2201 headerMsg = newtLabel(1, 1, "Label Value");2200 (_(" Edit the additional fields to your heart's content, then click OK or Cancel.")); 2201 headerMsg = newtLabel(1, 1, _("Label Value")); 2202 2202 varsListbox = 2203 2203 newtListbox(1, 2, 6, NEWT_FLAG_SCROLL | NEWT_FLAG_RETURNEXIT); 2204 2204 i = 1; 2205 bAdd = newtCompactButton(i, 9, " Add ");2206 bEdit = newtCompactButton(i += 8, 9, " Edit ");2207 bDelete = newtCompactButton(i += 9, 9, "Delete");2208 bOK = newtCompactButton(i += 9, 9, " OK ");2209 bCancel = newtCompactButton(i += 9, 9, "Cancel");2205 bAdd = newtCompactButton(i, 9, _(" Add ")); 2206 bEdit = newtCompactButton(i += 8, 9, _(" Edit ")); 2207 bDelete = newtCompactButton(i += 9, 9, _("Delete")); 2208 bOK = newtCompactButton(i += 9, 9, _(" OK ")); 2209 bCancel = newtCompactButton(i += 9, 9, _("Cancel")); 2210 2210 newtOpenWindow(17, 7, 46, 10, title_of_window); 2211 2211 myForm = newtForm(NULL, NULL, 0); … … 2361 2361 2362 2362 if (popup_and_get_string 2363 ( "ISO Mode - device", "On what device do the ISO files live?",2363 (_("ISO Mode - device"), _("On what device do the ISO files live?"), 2364 2364 isodir_device, MAX_STR_LEN / 4)) { 2365 2365 if (popup_and_get_string 2366 ( "ISO Mode - format",2367 "What is the disk format of the device? (Hit ENTER if you don't know.)",2366 (_("ISO Mode - format"), 2367 _("What is the disk format of the device? (Hit ENTER if you don't know.)"), 2368 2368 isodir_format, 16)) { 2369 2369 if (popup_and_get_string 2370 ( "ISO Mode - path",2371 "At what path on this device can the ISO files be found?",2370 (_("ISO Mode - path"), 2371 _("At what path on this device can the ISO files be found?"), 2372 2372 isodir_path, MAX_STR_LEN / 4)) { 2373 2373 strip_spaces(isodir_device); … … 2467 2467 2468 2468 newtPushHelpLine 2469 ( "This is where I nuke your hard drives. Mhahahahaha. No-one can stop Mojo Jojo!");2470 newtOpenWindow(24, 3, 32, 13, "Nuking");2471 b1 = newtButton(7, 1, "Slowly");2472 b2 = newtButton(7, 5, "Medium");2473 b3 = newtButton(7, 9, "Quickly");2469 (_("This is where I nuke your hard drives. Mhahahahaha. No-one can stop Mojo Jojo!")); 2470 newtOpenWindow(24, 3, 32, 13, _("Nuking")); 2471 b1 = newtButton(7, 1, _("Slowly")); 2472 b2 = newtButton(7, 5, _("Medium")); 2473 b3 = newtButton(7, 9, _("Quickly")); 2474 2474 myForm = newtForm(NULL, NULL, 0); 2475 2475 newtFormAddComponents(myForm, b1, b2, b3, NULL); … … 2837 2837 iamhere("Post-malloc"); 2838 2838 strcpy(help_text, 2839 " Edit this RAID device's list of partitions. Choose OK or Cancel when done.");2840 sprintf(header_text, "%-24s %s", "Device", "Index");2841 sprintf(title_of_window, "%s contains...", raidrec->raid_device);2839 _(" Edit this RAID device's list of partitions. Choose OK or Cancel when done.")); 2840 sprintf(header_text, "%-24s %s", _("Device"), _("Index")); 2841 sprintf(title_of_window, _("%s contains..."), raidrec->raid_device); 2842 2842 newtPushHelpLine(help_text); 2843 2843 for (b_res = (newtComponent) 12345; b_res != bOK && b_res != bCancel;) { … … 2847 2847 redraw_disklist(disklist, keylist, partitionsListbox); 2848 2848 i = 1; 2849 bAdd = newtCompactButton(i, 9, " Add ");2850 bDelete = newtCompactButton(i += 8, 9, "Delete");2851 bOK = newtCompactButton(i += 9, 9, " OK ");2852 bCancel = newtCompactButton(i += 9, 9, "Cancel");2849 bAdd = newtCompactButton(i, 9, _(" Add ")); 2850 bDelete = newtCompactButton(i += 8, 9, _("Delete")); 2851 bOK = newtCompactButton(i += 9, 9, _(" OK ")); 2852 bCancel = newtCompactButton(i += 9, 9, _("Cancel")); 2853 2853 newtOpenWindow(21, 7, 38, 10, title_of_window); 2854 2854 myForm = newtForm(NULL, NULL, 0); … … 2869 2869 i++); 2870 2870 if (i == disklist->entries && disklist->entries > 0) { 2871 log_to_screen( "I don't know what that button does!");2871 log_to_screen(_("I don't know what that button does!")); 2872 2872 } else { 2873 2873 currline = i; 2874 2874 if (b_res == bAdd) { 2875 log_it( "Making list of unallocated RAID slices");2875 log_it(_("Making list of unallocated RAID slices")); 2876 2876 make_list_of_unallocated_raid_partitions 2877 2877 (unallocated_raid_partitions, mountlist_dontedit, … … 2879 2879 if (unallocated_raid_partitions->entries <= 0) { 2880 2880 popup_and_OK 2881 ( "There are no unallocated partitions marked for RAID.");2881 (_("There are no unallocated partitions marked for RAID.")); 2882 2882 } else { 2883 2883 log_it 2884 ( "Done. The user may add one or more of the above to RAID device");2884 (_("Done. The user may add one or more of the above to RAID device")); 2885 2885 add_disklist_entry(disklist, raidrec->raid_device, 2886 2886 unallocated_raid_partitions); 2887 log_it( "I have finished adding a disklist entry.");2887 log_it(_("I have finished adding a disklist entry.")); 2888 2888 redraw_disklist(disklist, keylist, 2889 2889 partitionsListbox); … … 2894 2894 redraw_disklist(disklist, keylist, partitionsListbox); 2895 2895 } else { 2896 sprintf(tmp, "%s's index is %d. What should it be?",2896 sprintf(tmp, _("%s's index is %d. What should it be?"), 2897 2897 raidrec->raid_device, 2898 2898 disklist->el[currline].index); 2899 2899 sprintf(sz_res, "%d", disklist->el[currline].index); 2900 if (popup_and_get_string( "Set index", tmp, sz_res, 10)) {2900 if (popup_and_get_string(_("Set index"), tmp, sz_res, 10)) { 2901 2901 disklist->el[currline].index = atoi(sz_res); 2902 2902 } … … 2955 2955 for (output = 'z'; !strchr("AICE", output); output = tmp[0]) { 2956 2956 printf 2957 ( "Which mode - (A)utomatic, (I)nteractive, \n(C)ompare only, or (E)xit to shell?\n--> ");2957 (_("Which mode - (A)utomatic, (I)nteractive, \n(C)ompare only, or (E)xit to shell?\n--> ")); 2958 2958 fgets(tmp, MAX_STR_LEN - 1, stdin); 2959 2959 } … … 2962 2962 2963 2963 newtPushHelpLine 2964 ( " Do you want to 'nuke' your system, restore interactively, or just compare?");2965 newtOpenWindow(24, 3, 32, 17, "How should I restore?");2966 b1 = newtButton(7, 1, "Automatically");2967 b2 = newtButton(7, 5, "Interactively");2968 b3 = newtButton(7, 9, "Compare only!");2969 b4 = newtButton(7, 13, "Exit to shell");2964 (_(" Do you want to 'nuke' your system, restore interactively, or just compare?")); 2965 newtOpenWindow(24, 3, 32, 17, _("How should I restore?")); 2966 b1 = newtButton(7, 1, _("Automatically")); 2967 b2 = newtButton(7, 5, _("Interactively")); 2968 b3 = newtButton(7, 9, _("Compare only!")); 2969 b4 = newtButton(7, 13, _("Exit to shell")); 2970 2970 myForm = newtForm(NULL, NULL, 0); 2971 2971 newtFormAddComponents(myForm, b1, b2, b3, b4, NULL);
Note:
See TracChangeset
for help on using the changeset viewer.