| 1 | Index: wp-includes/l10n.php |
|---|
| 2 | =================================================================== |
|---|
| 3 | --- wp-includes/l10n.php (revision 20381) |
|---|
| 4 | +++ wp-includes/l10n.php (working copy) |
|---|
| 5 | @@ -274,8 +274,8 @@ |
|---|
| 6 | * @param string $plural Plural form to be i18ned |
|---|
| 7 | * @return array array($singular, $plural) |
|---|
| 8 | */ |
|---|
| 9 | -function _n_noop( $singular, $plural ) { |
|---|
| 10 | - return array( 0 => $singular, 1 => $plural, 'singular' => $singular, 'plural' => $plural, 'context' => null ); |
|---|
| 11 | +function _n_noop( $singular, $plural, $domain = null ) { |
|---|
| 12 | + return array( 0 => $singular, 1 => $plural, 'singular' => $singular, 'plural' => $plural, 'context' => null, 'domain' => $domain ); |
|---|
| 13 | } |
|---|
| 14 | |
|---|
| 15 | /** |
|---|
| 16 | @@ -283,8 +283,8 @@ |
|---|
| 17 | * |
|---|
| 18 | * @see _n_noop() |
|---|
| 19 | */ |
|---|
| 20 | -function _nx_noop( $singular, $plural, $context ) { |
|---|
| 21 | - return array( 0 => $singular, 1 => $plural, 2 => $context, 'singular' => $singular, 'plural' => $plural, 'context' => $context ); |
|---|
| 22 | +function _nx_noop( $singular, $plural, $context, $domain = null ) { |
|---|
| 23 | + return array( 0 => $singular, 1 => $plural, 2 => $context, 'singular' => $singular, 'plural' => $plural, 'context' => $context, 'domain' => $domain ); |
|---|
| 24 | } |
|---|
| 25 | |
|---|
| 26 | /** |
|---|
| 27 | @@ -296,6 +296,9 @@ |
|---|
| 28 | * @param string $domain Optional. The domain identifier the text should be retrieved in |
|---|
| 29 | */ |
|---|
| 30 | function translate_nooped_plural( $nooped_plural, $count, $domain = 'default' ) { |
|---|
| 31 | + if ( $nooped_plural['domain'] ) |
|---|
| 32 | + $domain = $nooped_plural['domain']; |
|---|
| 33 | + |
|---|
| 34 | if ( $nooped_plural['context'] ) |
|---|
| 35 | return _nx( $nooped_plural['singular'], $nooped_plural['plural'], $count, $nooped_plural['context'], $domain ); |
|---|
| 36 | else |
|---|