summaryrefslogtreecommitdiff
path: root/library/WT/I18N.php
diff options
context:
space:
mode:
Diffstat (limited to 'library/WT/I18N.php')
-rw-r--r--library/WT/I18N.php56
1 files changed, 28 insertions, 28 deletions
diff --git a/library/WT/I18N.php b/library/WT/I18N.php
index 1895f1da4d..b5625cb777 100644
--- a/library/WT/I18N.php
+++ b/library/WT/I18N.php
@@ -168,10 +168,10 @@ class WT_I18N {
self::$dir=$TEXT_DIRECTION;
// I18N: This punctuation is used to separate lists of items.
- self::$list_separator=self::translate(', ');
+ self::$list_separator=WT_I18N::translate(', ');
// I18N: This is the name of the MySQL collation that applies to your language. A list is available at http://dev.mysql.com/doc/refman/5.0/en/charset-unicode-sets.html
- self::$collation=self::translate('utf8_unicode_ci');
+ self::$collation=WT_I18N::translate('utf8_unicode_ci');
return $locale;
}
@@ -255,11 +255,11 @@ class WT_I18N {
static public function percentage($n, $precision=0) {
return
/* I18N: This is a percentage, such as “32.5%”. “%s” is the number, “%%” is the percent symbol. Some languages require a (non-breaking) space between the two, or a different symbol. */
- self::translate('%s%%', self::number($n*100.0, $precision));
+ WT_I18N::translate('%s%%', self::number($n*100.0, $precision));
}
- // echo self::translate('Hello World!');
- // echo self::translate('The %s sat on the mat', 'cat');
+ // echo WT_I18N::translate('Hello World!');
+ // echo WT_I18N::translate('The %s sat on the mat', 'cat');
static public function translate(/* var_args */) {
$args=func_get_args();
if (WT_DEBUG_LANG) {
@@ -271,8 +271,8 @@ class WT_I18N {
}
// Context sensitive version of translate.
- // echo self::translate_c('NOMINATIVE', 'January');
- // echo self::translate_c('GENITIVE', 'January');
+ // echo WT_I18N::translate_c('NOMINATIVE', 'January');
+ // echo WT_I18N::translate_c('GENITIVE', 'January');
static public function translate_c(/* var_args */) {
$args=func_get_args();
if (WT_DEBUG_LANG) {
@@ -322,13 +322,13 @@ class WT_I18N {
switch ($string) {
case 'STILLBORN':
// I18N: Description of an individual’s age at an event. e.g Died 14 Jan 1900 (stillborn)
- return self::translate('(stillborn)');
+ return WT_I18N::translate('(stillborn)');
case 'INFANT':
// I18N: Description of an individual’s age at an event. e.g Died 14 Jan 1900 (in infancy)
- return self::translate('(in infancy)');
+ return WT_I18N::translate('(in infancy)');
case 'CHILD':
// I18N: Description of an individual’s age at an event. e.g Died 14 Jan 1900 (in childhood)
- return self::translate('(in childhood)');
+ return WT_I18N::translate('(in childhood)');
}
$age=array();
if (preg_match('/(\d+)y/', $string, $match)) {
@@ -357,17 +357,17 @@ class WT_I18N {
if ($age) {
if (!substr_compare($string, '<', 0, 1)) {
// I18N: Description of an individual’s age at an event. e.g Died 14 Jan 1900 (aged less than 21 years)
- return self::translate('(aged less than %s)', $age);
+ return WT_I18N::translate('(aged less than %s)', $age);
} elseif (!substr_compare($string, '>', 0, 1)) {
// I18N: Description of an individual’s age at an event. e.g Died 14 Jan 1900 (aged more than 21 years)
- return self::translate('(aged more than %s)', $age);
+ return WT_I18N::translate('(aged more than %s)', $age);
} else {
// I18N: Description of an individual’s age at an event. e.g Died 14 Jan 1900 (aged 43 years)
- return self::translate('(aged %s)', $age);
+ return WT_I18N::translate('(aged %s)', $age);
}
} else {
// Not a valid string?
- return self::translate('(aged %s)', $string);
+ return WT_I18N::translate('(aged %s)', $string);
}
}
@@ -413,11 +413,11 @@ class WT_I18N {
foreach ($lengths as $length) {
$length_menu.=
'<option value="'.$length.'">'.
- ($length==-1 ? /* I18N: listbox option, e.g. “10,25,50,100,all” */ self::translate('All') : self::number($length)).
+ ($length==-1 ? /* I18N: listbox option, e.g. “10,25,50,100,all” */ WT_I18N::translate('All') : self::number($length)).
'</option>';
}
$length_menu='<select>'.$length_menu.'</select>';
- $length_menu=/* I18N: Display %s [records per page], %s is a placeholder for listbox containing numeric options */ self::translate('Display %s', $length_menu);
+ $length_menu=/* I18N: Display %s [records per page], %s is a placeholder for listbox containing numeric options */ WT_I18N::translate('Display %s', $length_menu);
// Which symbol is used for separating numbers into groups
$symbols = Zend_Locale_Data::getList(WT_LOCALE, 'symbols');
@@ -461,23 +461,23 @@ class WT_I18N {
return
'"oLanguage": {'.
' "oPaginate": {'.
- ' "sFirst": "'./* I18N: button label, first page */ self::translate('first').'",'.
- ' "sLast": "'./* I18N: button label, last page */ self::translate('last').'",'.
- ' "sNext": "'./* I18N: button label, next page */ self::translate('next').'",'.
- ' "sPrevious": "'./* I18N: button label, previous page */ self::translate('previous').'"'.
+ ' "sFirst": "'./* I18N: button label, first page */ WT_I18N::translate('first').'",'.
+ ' "sLast": "'./* I18N: button label, last page */ WT_I18N::translate('last').'",'.
+ ' "sNext": "'./* I18N: button label, next page */ WT_I18N::translate('next').'",'.
+ ' "sPrevious": "'./* I18N: button label, previous page */ WT_I18N::translate('previous').'"'.
' },'.
- ' "sEmptyTable": "'.self::translate('No records to display').'",'.
- ' "sInfo": "'./* I18N: %s are placeholders for numbers */ self::translate('Showing %1$s to %2$s of %3$s', '_START_', '_END_', '_TOTAL_').'",'.
- ' "sInfoEmpty": "'.self::translate('Showing %1$s to %2$s of %3$s', 0, 0, 0).'",'.
- ' "sInfoFiltered": "'./* I18N: %s is a placeholder for a number */ self::translate('(filtered from %s total entries)', '_MAX_').'",'.
+ ' "sEmptyTable": "'.WT_I18N::translate('No records to display').'",'.
+ ' "sInfo": "'./* I18N: %s are placeholders for numbers */ WT_I18N::translate('Showing %1$s to %2$s of %3$s', '_START_', '_END_', '_TOTAL_').'",'.
+ ' "sInfoEmpty": "'.WT_I18N::translate('Showing %1$s to %2$s of %3$s', 0, 0, 0).'",'.
+ ' "sInfoFiltered": "'./* I18N: %s is a placeholder for a number */ WT_I18N::translate('(filtered from %s total entries)', '_MAX_').'",'.
' "sInfoPostfix": "",'.
' "sInfoThousands": "'.$symbols['group'].'",'.
' "sLengthMenu": "'.addslashes($length_menu).'",'.
- ' "sLoadingRecords": "'.self::translate('Loading...').'",'.
- ' "sProcessing": "'.self::translate('Loading...').'",'.
- ' "sSearch": "'.self::translate('Filter').'",'.
+ ' "sLoadingRecords": "'.WT_I18N::translate('Loading...').'",'.
+ ' "sProcessing": "'.WT_I18N::translate('Loading...').'",'.
+ ' "sSearch": "'.WT_I18N::translate('Filter').'",'.
' "sUrl": "",'.
- ' "sZeroRecords": "'.self::translate('No records to display').'"'.
+ ' "sZeroRecords": "'.WT_I18N::translate('No records to display').'"'.
'}'.
$callback;
}