Update translator documentation.
i18n/L10n fixes. Superfluous whitespace removed.
This commit is contained in:
parent
1a91f85438
commit
5b660bd3c6
|
@ -63,21 +63,24 @@ class AutoSandboxPlugin extends Plugin
|
|||
'author' => 'Sean Carmody',
|
||||
'homepage' => 'http://status.net/wiki/Plugin:AutoSandbox',
|
||||
'rawdescription' =>
|
||||
// TRANS: Plugin description.
|
||||
_m('Automatically sandboxes newly registered members.'));
|
||||
return true;
|
||||
}
|
||||
|
||||
function onStartRegistrationFormData($action)
|
||||
{
|
||||
// TRANS: User instructions after registration.
|
||||
$instr = _m('Note you will initially be "sandboxed" so your posts will not appear in the public timeline.');
|
||||
|
||||
if (isset($this->contact)) {
|
||||
$contactuser = User::staticGet('nickname', $this->contact);
|
||||
if (!empty($contactuser)) {
|
||||
$contactlink = "@<a href=\"$contactuser->uri\">$contactuser->nickname</a>";
|
||||
// TRANS: $contactlink is a clickable e-mailaddress.
|
||||
$instr = _m("Note you will initially be \"sandboxed\" so your posts will not appear in the public timeline. ".
|
||||
'Send a message to $contactlink to speed up the unsandboxing process.');
|
||||
// TRANS: User instructions after registration.
|
||||
// TRANS: %s is a clickable e-mailaddress.
|
||||
$instr = sprintf(_m('Note you will initially be "sandboxed" so your posts will not appear in the public timeline. '.
|
||||
'Send a message to %s to speed up the unsandboxing process.'),$contactlink);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -43,7 +43,8 @@ class BitlyUrlPlugin extends UrlShortenerPlugin
|
|||
function onInitializePlugin(){
|
||||
parent::onInitializePlugin();
|
||||
if(!isset($this->serviceUrl)){
|
||||
throw new Exception(_m("You must specify a serviceUrl for bit.ly shortening."));
|
||||
// TRANS: Exception thrown when bit.ly URL shortening plugin was configured incorrectly.
|
||||
throw new Exception(_m('You must specify a serviceUrl for bit.ly URL shortening.'));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -170,6 +171,7 @@ class BitlyUrlPlugin extends UrlShortenerPlugin
|
|||
'author' => 'Craig Andrews, Brion Vibber',
|
||||
'homepage' => 'http://status.net/wiki/Plugin:BitlyUrl',
|
||||
'rawdescription' =>
|
||||
// TRANS: Plugin description. %1$s is the URL shortening service base URL (for example "bit.ly").
|
||||
sprintf(_m('Uses <a href="http://%1$s/">%1$s</a> URL-shortener service.'),
|
||||
$this->shortenerName));
|
||||
|
||||
|
@ -211,8 +213,10 @@ class BitlyUrlPlugin extends UrlShortenerPlugin
|
|||
$action_name = $nav->action->trimmed('action');
|
||||
|
||||
$nav->out->menuItem(common_local_url('bitlyadminpanel'),
|
||||
// TRANS: Menu item in administration menus for bit.ly URL shortening settings.
|
||||
_m('bit.ly'),
|
||||
_m('bit.ly URL shortening'),
|
||||
// TRANS: Title for menu item in administration menus for bit.ly URL shortening settings.
|
||||
_m('bit.ly URL shortening.'),
|
||||
$action_name == 'bitlyadminpanel',
|
||||
'nav_bitly_admin_panel');
|
||||
}
|
||||
|
|
|
@ -40,7 +40,6 @@ if (!defined('STATUSNET')) {
|
|||
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
|
||||
* @link http://status.net/
|
||||
*/
|
||||
|
||||
class BitlyadminpanelAction extends AdminPanelAction
|
||||
{
|
||||
/**
|
||||
|
@ -48,9 +47,9 @@ class BitlyadminpanelAction extends AdminPanelAction
|
|||
*
|
||||
* @return string page title
|
||||
*/
|
||||
|
||||
function title()
|
||||
{
|
||||
// TRANS: Title of administration panel.
|
||||
return _m('bit.ly URL shortening');
|
||||
}
|
||||
|
||||
|
@ -59,9 +58,10 @@ class BitlyadminpanelAction extends AdminPanelAction
|
|||
*
|
||||
* @return string instructions
|
||||
*/
|
||||
|
||||
function getInstructions()
|
||||
{
|
||||
// TRANS: Instructions for administration panel.
|
||||
// TRANS: This message contains Markdown links in the form [decsription](link).
|
||||
return _m('URL shortening with bit.ly requires ' .
|
||||
'[a bit.ly account and API key](http://bit.ly/a/your_api_key). ' .
|
||||
'This verifies that this is an authorized account, and ' .
|
||||
|
@ -73,7 +73,6 @@ class BitlyadminpanelAction extends AdminPanelAction
|
|||
*
|
||||
* @return void
|
||||
*/
|
||||
|
||||
function showForm()
|
||||
{
|
||||
$form = new BitlyAdminPanelForm($this);
|
||||
|
@ -86,7 +85,6 @@ class BitlyadminpanelAction extends AdminPanelAction
|
|||
*
|
||||
* @return void
|
||||
*/
|
||||
|
||||
function saveSettings()
|
||||
{
|
||||
static $settings = array(
|
||||
|
@ -129,13 +127,15 @@ class BitlyadminpanelAction extends AdminPanelAction
|
|||
|
||||
if (mb_strlen($values['bitly']['default_apikey']) > 255) {
|
||||
$this->clientError(
|
||||
_m("Invalid login. Max length is 255 characters.")
|
||||
// TRANS: Client error displayed when using too long a key.
|
||||
_m('Invalid login. Maximum length is 255 characters.')
|
||||
);
|
||||
}
|
||||
|
||||
if (mb_strlen($values['bitly']['default_apikey']) > 255) {
|
||||
$this->clientError(
|
||||
_m("Invalid API key. Max length is 255 characters.")
|
||||
// TRANS: Client error displayed when using too long a key.
|
||||
_m('Invalid API key. Maximum length is 255 characters.')
|
||||
);
|
||||
}
|
||||
}
|
||||
|
@ -148,7 +148,6 @@ class BitlyAdminPanelForm extends AdminForm
|
|||
*
|
||||
* @return int ID of the form
|
||||
*/
|
||||
|
||||
function id()
|
||||
{
|
||||
return 'bitlyadminpanel';
|
||||
|
@ -159,7 +158,6 @@ class BitlyAdminPanelForm extends AdminForm
|
|||
*
|
||||
* @return string class of the form
|
||||
*/
|
||||
|
||||
function formClass()
|
||||
{
|
||||
return 'form_settings';
|
||||
|
@ -170,7 +168,6 @@ class BitlyAdminPanelForm extends AdminForm
|
|||
*
|
||||
* @return string URL of the action
|
||||
*/
|
||||
|
||||
function action()
|
||||
{
|
||||
return common_local_url('bitlyadminpanel');
|
||||
|
@ -181,14 +178,14 @@ class BitlyAdminPanelForm extends AdminForm
|
|||
*
|
||||
* @return void
|
||||
*/
|
||||
|
||||
function formData()
|
||||
{
|
||||
$this->out->elementStart(
|
||||
'fieldset',
|
||||
array('id' => 'settings_bitly')
|
||||
);
|
||||
$this->out->element('legend', null, _m('Credentials'));
|
||||
// TRANS: Fieldset legend in administration panel for bit.ly username and API key.
|
||||
$this->out->element('legend', null, _m('LEGEND','Credentials'));
|
||||
|
||||
// Do we have global defaults to fall back on?
|
||||
$login = $apiKey = false;
|
||||
|
@ -196,9 +193,11 @@ class BitlyAdminPanelForm extends AdminForm
|
|||
$haveGlobalDefaults = ($login && $apiKey);
|
||||
if ($login && $apiKey) {
|
||||
$this->out->element('p', 'form_guide',
|
||||
// TRANS: Form guide in administration panel for bit.ly URL shortening.
|
||||
_m('Leave these empty to use global default credentials.'));
|
||||
} else {
|
||||
$this->out->element('p', 'form_guide',
|
||||
// TRANS: Form guide in administration panel for bit.ly URL shortening.
|
||||
_m('If you leave these empty, bit.ly will be unavailable to users.'));
|
||||
}
|
||||
$this->out->elementStart('ul', 'form_data');
|
||||
|
@ -206,6 +205,7 @@ class BitlyAdminPanelForm extends AdminForm
|
|||
$this->li();
|
||||
$this->input(
|
||||
'default_login',
|
||||
// TRANS: Field label in administration panel for bit.ly URL shortening.
|
||||
_m('Login name'),
|
||||
null,
|
||||
'bitly'
|
||||
|
@ -215,6 +215,7 @@ class BitlyAdminPanelForm extends AdminForm
|
|||
$this->li();
|
||||
$this->input(
|
||||
'default_apikey',
|
||||
// TRANS: Field label in administration panel for bit.ly URL shortening.
|
||||
_m('API key'),
|
||||
null,
|
||||
'bitly'
|
||||
|
@ -230,13 +231,14 @@ class BitlyAdminPanelForm extends AdminForm
|
|||
*
|
||||
* @return void
|
||||
*/
|
||||
|
||||
function formActions()
|
||||
{
|
||||
$this->out->submit('submit',
|
||||
// TRANS: Button text to save setting in administration panel for bit.ly URL shortening.
|
||||
_m('BUTTON','Save'),
|
||||
'submit',
|
||||
null,
|
||||
// TRANS: Button title to save setting in administration panel for bit.ly URL shortening.
|
||||
_m('Save bit.ly settings'));
|
||||
}
|
||||
}
|
||||
|
|
|
@ -126,7 +126,7 @@ class BlacklistPlugin extends Plugin
|
|||
} else if (is_string($config)) {
|
||||
return explode("\r\n", $config);
|
||||
} else {
|
||||
throw new Exception("Unknown data type for config $section + $setting");
|
||||
throw new Exception(sprintf(_m('Unknown data type for config %1$s + %2$s.'),$section, $setting));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -340,6 +340,7 @@ class BlacklistPlugin extends Plugin
|
|||
'homepage' =>
|
||||
'http://status.net/wiki/Plugin:Blacklist',
|
||||
'description' =>
|
||||
// TRANS: Plugin description.
|
||||
_m('Keeps a blacklist of forbidden nickname '.
|
||||
'and URL patterns.'));
|
||||
return true;
|
||||
|
@ -380,7 +381,7 @@ class BlacklistPlugin extends Plugin
|
|||
// TRANS: Menu item in admin panel.
|
||||
_m('MENU','Blacklist'),
|
||||
// TRANS: Tooltip for menu item in admin panel.
|
||||
_m('TOOLTIP','Blacklist configuration'),
|
||||
_m('TOOLTIP','Blacklist configuration.'),
|
||||
$action_name == 'blacklistadminpanel',
|
||||
'nav_blacklist_admin_panel');
|
||||
}
|
||||
|
@ -406,7 +407,7 @@ class BlacklistPlugin extends Plugin
|
|||
$action->elementStart('li');
|
||||
$this->checkboxAndText($action,
|
||||
'blacklistnickname',
|
||||
// TRANS: Checkbox with text label in the delete user form.
|
||||
// TRANS: Checkbox label in the blacklist user form.
|
||||
_m('Add this nickname pattern to blacklist'),
|
||||
'blacklistnicknamepattern',
|
||||
$this->patternizeNickname($user->nickname));
|
||||
|
@ -416,7 +417,7 @@ class BlacklistPlugin extends Plugin
|
|||
$action->elementStart('li');
|
||||
$this->checkboxAndText($action,
|
||||
'blacklisthomepage',
|
||||
// TRANS: Checkbox with text label in the delete user form.
|
||||
// TRANS: Checkbox label in the blacklist user form.
|
||||
_m('Add this homepage pattern to blacklist'),
|
||||
'blacklisthomepagepattern',
|
||||
$this->patternizeHomepage($profile->homepage));
|
||||
|
@ -496,7 +497,7 @@ class BlacklistPlugin extends Plugin
|
|||
if (!empty($homepage)) {
|
||||
if (!$this->_checkUrl($homepage)) {
|
||||
// TRANS: Exception thrown trying to post a notice while having set a blocked homepage URL. %s is the blocked URL.
|
||||
$msg = sprintf(_m("Users from \"%s\" blocked."),
|
||||
$msg = sprintf(_m("Users from \"%s\" are blocked."),
|
||||
$homepage);
|
||||
throw new ClientException($msg);
|
||||
}
|
||||
|
@ -507,7 +508,7 @@ class BlacklistPlugin extends Plugin
|
|||
if (!empty($nickname)) {
|
||||
if (!$this->_checkNickname($nickname)) {
|
||||
// TRANS: Exception thrown trying to post a notice while having a blocked nickname. %s is the blocked nickname.
|
||||
$msg = sprintf(_m("Posts from nickname \"%s\" disallowed."),
|
||||
$msg = sprintf(_m("Notices from nickname \"%s\" disallowed."),
|
||||
$nickname);
|
||||
throw new ClientException($msg);
|
||||
}
|
||||
|
@ -531,7 +532,7 @@ class BlacklistPlugin extends Plugin
|
|||
|
||||
if (!$this->_checkUrl($url)) {
|
||||
// TRANS: Client exception thrown trying to subscribe to a person with a blocked homepage or site URL. %s is the blocked URL.
|
||||
$msg = sprintf(_m("Users from \"%s\" blocked."),
|
||||
$msg = sprintf(_m("Users from \"%s\" are blocked."),
|
||||
$url);
|
||||
throw new ClientException($msg);
|
||||
}
|
||||
|
@ -542,7 +543,7 @@ class BlacklistPlugin extends Plugin
|
|||
if (!empty($nickname)) {
|
||||
if (!$this->_checkNickname($nickname)) {
|
||||
// TRANS: Client exception thrown trying to subscribe to a person with a blocked nickname. %s is the blocked nickname.
|
||||
$msg = sprintf(_m("Can't subscribe to nickname \"%s\"."),
|
||||
$msg = sprintf(_m("Cannot subscribe to nickname \"%s\"."),
|
||||
$nickname);
|
||||
throw new ClientException($msg);
|
||||
}
|
||||
|
|
|
@ -49,7 +49,8 @@ class BlacklistadminpanelAction extends AdminPanelAction
|
|||
*/
|
||||
function title()
|
||||
{
|
||||
return _m('Blacklist');
|
||||
// TRANS: Title of blacklist plugin administration panel.
|
||||
return _m('TITLE','Blacklist');
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -59,6 +60,7 @@ class BlacklistadminpanelAction extends AdminPanelAction
|
|||
*/
|
||||
function getInstructions()
|
||||
{
|
||||
// TRANS: Instructions for blacklist plugin administration panel.
|
||||
return _m('Blacklisted URLs and nicknames');
|
||||
}
|
||||
|
||||
|
@ -171,17 +173,21 @@ class BlacklistAdminPanelForm extends Form
|
|||
|
||||
$nickPatterns = Nickname_blacklist::getPatterns();
|
||||
|
||||
// TRANS: Field label in blacklist plugin administration panel.
|
||||
$this->out->textarea('blacklist-nicknames', _m('Nicknames'),
|
||||
implode("\r\n", $nickPatterns),
|
||||
_m('Patterns of nicknames to block, one per line'));
|
||||
// TRANS: Field title in blacklist plugin administration panel.
|
||||
_m('Patterns of nicknames to block, one per line.'));
|
||||
$this->out->elementEnd('li');
|
||||
|
||||
$urlPatterns = Homepage_blacklist::getPatterns();
|
||||
|
||||
$this->out->elementStart('li');
|
||||
// TRANS: Field label in blacklist plugin administration panel.
|
||||
$this->out->textarea('blacklist-urls', _m('URLs'),
|
||||
implode("\r\n", $urlPatterns),
|
||||
_m('Patterns of URLs to block, one per line'));
|
||||
// TRANS: Field title in blacklist plugin administration panel.
|
||||
_m('Patterns of URLs to block, one per line.'));
|
||||
$this->out->elementEnd('li');
|
||||
|
||||
$this->out->elementEnd('ul');
|
||||
|
@ -195,9 +201,11 @@ class BlacklistAdminPanelForm extends Form
|
|||
function formActions()
|
||||
{
|
||||
$this->out->submit('submit',
|
||||
_m('Save'),
|
||||
// TRANS: Button text in blacklist plugin administration panel to save settings.
|
||||
_m('BUTTON','Save'),
|
||||
'submit',
|
||||
null,
|
||||
_m('Save site settings'));
|
||||
// TRANS: Button title in blacklist plugin administration panel to save settings.
|
||||
_m('Save site settings.'));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user