mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-23 10:15:41 +00:00
Bug 338167 Localizability issues with recurNthWeek and recurLast in dateFormat.properties r1=ssitter, r2=mvl
This commit is contained in:
parent
4ad990f6ab
commit
da8c237fad
@ -90,9 +90,15 @@ function loadDialog()
|
||||
// Set label to 'second week of the month'
|
||||
// Note that the date here needs to be 0 based to work properly
|
||||
var monthWeekNum = Math.floor((window.startDate.day - 1) / 7) + 1;
|
||||
nthstr = props.GetStringFromName("ordinal.name."+monthWeekNum);
|
||||
var daystr = props.GetStringFromName("day."+(window.startDate.weekday+1)+".name");
|
||||
str = props.formatStringFromName("recurNthWeek", [nthstr, daystr], 2);
|
||||
|
||||
// In order to remain somewhat sane for l10n, turns a number into a word
|
||||
var numWordMap = ["", "first", "second", "third", "fourth", "fifth"];
|
||||
var numDayMap = ["sunday", "monday", "tuesday", "wednesday",
|
||||
"thursday", "friday", "saturday"];
|
||||
|
||||
str = calGetString("dateFormat",
|
||||
"recur." + numWordMap[monthWeekNum] + "." +
|
||||
numDayMap[window.startDate.weekday]);
|
||||
document.getElementById("monthly-nth-week").label = str;
|
||||
|
||||
// Set two values needed to create the real rrule later
|
||||
@ -107,7 +113,7 @@ function loadDialog()
|
||||
var isLastDay = (monthLength == window.startDate.day);
|
||||
document.getElementById("monthly-last-day").hidden = !isLastDay;
|
||||
if (isLastWeek) {
|
||||
str = props.formatStringFromName("recurLast", [daystr], 1);
|
||||
str = calGetString("dateFormat", "recur.last." + numDayMap[window.startDate.weekday]);
|
||||
document.getElementById("monthly-last-week").label = str;
|
||||
}
|
||||
|
||||
|
@ -135,12 +135,56 @@ ordinal.name.4=Fourth
|
||||
ordinal.name.5=Fifth
|
||||
|
||||
# For the recurrence dialog
|
||||
# Will be subsituted with one of ordinal.name.N and one of day.N.name
|
||||
# Second Tuesday of the month
|
||||
recurNthWeek=%1$S %2$S of the month
|
||||
# Will be subsituted with one of day.N.name
|
||||
# Last Tuesday of the month
|
||||
recurLast=Last %1$S of the month
|
||||
#
|
||||
recur.first.sunday = First Sunday of the month
|
||||
recur.second.sunday = Second Sunday of the month
|
||||
recur.third.sunday = Third Sunday of the month
|
||||
recur.fourth.sunday = Fourth Sunday of the month
|
||||
recur.fifth.sunday = Fifth Sunday of the month
|
||||
recur.last.sunday = Last Sunday of the month
|
||||
|
||||
recur.first.monday = First Monday of the month
|
||||
recur.second.monday = Second Monday of the month
|
||||
recur.third.monday = Third Monday of the month
|
||||
recur.fourth.monday = Fourth Monday of the month
|
||||
recur.fifth.monday = Fifth Monday of the month
|
||||
recur.last.monday = Last Monday of the month
|
||||
|
||||
recur.first.tuesday = First Tuesday of the month
|
||||
recur.second.tuesday = Second Tuesday of the month
|
||||
recur.third.tuesday = Third Tuesday of the month
|
||||
recur.fourth.tuesday = Fourth Tuesday of the month
|
||||
recur.fifth.tuesday = Fifth Tuesday of the month
|
||||
recur.last.tuesday = Last Tuesday of the month
|
||||
|
||||
recur.first.wednesday = First Wednesday of the month
|
||||
recur.second.wednesday = Second Wednesday of the month
|
||||
recur.third.wednesday = Third Wednesday of the month
|
||||
recur.fourth.wednesday = Fourth Wednesday of the month
|
||||
recur.fifth.wednesday = Fifth Wednesday of the month
|
||||
recur.last.wednesday = Last Wednesday of the month
|
||||
|
||||
recur.first.thursday = First Thursday of the month
|
||||
recur.second.thursday = Second Thursday of the month
|
||||
recur.third.thursday = Third Thursday of the month
|
||||
recur.fourth.thursday = Fourth Thursday of the month
|
||||
recur.fifth.thursday = Fifth Thursday of the month
|
||||
recur.last.thursday = Last Thursday of the month
|
||||
|
||||
recur.first.friday = First Friday of the month
|
||||
recur.second.friday = Second Friday of the month
|
||||
recur.third.friday = Third Friday of the month
|
||||
recur.fourth.friday = Fourth Friday of the month
|
||||
recur.fifth.friday = Fifth Friday of the month
|
||||
recur.last.friday = Last Friday of the month
|
||||
|
||||
recur.first.saturday = First Saturday of the month
|
||||
recur.second.saturday = Second Saturday of the month
|
||||
recur.third.saturday = Third Saturday of the month
|
||||
recur.fourth.saturday = Fourth Saturday of the month
|
||||
recur.fifth.saturday = Fifth Saturday of the month
|
||||
recur.last.saturday = Last Saturday of the month
|
||||
|
||||
# Will be subsituted with day and one of ordinal.suffix.N
|
||||
# 15th day of the month
|
||||
recurNthDay=%1$S%2$S day of the month
|
||||
|
Loading…
Reference in New Issue
Block a user