Ticket #7480: Mail_localization.patch
File Mail_localization.patch, 23.8 KB (added by , 13 years ago) |
---|
-
src/preferences/mail/AutoConfigWindow.cpp
29 29 30 30 AutoConfigWindow::AutoConfigWindow(BRect rect, ConfigWindow *parent) 31 31 : 32 BWindow(rect, "Create new account", B_TITLED_WINDOW_LOOK,32 BWindow(rect, B_TRANSLATE("Create new account"), B_TITLED_WINDOW_LOOK, 33 33 B_MODAL_APP_WINDOW_FEEL, 34 34 B_NOT_RESIZABLE | B_NOT_ZOOMABLE | B_AVOID_FRONT, B_ALL_WORKSPACES), 35 35 fParentWindow(parent), … … 93 93 fMainView->GetBasicAccountInfo(fAccountInfo); 94 94 if (!fMainView->IsValidMailAddress(fAccountInfo.email)) { 95 95 invalidMailAlert = new BAlert("invalidMailAlert", 96 "Enter a valid e-mail address.", "OK"); 96 B_TRANSLATE("Enter a valid e-mail address."), 97 B_TRANSLATE("OK")); 97 98 invalidMailAlert->Go(); 98 99 return; 99 100 } -
src/preferences/mail/Jamfile
23 23 main.cpp 24 24 ; 25 25 26 AddResources E-mail : e-mail.rdef ; 26 27 27 28 Preference E-mail 28 29 : … … 30 31 : 31 32 be libmail.so $(HAIKU_NETWORK_LIBS) $(TARGET_NETAPI_LIB) $(TARGET_LIBSTDC++) 32 33 $(TARGET_LIBSUPC++) $(HAIKU_LOCALE_LIBS) 33 : e-mail.rdef34 34 ; 35 35 36 36 DoCatalogs E-mail 37 : x-vnd.Haiku-Mail 38 : ConfigViews.cpp 39 ConfigWindow.cpp 37 : 38 x-vnd.Haiku-Mail 39 : 40 AutoConfigView.cpp 41 AutoConfigWindow.cpp 42 ConfigViews.cpp 43 ConfigWindow.cpp 44 FilterConfigView.cpp 40 45 ; 41 46 42 47 -
src/preferences/mail/AutoConfigView.cpp
49 49 topLeft.y += stepSize; 50 50 rightDown.y += stepSize; 51 51 fEmailView = new BTextControl(BRect(topLeft, rightDown), "email", 52 "E-mail address:", "", new BMessage(kEMailChangedMsg));52 B_TRANSLATE("E-mail address:"), "", new BMessage(kEMailChangedMsg)); 53 53 fEmailView->SetDivider(divider); 54 54 AddChild(fEmailView); 55 55 … … 57 57 topLeft.y += stepSize; 58 58 rightDown.y += stepSize; 59 59 fLoginNameView = new BTextControl(BRect(topLeft, rightDown), 60 "login", "Login name:", "", NULL);60 "login", B_TRANSLATE("Login name:"), "", NULL); 61 61 fLoginNameView->SetDivider(divider); 62 62 AddChild(fLoginNameView); 63 63 … … 65 65 topLeft.y += stepSize; 66 66 rightDown.y += stepSize; 67 67 fPasswordView = new BTextControl(BRect(topLeft, rightDown), "password", 68 "Password:", "", NULL);68 B_TRANSLATE("Password:"), "", NULL); 69 69 fPasswordView->SetDivider(divider); 70 70 fPasswordView->TextView()->HideTyping(true); 71 71 AddChild(fPasswordView); … … 74 74 topLeft.y += stepSize; 75 75 rightDown.y += stepSize; 76 76 fAccountNameView = new BTextControl(BRect(topLeft, rightDown), "account", 77 "Account name:", "", NULL);77 B_TRANSLATE("Account name:"), "", NULL); 78 78 fAccountNameView->SetDivider(divider); 79 79 AddChild(fAccountNameView); 80 80 … … 82 82 topLeft.y += stepSize; 83 83 rightDown.y += stepSize; 84 84 fNameView = new BTextControl(BRect(topLeft, rightDown), "name", 85 "Real name:", "", NULL);85 B_TRANSLATE("Real name:"), "", NULL); 86 86 AddChild(fNameView); 87 87 fNameView->SetDivider(divider); 88 88 } … … 312 312 serverName = info.providerInfo.pop_server; 313 313 314 314 fInboundNameView = new BTextControl(BRect(10, 20, rect.Width() - 20, 35), 315 "inbound", "Server Name:", serverName.String(),315 "inbound", B_TRANSLATE("Server Name:"), serverName.String(), 316 316 new BMessage(kServerChangedMsg)); 317 317 fInboundNameView->SetDivider(divider); 318 318 -
src/preferences/mail/ConfigWindow.cpp
648 648 649 649 BPopUpMenu rightClickMenu("accounts", false, false); 650 650 651 BMenuItem* inMenuItem = new BMenuItem("Incoming", NULL); 652 BMenuItem* outMenuItem = new BMenuItem("Outgoing", NULL); 651 BMenuItem* inMenuItem = new BMenuItem(B_TRANSLATE("Incoming"), 652 NULL); 653 BMenuItem* outMenuItem = new BMenuItem(B_TRANSLATE("Outgoing"), 654 NULL); 653 655 rightClickMenu.AddItem(inMenuItem); 654 656 rightClickMenu.AddItem(outMenuItem); 655 657 … … 896 898 item = new AccountItem(label, account, ACCOUNT_ITEM); 897 899 fAccountsListView->AddItem(item); 898 900 899 item = new AccountItem(B_TRANSLATE(" 901 item = new AccountItem(B_TRANSLATE("· Incoming"), account, INBOUND_ITEM); 900 902 fAccountsListView->AddItem(item); 901 903 if (!account->IsInboundEnabled()) 902 904 item->SetEnabled(false); 903 905 904 item = new AccountItem(B_TRANSLATE(" 906 item = new AccountItem(B_TRANSLATE("· Outgoing"), account, 905 907 OUTBOUND_ITEM); 906 908 fAccountsListView->AddItem(item); 907 909 if (!account->IsOutboundEnabled()) 908 910 item->SetEnabled(false); 909 911 910 item = new AccountItem(B_TRANSLATE(" 912 item = new AccountItem(B_TRANSLATE("· E-mail filters"), account, 911 913 FILTER_ITEM); 912 914 fAccountsListView->AddItem(item); 913 915 } -
src/add-ons/mail_daemon/inbound_protocols/pop3/ConfigView.cpp
42 42 #endif 43 43 ) 44 44 { 45 AddAuthMethod( "Plain text");46 AddAuthMethod( "APOP");45 AddAuthMethod(B_TRANSLATE("Plain text")); 46 AddAuthMethod(B_TRANSLATE("APOP")); 47 47 48 48 #if USE_SSL 49 AddFlavor( "No encryption");50 AddFlavor( "SSL");49 AddFlavor(B_TRANSLATE("No encryption")); 50 AddFlavor(B_TRANSLATE("SSL")); 51 51 #endif 52 52 53 53 SetTo(settings); -
src/add-ons/mail_daemon/inbound_protocols/pop3/pop3.cpp
343 343 fLog = ""; 344 344 345 345 // Prime the error message 346 BString error_msg; 347 error_msg << B_TRANSLATE("Error while connecting to server ") << server; 346 BString error_msg, servString; 347 error_msg << B_TRANSLATE("Error while connecting to server %serv"); 348 349 servString << server; 350 error_msg.ReplaceFirst("%serv", servString); 351 348 352 if (port != 110) 349 353 error_msg << ":" << port; 350 354 … … 445 449 { 446 450 status_t err; 447 451 448 BString error_msg ;449 error_msg << B_TRANSLATE("Error while authenticating user ") << uid;452 BString error_msg, userString; 453 error_msg << B_TRANSLATE("Error while authenticating user %user"); 450 454 455 userString << uid; 456 error_msg.ReplaceFirst("%user", userString); 457 451 458 if (method == 1) { //APOP 452 459 int32 index = fLog.FindFirst("<"); 453 460 if(index != B_ERROR) { -
src/add-ons/mail_daemon/inbound_protocols/imap/imap_config.cpp
60 60 fAddonSettings(settings) 61 61 { 62 62 #ifdef USE_SSL 63 AddFlavor( "No encryption");64 AddFlavor( "SSL");63 AddFlavor(B_TRANSLATE("No encryption")); 64 AddFlavor(B_TRANSLATE("SSL")); 65 65 #endif 66 66 67 67 SetTo(settings); -
src/add-ons/mail_daemon/outbound_protocols/smtp/ConfigView.cpp
44 44 ) 45 45 { 46 46 #ifdef USE_SSL 47 AddFlavor( "Unencrypted");48 AddFlavor( "SSL");49 AddFlavor( "STARTTLS");47 AddFlavor(B_TRANSLATE("Unencrypted")); 48 AddFlavor(B_TRANSLATE("SSL")); 49 AddFlavor(B_TRANSLATE("STARTTLS")); 50 50 #endif 51 51 52 52 AddAuthMethod(B_TRANSLATE("None"), false); … … 54 54 AddAuthMethod(B_TRANSLATE("POP3 before SMTP"), false); 55 55 56 56 BTextControl *control = (BTextControl *)(FindView("host")); 57 control->SetLabel(B_TRANSLATE("SMTP server: 57 control->SetLabel(B_TRANSLATE("SMTP server:")); 58 58 59 59 // Reset the dividers after changing one 60 60 float widestLabel = 0; -
src/add-ons/mail_daemon/outbound_protocols/smtp/smtp.cpp
281 281 status = Open(fSettingsMessage.FindString("server"), 282 282 fSettingsMessage.FindInt32("port"), authMethod == 1); 283 283 if (status < B_OK) { 284 error_msg << B_TRANSLATE("Error while opening connection to ")285 << fSettingsMessage.FindString("server");284 error_msg << B_TRANSLATE("Error while opening connection to %serv"); 285 error_msg.ReplaceFirst("%serv", fSettingsMessage.FindString("server")); 286 286 287 287 if (fSettingsMessage.FindInt32("port") > 0) 288 288 error_msg << ":" << fSettingsMessage.FindInt32("port"); … … 304 304 305 305 if (status != B_OK) { 306 306 //-----This is a really cool kind of error message. How can we make it work for POP3? 307 error_msg << B_TRANSLATE("Error while logging in to ") 308 << fSettingsMessage.FindString("server") 307 error_msg << B_TRANSLATE("Error while logging in to %serv") 309 308 << B_TRANSLATE(". The server said:\n") << fLog; 309 310 error_msg.ReplaceFirst("%serv", fSettingsMessage.FindString("server")); 311 310 312 ShowError(error_msg.String()); 311 313 } 312 314 return B_OK; -
src/add-ons/mail_daemon/inbound_filters/notifier/ConfigView.cpp
33 33 // determine font height 34 34 font_height fontHeight; 35 35 GetFontHeight(&fontHeight); 36 float itemHeight = (int32)(fontHeight.ascent + fontHeight.descent + fontHeight.leading) + 6; 37 36 float itemHeight = (int32)(fontHeight.ascent + fontHeight.descent 37 + fontHeight.leading) + 6; 38 38 39 BRect frame(5,2,250,itemHeight + 2); 39 40 BPopUpMenu *menu = new BPopUpMenu(B_EMPTY_STRING,false,false); 40 41 … … 58 59 AddChild(field); 59 60 60 61 ResizeToPreferred(); 61 } 62 } 62 63 63 64 64 65 void ConfigView::AttachedToWindow() … … 105 106 label.Prepend(item->Label()); 106 107 } 107 108 if (label == "") 108 label = "none";109 label = B_TRANSLATE("none"); 109 110 field->MenuItem()->SetLabel(label.String()); 110 111 } 111 112 … … 119 120 BMenuItem *item; 120 121 if (msg->FindPointer("source",(void **)&item) < B_OK) 121 122 break; 122 123 123 124 item->SetMarked(!item->IsMarked()); 124 125 UpdateNotifyText(); 125 126 break; … … 151 152 return B_OK; 152 153 } 153 154 154 155 155 156 void ConfigView::GetPreferredSize(float *width, float *height) 156 157 { 157 158 *width = 258; … … 171 172 BString 172 173 descriptive_name() 173 174 { 174 return "New mails notification";175 return B_TRANSLATE("New mails notification"); 175 176 } -
src/add-ons/mail_daemon/inbound_filters/notifier/filter.cpp
78 78 text.ReplaceFirst("%name", fMailProtocol.AccountSettings().Name()); 79 79 80 80 BAlert *alert = new BAlert(B_TRANSLATE("New messages"), text.String(), 81 "OK", NULL, NULL, B_WIDTH_AS_USUAL);81 B_TRANSLATE("OK"), NULL, NULL, B_WIDTH_AS_USUAL); 82 82 alert->SetFeel(B_NORMAL_WINDOW_FEEL); 83 83 alert->Go(NULL); 84 84 } … … 98 98 } 99 99 100 100 if (fStrategy & log_window) { 101 BString message ;101 BString message, numString; 102 102 if (fNNewMessages != 1) 103 message << fNNewMessages << B_TRANSLATE("new messages");103 message << B_TRANSLATE("%num new messages"); 104 104 else 105 message << fNNewMessages << B_TRANSLATE(" new message"); 105 message << B_TRANSLATE("%num new message"); 106 107 numString << fNNewMessages; 108 message.ReplaceFirst("%num", numString); 109 106 110 fMailProtocol.ShowMessage(message.String()); 107 111 } 108 112 -
src/add-ons/mail_daemon/inbound_filters/match_header/ConfigView.cpp
55 55 SetViewColor(ui_color(B_PANEL_BACKGROUND_COLOR)); 56 56 attr = new BTextControl(BRect(5,5,100,20),"attr", B_TRANSLATE("If"), 57 57 B_TRANSLATE("header (e.g. Subject)"),NULL); 58 attr->SetDivider(be_plain_font->StringWidth(B_TRANSLATE("If 58 attr->SetDivider(be_plain_font->StringWidth(B_TRANSLATE("If"))+ 4); 59 59 if (settings->HasString("attribute")) 60 60 attr->SetText(settings->FindString("attribute")); 61 61 AddChild(attr); 62 62 63 regex = new BTextControl(BRect(104,5,255,20),"attr", B_TRANSLATE(" has"),63 regex = new BTextControl(BRect(104,5,255,20),"attr", B_TRANSLATE("has"), 64 64 B_TRANSLATE("value (use REGEX: in from of regular expressions like " 65 65 "*spam*)"), NULL); 66 regex->SetDivider(be_plain_font->StringWidth(B_TRANSLATE(" has")) + 4);66 regex->SetDivider(be_plain_font->StringWidth(B_TRANSLATE("has")) + 4); 67 67 if (settings->HasString("regex")) 68 68 regex->SetText(settings->FindString("regex")); 69 69 AddChild(regex); -
src/add-ons/mail_daemon/inbound_filters/match_header/Jamfile
21 21 x-vnd.Haiku-MatchHeader 22 22 : 23 23 ConfigView.cpp 24 RuleFilter.cpp 24 25 ; -
src/add-ons/mail_daemon/inbound_filters/match_header/RuleFilter.cpp
9 9 #include <stdlib.h> 10 10 #include <stdio.h> 11 11 12 #include <Catalog.h> 12 13 #include <Directory.h> 13 14 #include <fs_attr.h> 14 15 #include <Node.h> … … 17 18 #include <MailProtocol.h> 18 19 19 20 21 #undef B_TRANSLATE_CONTEXT 22 #define B_TRANSLATE_CONTEXT "RuleFilter" 23 24 20 25 RuleFilter::RuleFilter(MailProtocol& protocol, AddonSettings* addonSettings) 21 26 : 22 27 MailFilter(protocol, addonSettings) … … 28 33 29 34 BString regex; 30 35 settings->FindString("regex", ®ex); 31 36 32 37 int32 index = regex.FindFirst("REGEX:"); 33 38 if (index == B_ERROR || index > 0) 34 39 EscapeRegexTokens(regex); 35 40 else 36 41 regex.RemoveFirst("REGEX:"); 37 42 38 43 fMatcher.SetPattern(regex, false); 39 44 40 45 settings->FindString("argument",&fArg); 41 46 settings->FindInt32("do_what",(long *)&fDoWhat); 42 47 if (fDoWhat == Z_SET_REPLY) … … 65 70 66 71 if (!fMatcher.Match(data)) 67 72 return; //-----There wasn't an error. We're just not supposed to do anything 68 73 69 74 switch (fDoWhat) { 70 75 case Z_MOVE_TO: 71 76 { … … 95 100 default: 96 101 fprintf(stderr,"Unknown do_what: 0x%04x!\n", fDoWhat); 97 102 } 98 103 99 104 return; 100 105 } 101 106 … … 123 128 sprintf(buffer + strlen(buffer), " against \"%s\"", reg); 124 129 125 130 return B_OK;*/ 126 return "Rule filter";131 return B_TRANSLATE("Rule filter"); 127 132 } 128 133 129 134 -
src/add-ons/mail_daemon/inbound_filters/spam_filter/SpamFilter.rdef
1 /* 2 * SpamFilter.rdef 3 */ 4 5 resource app_signature "application/x-vnd.Haiku-SpamFilter"; 6 7 resource app_version { 8 major = 1, 9 middle = 0, 10 minor = 0, 11 variety = 0, 12 internal = 0, 13 short_info = "1.0.0", 14 long_info = "Haiku SpamFilter mail_daemon add-on." 15 }; -
src/add-ons/mail_daemon/inbound_filters/spam_filter/Jamfile
6 6 7 7 SubDirHdrs [ FDirName $(HAIKU_TOP) headers os add-ons mail_daemon ] ; 8 8 9 AddResources SpamFilter : SpamFilter.rdef ; 10 9 11 Addon SpamFilter : 10 12 SpamFilterConfig.cpp 11 13 SpamFilter.cpp 12 14 : 13 be libmail.so $( TARGET_LIBSUPC++)15 be libmail.so $(HAIKU_LOCALE_LIBS) $(TARGET_LIBSUPC++) 14 16 ; 17 18 DoCatalogs SpamFilter 19 : 20 x-vnd.Haiku-SpamFilter 21 : 22 SpamFilter.cpp 23 SpamFilterConfig.cpp 24 ; -
src/add-ons/mail_daemon/inbound_filters/spam_filter/SpamFilter.cpp
113 113 */ 114 114 115 115 #include <Beep.h> 116 #include <Catalog.h> 116 117 #include <fs_attr.h> 117 118 #include <Messenger.h> 118 119 #include <Node.h> … … 127 128 128 129 #include "SpamFilter.h" 129 130 131 132 #undef B_TRANSLATE_CONTEXT 133 #define B_TRANSLATE_CONTEXT "SpamFilter" 134 135 130 136 // The names match the ones set up by spamdbm for sound effects. 131 137 static const char *kAGMSBayesBeepGenuineName = "SpamFilter-Genuine"; 132 138 static const char *kAGMSBayesBeepSpamName = "SpamFilter-Spam"; … … 225 231 float spamRatio; 226 232 if (_GetSpamRatio(stringBuffer, dataSize, spamRatio) != B_OK) 227 233 return B_ERROR; 228 234 229 235 // If we are auto-training, feed back the message to the server as a 230 236 // training example (don't train if it is uncertain). 231 237 if (fAutoTraining && (spamRatio >= fSpamCutoffRatio … … 406 412 delete[] buffer; 407 413 return B_ERROR; 408 414 } 409 415 410 416 BString newSubjectString; 411 417 newSubjectString.SetTo("[Spam "); 412 418 char percentageString[30]; … … 426 432 BString 427 433 descriptive_name() 428 434 { 429 return "Spam Filter (AGMS Bayesian)";435 return B_TRANSLATE("Spam Filter (AGMS Bayesian)"); 430 436 } 431 437 432 438 -
src/add-ons/mail_daemon/inbound_filters/spam_filter/SpamFilterConfig.cpp
80 80 81 81 #include <Alert.h> 82 82 #include <Button.h> 83 #include <Catalog.h> 83 84 #include <CheckBox.h> 84 85 #include <Message.h> 85 86 #include <Messenger.h> … … 93 94 #include <MailAddon.h> 94 95 #include <FileConfigView.h> 95 96 97 98 #undef B_TRANSLATE_CONTEXT 99 #define B_TRANSLATE_CONTEXT "SpamFilterConfig" 100 101 96 102 static const char *kServerSignature = "application/x-vnd.agmsmith.spamdbm"; 97 103 98 104 class AGMSBayesianSpamFilterConfig : public BView { … … 179 185 fAddSpamToSubjectCheckBoxPntr = new BCheckBox ( 180 186 tempRect, 181 187 "AddToSubject", 182 "Add spam rating to start of subject",188 B_TRANSLATE("Add spam rating to start of subject"), 183 189 new BMessage (kAddSpamToSubjectPressed)); 184 190 AddChild (fAddSpamToSubjectCheckBoxPntr); 185 191 fAddSpamToSubjectCheckBoxPntr->ResizeToPreferred (); … … 195 201 fNoWordsMeansSpamCheckBoxPntr = new BCheckBox ( 196 202 tempRect, 197 203 "NoWordsMeansSpam", 198 "or empty e-mail",204 B_TRANSLATE("or empty e-mail"), 199 205 new BMessage (kNoWordsMeansSpam)); 200 206 AddChild (fNoWordsMeansSpamCheckBoxPntr); 201 207 fNoWordsMeansSpamCheckBoxPntr->ResizeToPreferred (); … … 210 216 211 217 tempRect.right = fNoWordsMeansSpamCheckBoxPntr->Frame().left - 212 218 be_plain_font->StringWidth ("a"); 213 tempStringPntr = "Spam above:";219 tempStringPntr = B_TRANSLATE("Spam above:"); 214 220 sprintf (numberString, "%06.4f", (double) fSpamCutoffRatio); 215 221 fSpamCutoffRatioTextBoxPntr = new BTextControl ( 216 222 tempRect, … … 229 235 230 236 // Add the box displaying the genuine cutoff ratio, on a line by itself. 231 237 232 tempStringPntr = "Genuine below and uncertain above:";238 tempStringPntr = B_TRANSLATE("Genuine below and uncertain above:"); 233 239 sprintf (numberString, "%08.6f", (double) fGenuineCutoffRatio); 234 240 fGenuineCutoffRatioTextBoxPntr = new BTextControl ( 235 241 tempRect, … … 251 257 fAutoTrainingCheckBoxPntr = new BCheckBox ( 252 258 tempRect, 253 259 "autoTraining", 254 "Learn from all incoming e-mail",260 B_TRANSLATE("Learn from all incoming e-mail"), 255 261 new BMessage (kAutoTrainingPressed)); 256 262 AddChild (fAutoTrainingCheckBoxPntr); 257 263 fAutoTrainingCheckBoxPntr->ResizeToPreferred (); … … 394 400 goto ErrorExit; 395 401 } 396 402 } 397 403 398 404 // Set up the messenger to the database server. 399 405 messengerToServer = 400 406 BMessenger (kServerSignature); … … 415 421 return; // Successful. 416 422 417 423 ErrorExit: 418 (new BAlert ("SpamFilterConfig Error", "Sorry, unable to launch the"419 " spamdbm program to let you edit the server settings.",420 "Close"))->Go ();424 (new BAlert ("SpamFilterConfig Error", B_TRANSLATE("Sorry, unable to " 425 "launch the spamdbm program to let you edit the server settings."), 426 B_TRANSLATE("Close")))->Go (); 421 427 return; 422 428 } 423 429 -
src/add-ons/mail_daemon/outbound_filters/fortune/ConfigView.cpp
57 57 58 58 BString path = archive->FindString("tag_line"); 59 59 if (!archive->HasString("tag_line")) 60 path = "Fortune cookie says:\n\n";60 path = B_TRANSLATE("Fortune cookie says:\n\n"); 61 61 62 62 path.Truncate(path.Length() - 2); 63 63 if (BTextControl *control = (BTextControl *)FindView("tag_line")) -
src/servers/mail/DeskbarView.cpp
541 541 // The New E-mail query 542 542 543 543 if (fNewMessages > 0) { 544 BString string ;544 BString string, numString; 545 545 if (fNewMessages != 1) 546 string << fNewMessages << B_TRANSLATE("new messages");546 string << B_TRANSLATE("%num new messages"); 547 547 else 548 string << fNewMessages << B_TRANSLATE("new message");548 string << B_TRANSLATE("%num new message"); 549 549 550 numString << fNewMessages; 551 string.ReplaceFirst("%num", numString); 552 550 553 _GetNewQueryRef(ref); 551 554 552 555 item = new BMenuItem(navMenu = new BNavMenu(string.String(), -
src/servers/mail/MailDaemon.cpp
96 96 fAutoCheckRunner(NULL) 97 97 { 98 98 fErrorLogWindow = new ErrorLogWindow(BRect(200, 200, 500, 250), 99 "Mail daemon status log", B_TITLED_WINDOW);99 B_TRANSLATE("Mail daemon status log"), B_TITLED_WINDOW); 100 100 fMailStatusWindow = new MailStatusWindow(BRect(40, 400, 360, 400), 101 "Mail Status", fSettingsFile.ShowStatusWindow());101 B_TRANSLATE("Mail Status"), fSettingsFile.ShowStatusWindow()); 102 102 // install MimeTypes, attributes, indices, and the 103 103 // system beep add startup 104 104 MakeMimeTypes(); … … 162 162 fQueries.AddItem(query); 163 163 } 164 164 165 BString string ;165 BString string, numString; 166 166 if (fNewMessages > 0) { 167 167 if (fNewMessages != 1) 168 string << fNewMessages << B_TRANSLATE("new messages.");168 string << B_TRANSLATE("%num new messages."); 169 169 else 170 string << fNewMessages << B_TRANSLATE(" new message."); 170 string << B_TRANSLATE("%num new message."); 171 172 numString << fNewMessages; 173 string.ReplaceFirst("%num", numString); 171 174 } 172 175 else 173 176 string = B_TRANSLATE("No new messages"); … … 518 521 { 519 522 int32 numMessages = msg->FindInt32("num_messages"); 520 523 BString numString; 521 524 522 525 if (numMessages > 1) 523 526 fAlertString << B_TRANSLATE("%num new messages for %name\n"); 524 527 else … … 543 546 break; 544 547 } 545 548 546 BString string ;549 BString string, numString; 547 550 548 551 if (fNewMessages > 0) { 549 552 if (fNewMessages != 1) 550 string << fNewMessages << B_TRANSLATE("new messages.");553 string << B_TRANSLATE("%num new messages."); 551 554 else 552 string << fNewMessages << B_TRANSLATE(" new message."); 555 string << B_TRANSLATE("%num new message."); 556 557 numString << fNewMessages; 558 string.ReplaceFirst("%num", numString); 553 559 } 554 560 else 555 561 string << B_TRANSLATE("No new messages.");