Added translation comments.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@35800 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Michael Pfeiffer 2010-03-10 18:11:58 +00:00
parent 47f23fb5c1
commit c7e6a67024
8 changed files with 41 additions and 34 deletions

View File

@ -156,7 +156,7 @@ BootManagerController::_HasSelectedPartitions()
BAlert* alert = new BAlert("info",
TR("At least one partition must be selected!"),
TR("OK"));
TR_CMT("OK", "Button"));
alert->Go();
return false;
@ -168,8 +168,8 @@ BootManagerController::_WriteBootMenu()
{
BAlert* alert = new BAlert("confirm", TR("About to write the boot menu "
"to disk. Are you sure you want to continue?"),
TR("Write boot menu"),
TR("Back"), NULL, B_WIDTH_AS_USUAL, B_WARNING_ALERT);
TR_CMT("Write boot menu", "Button"),
TR_CMT("Back", "Button"), NULL, B_WIDTH_AS_USUAL, B_WARNING_ALERT);
if (alert->Go() == 1)
return false;
@ -206,7 +206,8 @@ BootManagerController::_RestoreMBR()
message.ReplaceFirst("%file", path);
BAlert* alert = new BAlert("confirm", message.String(),
TR("Restore MBR"), TR("Back"),
TR_CMT("Restore MBR", "Button"),
TR_CMT("Back", "Button"),
NULL, B_WIDTH_AS_USUAL, B_WARNING_ALERT);
if (alert->Go() == 1)
return false;
@ -231,7 +232,7 @@ BootManagerController::CreatePage(int32 state, WizardView* wizard)
case kStateErrorEntry:
page = _CreateErrorEntryPage(frame);
wizard->SetPreviousButtonHidden(true);
wizard->SetNextButtonLabel(TR("Done"));
wizard->SetNextButtonLabel(TR_CMT("Done", "Button"));
break;
case kStateSaveMBR:
page = _CreateSaveMBRPage(frame);
@ -249,11 +250,11 @@ BootManagerController::CreatePage(int32 state, WizardView* wizard)
break;
case kStateInstallSummary:
page = _CreateInstallSummaryPage(frame);
wizard->SetNextButtonLabel(TR("Next"));
wizard->SetNextButtonLabel(TR_CMT("Next", "Button"));
break;
case kStateInstalled:
page = _CreateInstalledPage(frame);
wizard->SetNextButtonLabel(TR("Done"));
wizard->SetNextButtonLabel(TR_CMT("Done", "Button"));
break;
case kStateUninstall:
page = _CreateUninstallPage(frame);
@ -278,14 +279,14 @@ BootManagerController::_CreateErrorEntryPage(BRect frame)
if (fReadPartitionsStatus == kErrorBootSectorTooSmall)
description <<
TR("Partition table not compatible") << "\n\n" <<
TR_CMT("Partition table not compatible", "Title") << "\n\n" <<
TR("The partition table of the first hard disk is not compatible "
"with Boot Manager.\n"
"Boot Manager needs 2 KB available space before the first "
"partition.");
else
description <<
TR("Error reading partition table") << "\n\n" <<
TR_CMT("Error reading partition table", "Title") << "\n\n" <<
TR("Boot Manager is unable to read the partition table!");
return new DescriptionPage(frame, "errorEntry", description.String(), true);
@ -300,7 +301,7 @@ BootManagerController::_CreateSaveMBRPage(BRect frame)
fSettings.FindString("disk", &disk);
description <<
TR("Backup Master Boot Record") << "\n\n" <<
TR_CMT("Backup Master Boot Record", "Title") << "\n\n" <<
TR("The Master Boot Record (MBR) of the boot device:\n"
"\t%s\n"
"will now be saved to disk. Please select a file to "
@ -325,12 +326,12 @@ BootManagerController::_CreateMBRSavedPage(BRect frame)
if (fSaveMBRStatus == B_OK) {
description <<
TR("Old Master Boot Record saved") << "\n\n" <<
TR_CMT("Old Master Boot Record saved", "Title") << "\n\n" <<
TR("The old Master Boot Record was successfully save to %s.") <<
"\n";
} else {
description <<
TR("Old Master Boot Record Saved failure") << "\n\n" <<
TR_CMT("Old Master Boot Record Saved failure", "Title") << "\n\n" <<
TR("The old Master Boot Record could not be saved to %s") <<
"\n";
}
@ -348,7 +349,7 @@ BootManagerController::_CreateInstallSummaryPage(BRect frame)
fSettings.FindString("disk", &disk);
description <<
TR("Summary") << "\n\n" <<
TR_CMT("Summary", "Title") << "\n\n" <<
TR("About to write the following boot menu to the boot disk "
"(%s). Please verify the information below before continuing.") <<
"\n\n";
@ -384,12 +385,12 @@ BootManagerController::_CreateInstalledPage(BRect frame)
if (fWriteBootMenuStatus == B_OK) {
description <<
TR("Installation of boot menu completed") << "\n\n" <<
TR_CMT("Installation of boot menu completed", "Title") << "\n\n" <<
TR("The boot manager has been successfully installed "
"on your system.");
} else {
description <<
TR("Installation of boot menu failed") << "\n\n" <<
TR_CMT("Installation of boot menu failed", "Title") << "\n\n" <<
TR("An error occurred writing the boot menu. "
"The Master Boot Record might be destroyed, "
"you should restore the MBR now!");
@ -405,13 +406,13 @@ BootManagerController::_CreateUninstallPage(BRect frame)
BString description;
description <<
TR("Uninstall boot manager") << "\n\n" <<
TR_CMT("Uninstall boot manager", "Title") << "\n\n" <<
TR("Please locate the Master Boot Record (MBR) save file to "
"restore from. This is the file that was created when the "
"boot manager was first installed.");
return new FileSelectionPage(&fSettings, frame, "restoreMBR", description.String(),
B_OPEN_PANEL);
return new FileSelectionPage(&fSettings, frame, "restoreMBR",
description.String(), B_OPEN_PANEL);
}
@ -426,14 +427,15 @@ BootManagerController::_CreateUninstalledPage(BRect frame)
if (fRestoreMBRStatus == B_OK) {
description <<
TR("Uninstallation of boot menu completed") << "\n\n" <<
TR_CMT("Uninstallation of boot menu completed", "Title") <<
"\n\n" <<
TR("The Master Boot Record of the boot device "
"(%s) has been successfully restored from %s.");
description.ReplaceFirst("%s", disk);
description.ReplaceLast("%s", file);
} else {
description <<
TR("Uninstallation of boot menu failed") << "\n\n" <<
TR_CMT("Uninstallation of boot menu failed", "Title") << "\n\n" <<
TR("The Master Boot Record could not be restored!");
}

View File

@ -27,7 +27,8 @@
BootManagerWindow::BootManagerWindow()
: BWindow(BRect(100, 100, 500, 400), TR("Boot Manager"), B_TITLED_WINDOW,
: BWindow(BRect(100, 100, 500, 400), TR_CMT("Boot Manager", "Window Title"),
B_TITLED_WINDOW,
B_ASYNCHRONOUS_CONTROLS | B_NOT_ZOOMABLE)
{
float minWidth, maxWidth, minHeight, maxHeight;

View File

@ -95,7 +95,7 @@ DefaultPartitionPage::_BuildUI()
BString text;
text <<
TR("Default Partition") << "\n\n" <<
TR_CMT("Default Partition", "Title") << "\n\n" <<
TR("Please specify a default partition and a timeout.\n"
"The boot menu will load the default partition after "
"the timeout unless you select another partition. You "
@ -110,7 +110,7 @@ DefaultPartitionPage::_BuildUI()
BPopUpMenu* popUpMenu = _CreatePopUpMenu();
fDefaultPartition = new BMenuField(rect, "partitions",
TR("Default Partition:"), popUpMenu);
TR_CMT("Default Partition:", "Menu field label"), popUpMenu);
float divider = be_plain_font->StringWidth(fDefaultPartition->Label()) + 3;
fDefaultPartition->SetDivider(divider);
AddChild(fDefaultPartition);
@ -141,9 +141,11 @@ DefaultPartitionPage::_CreatePopUpMenu()
BMenuItem* selectedItem = NULL;
int32 selectedItemIndex = 0;
BPopUpMenu* menu = new BPopUpMenu(TR("Partitions"));
BPopUpMenu* menu = new BPopUpMenu(TR_CMT("Partitions",
"Pop up menu title"));
BMessage message;
for (int32 i = 0; fSettings->FindMessage("partition", i, &message) == B_OK; i ++) {
for (int32 i = 0; fSettings->FindMessage("partition", i, &message) == B_OK;
i ++) {
bool show;
if (message.FindBool("show", &show) != B_OK || !show)

View File

@ -65,7 +65,7 @@ EntryPage::_BuildUI()
BString text;
text <<
TR("Install boot menu") << "\n\n" <<
TR_CMT("Install boot menu", "Title") << "\n\n" <<
TR("Choose this option to install a boot menu, "
"allowing you to select which operating "
"system to boot when you turn on your "
@ -82,7 +82,7 @@ EntryPage::_BuildUI()
text.Truncate(0);
text <<
TR("Uninstall boot menu") << "\n\n" <<
TR_CMT("Uninstall boot menu", "Title") << "\n\n" <<
TR("Choose this option to remove the boot menu "
"previously installed by this program.\n");
fUninstallText = CreateDescription(textRect, "uninstallText", text);

View File

@ -102,12 +102,13 @@ FileSelectionPage::_BuildUI(const char* description)
fSettings->FindString("file", &file);
// TODO align text and button
fFile = new BTextControl(rect, "file", TR("File:"), file.String(),
new BMessage());
fFile = new BTextControl(rect, "file",
TR_CMT("File:", "Text control label"),
file.String(), new BMessage());
fFile->SetDivider(be_plain_font->StringWidth(fFile->Label()) + 5);
AddChild(fFile);
fSelect = new BButton(rect, "select", TR("Select"),
fSelect = new BButton(rect, "select", TR_CMT("Select", "Button"),
new BMessage(kMsgOpenFilePanel),
B_FOLLOW_RIGHT);
fSelect->ResizeToPreferred();

View File

@ -98,7 +98,7 @@ PartitionsPage::_BuildUI()
BString text;
text <<
TR("Partitions") << "\n\n" <<
TR_CMT("Partitions", "Title") << "\n\n" <<
TR("The following partitions were detected. Please "
"check the box next to the partitions to be included "
"in the boot menu. You can also set the names of the "

View File

@ -50,7 +50,7 @@ UninstallPage::_BuildUI()
BString text;
text <<
TR("Uninstall Boot Manager") << "\n\n" <<
TR_CMT("Uninstall Boot Manager", "Title") << "\n\n" <<
TR("Please locate the Master Boot Record (MBR) save file to "
"restore from. This is the file that was created when the "
"boot manager was first installed.");

View File

@ -143,13 +143,14 @@ WizardView::_BuildUI()
B_FOLLOW_LEFT_RIGHT | B_FOLLOW_BOTTOM);
AddChild(fSeparator);
fPrevious = new BButton(BRect(0, 0, 100, 20), "previous", TR("Previous"),
fPrevious = new BButton(BRect(0, 0, 100, 20), "previous",
TR_CMT("Previous", "Button"),
new BMessage(kMessagePrevious),
B_FOLLOW_LEFT | B_FOLLOW_BOTTOM);
AddChild(fPrevious);
fPrevious->ResizeToPreferred();
fNext = new BButton(BRect(0, 0, 100, 20), "next", TR("Next"),
fNext = new BButton(BRect(0, 0, 100, 20), "next", TR_CMT("Next", "Button"),
new BMessage(kMessageNext),
B_FOLLOW_RIGHT | B_FOLLOW_BOTTOM);
AddChild(fNext);