Use ngettext() for plural forms: Closes bgno#722055
This commit is contained in:
parent
3a1eb30f5f
commit
f642be549d
2 changed files with 9 additions and 6 deletions
|
|
@ -211,9 +211,9 @@ public class ConversationFindBar : Gtk.Layout {
|
|||
|
||||
if (matches > 0) {
|
||||
if (!wrapped)
|
||||
content += _("%i matches").printf(matches);
|
||||
content += ngettext("%i match", "%i matches", matches).printf(matches);
|
||||
else
|
||||
content += _("%i matches (wrapped)").printf(matches);
|
||||
content += ngettext("%i match (wrapped)", "%i matches (wrapped)", matches).printf(matches);
|
||||
} else {
|
||||
content += _("not found");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -250,10 +250,12 @@ public class ConversationViewer : Gtk.Box {
|
|||
}
|
||||
|
||||
private void show_multiple_selected(uint selected_count) {
|
||||
if (selected_count == 0)
|
||||
if (selected_count == 0) {
|
||||
show_special_message(_("No conversations selected."));
|
||||
else
|
||||
show_special_message(_("%u conversations selected.").printf(selected_count));
|
||||
} else {
|
||||
show_special_message(ngettext("%u conversation selected.", "%u conversations selected.",
|
||||
selected_count).printf(selected_count));
|
||||
}
|
||||
}
|
||||
|
||||
private void on_folder_selected(Geary.Folder? folder) {
|
||||
|
|
@ -839,7 +841,8 @@ public class ConversationViewer : Gtk.Box {
|
|||
WebKit.DOM.HTMLElement span =
|
||||
first_compressed.first_element_child.first_element_child
|
||||
as WebKit.DOM.HTMLElement;
|
||||
span.set_inner_html(_("%u read messages").printf(compress_count));
|
||||
span.set_inner_html(
|
||||
ngettext("%u read message", "%u read messages", compress_count).printf(compress_count));
|
||||
// We need to set the display to get an accurate offset_height
|
||||
span.set_attribute("style", "display:inline-block;");
|
||||
span.set_attribute("style", "display:inline-block; top:%ipx".printf(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue