git.gnu.io has moved to IP address 209.51.188.249 -- please double check where you are logging in.

Commit 0df11102 authored by Siebrand Mazeland's avatar Siebrand Mazeland

Update translator documentation.

L10n/i18n fixes.
Update whitespace.
parent 940af215
......@@ -48,7 +48,6 @@ define('NOTICE_TITLE_PLUGIN_VERSION', '0.1');
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html AGPL 3.0
* @link http://status.net/
*/
class NoticeTitlePlugin extends Plugin
{
......@@ -67,7 +66,6 @@ class NoticeTitlePlugin extends Plugin
*
* @return boolean hook value; true means continue processing, false means stop.
*/
function onCheckSchema()
{
$schema = Schema::get();
......@@ -95,7 +93,6 @@ class NoticeTitlePlugin extends Plugin
*
* @return boolean hook value; true means continue processing, false means stop.
*/
function onAutoload($cls)
{
$dir = dirname(__FILE__);
......@@ -119,7 +116,6 @@ class NoticeTitlePlugin extends Plugin
*
* @return boolean hook value
*/
function onPluginVersion(&$versions)
{
$url = 'http://status.net/wiki/Plugin:NoticeTitle';
......@@ -129,6 +125,7 @@ class NoticeTitlePlugin extends Plugin
'author' => 'Evan Prodromou',
'homepage' => $url,
'rawdescription' =>
// TRANS: Plugin description.
_m('Adds optional titles to notices.'));
return true;
}
......@@ -140,7 +137,6 @@ class NoticeTitlePlugin extends Plugin
*
* @return boolean hook value
*/
function onStartShowNoticeFormData($form)
{
if ($this->isAllowedRichEdit()) {
......@@ -166,14 +162,17 @@ class NoticeTitlePlugin extends Plugin
*
* @return boolean hook value
*/
function onStartNoticeSaveWeb($action, &$authorId, &$text, &$options)
{
$title = $action->trimmed('notice_title');
if (!empty($title) && $this->isAllowedRichEdit()) {
if (mb_strlen($title) > Notice_title::MAXCHARS) {
throw new Exception(sprintf(_m("The notice title is too long (max %d characters).",
Notice_title::MAXCHARS)));
// TRANS: Exception thrown when a notice title is too long.
// TRANS: %d is the maximum number of characters allowed in a title (used for plural).
throw new Exception(sprintf(_m('The notice title is too long (maximum %d character).',
'The notice title is too long (maximum %d characters).',
Notice_title::MAXCHARS),
Notice_title::MAXCHARS));
}
}
return true;
......@@ -187,7 +186,6 @@ class NoticeTitlePlugin extends Plugin
*
* @return boolean hook value
*/
function onEndNoticeSaveWeb($action, $notice)
{
if (!empty($notice)) {
......@@ -215,7 +213,6 @@ class NoticeTitlePlugin extends Plugin
*
* @return boolean hook value
*/
function onStartShowNoticeItem($nli)
{
$title = Notice_title::fromNotice($nli->notice);
......@@ -237,7 +234,6 @@ class NoticeTitlePlugin extends Plugin
*
* @return boolean hook value
*/
function onEndRssEntryArray($notice, &$entry)
{
$title = Notice_title::fromNotice($notice);
......@@ -258,7 +254,6 @@ class NoticeTitlePlugin extends Plugin
*
* @return boolean hook value
*/
function onEndNoticeAsActivity($notice, &$activity)
{
$title = Notice_title::fromNotice($notice);
......@@ -282,7 +277,6 @@ class NoticeTitlePlugin extends Plugin
*
* @return boolean hook value
*/
function onNoticeDeleteRelated($notice)
{
$nt = Notice_title::staticGet('notice_id', $notice->id);
......@@ -301,7 +295,6 @@ class NoticeTitlePlugin extends Plugin
*
* @return boolean hook value
*/
function onStartShowHeadTitle($action)
{
$actionName = $action->trimmed('action');
......@@ -327,7 +320,6 @@ class NoticeTitlePlugin extends Plugin
*
* @return boolean hook value
*/
function onStartShowPageTitle($action)
{
$actionName = $action->trimmed('action');
......@@ -348,7 +340,7 @@ class NoticeTitlePlugin extends Plugin
* Always true unless the plugin's "restricted" setting is on, in which
* case it's limited to users with the "richedit" role.
*
* @fixme make that more sanely configurable :)
* @todo FIXME: make that more sanely configurable :)
*
* @return boolean
*/
......@@ -361,5 +353,4 @@ class NoticeTitlePlugin extends Plugin
return true;
}
}
}
......@@ -44,7 +44,6 @@ require_once INSTALLDIR . '/classes/Memcached_DataObject.php';
*
* @see DB_DataObject
*/
class Notice_title extends Memcached_DataObject
{
const MAXCHARS = 255;
......@@ -64,7 +63,6 @@ class Notice_title extends Memcached_DataObject
* @return Notice_title object found, or null for no hits
*
*/
function staticGet($k, $v=null)
{
return Memcached_DataObject::staticGet('Notice_title', $k, $v);
......@@ -78,7 +76,6 @@ class Notice_title extends Memcached_DataObject
*
* @return array array of column definitions
*/
function table()
{
return array('notice_id' => DB_DATAOBJECT_INT + DB_DATAOBJECT_NOTNULL,
......@@ -90,7 +87,6 @@ class Notice_title extends Memcached_DataObject
*
* @return array list of key field names
*/
function keys()
{
return array_keys($this->keyTypes());
......@@ -101,7 +97,6 @@ class Notice_title extends Memcached_DataObject
*
* @return array list mapping field names to key types
*/
function keyTypes()
{
return array('notice_id' => 'K');
......@@ -112,7 +107,6 @@ class Notice_title extends Memcached_DataObject
*
* @return array magic three-false array that stops auto-incrementing.
*/
function sequenceKey()
{
return array(false, false, false);
......@@ -125,7 +119,6 @@ class Notice_title extends Memcached_DataObject
*
* @return string title of the notice, or null if none
*/
static function fromNotice($notice)
{
$nt = Notice_title::staticGet('notice_id', $notice->id);
......
......@@ -56,6 +56,7 @@ class OpenExternalLinkTargetPlugin extends Plugin
'author' => 'Sarven Capadisli',
'homepage' => 'http://status.net/wiki/Plugin:OpenExternalLinkTarget',
'rawdescription' =>
// TRANS: Plugin description.
_m('Opens external links (i.e. with rel=external) on a new window or tab.'));
return true;
}
......
......@@ -135,7 +135,7 @@ class OpenIDPlugin extends Plugin
common_redirect(common_local_url('openidsettings'));
exit(0);
} else if ($action == 'recoverpassword') {
throw new ClientException('Unavailable action');
throw new ClientException('Unavailable action.');
}
}
}
......@@ -215,7 +215,7 @@ class OpenIDPlugin extends Plugin
{
if (common_config('site', 'openidonly') && !common_logged_in()) {
// TRANS: Tooltip for main menu option "Login"
$tooltip = _m('TOOLTIP', 'Login to the site');
$tooltip = _m('TOOLTIP', 'Login to the site.');
$action->menuItem(common_local_url('openidlogin'),
// TRANS: Main menu option when not logged in to log in
_m('MENU', 'Login'),
......@@ -232,7 +232,7 @@ class OpenIDPlugin extends Plugin
'nav_help');
if (!common_config('site', 'private')) {
// TRANS: Tooltip for main menu option "Search"
$tooltip = _m('TOOLTIP', 'Search for people or text');
$tooltip = _m('TOOLTIP', 'Search for people or text.');
$action->menuItem(common_local_url('peoplesearch'),
// TRANS: Main menu option when logged in or when the StatusNet instance is not private
_m('MENU', 'Search'), $tooltip, false, 'nav_search');
......@@ -294,7 +294,7 @@ class OpenIDPlugin extends Plugin
// TRANS: OpenID plugin menu item on site logon page.
_m('MENU', 'OpenID'),
// TRANS: OpenID plugin tooltip for logon menu item.
_m('Login or register with OpenID'),
_m('Login or register with OpenID.'),
$action_name === 'openidlogin');
}
......@@ -330,7 +330,7 @@ class OpenIDPlugin extends Plugin
// TRANS: OpenID plugin menu item on user settings page.
_m('MENU', 'OpenID'),
// TRANS: OpenID plugin tooltip for user settings menu item.
_m('Add or remove OpenIDs'),
_m('Add or remove OpenIDs.'),
$action_name === 'openidsettings');
return true;
......@@ -532,7 +532,8 @@ class OpenIDPlugin extends Plugin
function onEndLoadDoc($title, &$output)
{
if ($title == 'help') {
$menuitem = '* [OpenID](%%doc.openid%%) - what OpenID is and how to use it with this service';
// TRANS: Item on help page. This message contains Markdown links in the form [description](link).
$menuitem = _m('* [OpenID](%%doc.openid%%) - What OpenID is and how to use it with this service.');
$output .= common_markup_to_html($menuitem);
}
......@@ -604,7 +605,7 @@ class OpenIDPlugin extends Plugin
// TRANS: OpenID configuration menu item.
_m('MENU','OpenID'),
// TRANS: Tooltip for OpenID configuration menu item.
_m('OpenID configuration'),
_m('OpenID configuration.'),
$action_name == 'openidadminpanel',
'nav_openid_admin_panel'
);
......@@ -649,7 +650,7 @@ class OpenIDPlugin extends Plugin
'author' => 'Evan Prodromou, Craig Andrews',
'homepage' => 'http://status.net/wiki/Plugin:OpenID',
'rawdescription' =>
// TRANS: OpenID plugin description.
// TRANS: Plugin description.
_m('Use <a href="http://openid.net/">OpenID</a> to login to the site.'));
return true;
}
......@@ -677,7 +678,7 @@ class OpenIDPlugin extends Plugin
{
$action->elementStart('fieldset');
// TRANS: OpenID plugin logon form legend.
$action->element('legend', null, _m('OpenID login'));
$action->element('legend', null, _m('LEGEND','OpenID login'));
$action->elementStart('ul', 'form_data');
$action->elementStart('li');
......@@ -703,7 +704,7 @@ class OpenIDPlugin extends Plugin
$action->input('openid_url', _m('OpenID URL'),
'',
// TRANS: OpenID plugin logon form field instructions.
_m('Your OpenID URL'));
_m('Your OpenID URL.'));
}
$action->elementEnd('li');
$action->elementEnd('ul');
......@@ -760,26 +761,26 @@ class OpenIDPlugin extends Plugin
/**
* Add link in user's XRD file to allow OpenID login.
*
*
* This link in the XRD should let users log in with their
* Webfinger identity to services that support it. See
* http://webfinger.org/login for an example.
*
* @param XRD &$xrd Currently-displaying XRD object
* @param User $user The user that it's for
*
*
* @return boolean hook value (always true)
*/
function onEndXrdActionLinks(&$xrd, $user)
{
$profile = $user->getProfile();
if (!empty($profile)) {
$xrd->links[] = array('rel' => 'http://specs.openid.net/auth/2.0/provider',
'href' => $profile->profileurl);
}
return true;
}
}
......@@ -28,7 +28,6 @@ class User_openid extends Memcached_DataObject
function table()
{
$db = $this->getDatabaseConnection();
$dbtype = $db->phptype; // Database type is stored here. Crazy but true.
......
......@@ -53,5 +53,4 @@ class User_openid_trustroot extends Memcached_DataObject
{
return array('trustroot' => 'K', 'user_id' => 'K');
}
}
......@@ -44,7 +44,6 @@ require_once INSTALLDIR.'/plugins/OpenID/openid.php';
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
* @link http://status.net/
*/
class FinishaddopenidAction extends Action
{
var $msg = null;
......@@ -59,7 +58,6 @@ class FinishaddopenidAction extends Action
*
* @return void
*/
function handle($args)
{
parent::handle($args);
......@@ -78,7 +76,6 @@ class FinishaddopenidAction extends Action
*
* @return void
*/
function tryLogin()
{
$consumer = oid_consumer();
......@@ -92,7 +89,7 @@ class FinishaddopenidAction extends Action
} else if ($response->status == Auth_OpenID_FAILURE) {
// TRANS: OpenID authentication failed; display the error message.
// TRANS: %s is the error message.
$this->message(sprintf(_m('OpenID authentication failed: %s'),
$this->message(sprintf(_m('OpenID authentication failed: %s.'),
$response->message));
} else if ($response->status == Auth_OpenID_SUCCESS) {
......@@ -108,7 +105,8 @@ class FinishaddopenidAction extends Action
// Launchpad teams extension
if (!oid_check_teams($response)) {
$this->message(_m('OpenID authentication aborted: you are not allowed to login to this site.'));
// TRANS: OpenID authentication error.
$this->message(_m('OpenID authentication aborted: You are not allowed to login to this site.'));
return;
}
......@@ -118,10 +116,10 @@ class FinishaddopenidAction extends Action
if ($other) {
if ($other->id == $cur->id) {
// TRANS: message in case a user tries to add an OpenID that is already connected to them.
// TRANS: Message in case a user tries to add an OpenID that is already connected to them.
$this->message(_m('You already have this OpenID!'));
} else {
// TRANS: message in case a user tries to add an OpenID that is already used by another user.
// TRANS: Message in case a user tries to add an OpenID that is already used by another user.
$this->message(_m('Someone else already has this OpenID.'));
}
return;
......@@ -134,15 +132,15 @@ class FinishaddopenidAction extends Action
$result = oid_link_user($cur->id, $canonical, $display);
if (!$result) {
// TRANS: message in case the OpenID object cannot be connected to the user.
// TRANS: Message in case the OpenID object cannot be connected to the user.
$this->message(_m('Error connecting user.'));
return;
}
if (Event::handle('StartOpenIDUpdateUser', array($cur, $canonical, &$sreg))) {
if ($sreg) {
if (!oid_update_user($cur, $sreg)) {
// TRANS: message in case the user or the user profile cannot be saved in StatusNet.
$this->message(_m('Error updating profile'));
// TRANS: Message in case the user or the user profile cannot be saved in StatusNet.
$this->message(_m('Error updating profile.'));
return;
}
}
......@@ -168,7 +166,6 @@ class FinishaddopenidAction extends Action
*
* @return void
*/
function message($msg)
{
$this->message = $msg;
......@@ -180,7 +177,6 @@ class FinishaddopenidAction extends Action
*
* @return string title
*/
function title()
{
// TRANS: Title after getting the status of the OpenID authorisation request.
......@@ -192,7 +188,6 @@ class FinishaddopenidAction extends Action
*
* @return void
*/
function showPageNotice()
{
if ($this->message) {
......
......@@ -45,7 +45,7 @@ class FinishopenidloginAction extends Action
if ($this->arg('create')) {
if (!$this->boolean('license')) {
// TRANS: Message given if user does not agree with the site's license.
$this->showForm(_m('You can\'t register if you don\'t agree to the license.'),
$this->showForm(_m('You cannot register if you do not agree to the license.'),
$this->trimmed('newname'));
return;
}
......@@ -70,14 +70,14 @@ class FinishopenidloginAction extends Action
$this->element('div', 'instructions',
// TRANS: Instructions given after a first successful logon using OpenID.
// TRANS: %s is the site name.
sprintf(_m('This is the first time you\'ve logged into %s so we must connect your OpenID to a local account. You can either create a new account, or connect with your existing account, if you have one.'), common_config('site', 'name')));
sprintf(_m('This is the first time you have logged into %s so we must connect your OpenID to a local account. You can either create a new account, or connect with your existing account, if you have one.'), common_config('site', 'name')));
}
}
function title()
{
// TRANS: Title
return _m('OpenID Account Setup');
return _m('TITLE','OpenID Account Setup');
}
function showForm($error=null, $username=null)
......@@ -114,8 +114,10 @@ class FinishopenidloginAction extends Action
$this->hidden('token', common_session_token());
$this->elementStart('fieldset', array('id' => 'form_openid_createaccount'));
$this->element('legend', null,
// TRANS: Fieldset legend.
_m('Create new account'));
$this->element('p', null,
// TRANS: Form guide.
_m('Create a new user with this nickname.'));
$this->elementStart('ul', 'form_data');
......@@ -123,12 +125,16 @@ class FinishopenidloginAction extends Action
Event::handle('StartRegistrationFormData', array($this));
$this->elementStart('li');
// TRANS: Field label.
$this->input('newname', _m('New nickname'),
($this->username) ? $this->username : '',
// TRANS: Field title.
_m('1-64 lowercase letters or numbers, no punctuation or spaces.'));
$this->elementEnd('li');
$this->elementStart('li');
// TRANS: Field label.
$this->input('email', _m('Email'), $this->getEmail(),
// TRANS: Field title.
_m('Used only for updates, announcements, '.
'and password recovery.'));
$this->elementEnd('li');
......@@ -145,7 +151,7 @@ class FinishopenidloginAction extends Action
$this->elementStart('label', array('for' => 'license',
'class' => 'checkbox'));
// TRANS: OpenID plugin link text.
// TRANS: %s is a link to a licese with the license name as link text.
// TRANS: %s is a link to a license with the license name as link text.
$message = _m('My text and files are available under %s ' .
'except this private data: password, ' .
'email address, IM address, and phone number.');
......@@ -187,7 +193,7 @@ class FinishopenidloginAction extends Action
$this->password('password', _m('Password'));
$this->elementEnd('li');
$this->elementEnd('ul');
// TRANS: Button label in form in which to connect an OpenID to an existing user on the site.
// TRANS: Button text in form in which to connect an OpenID to an existing user on the site.
$this->submit('connect', _m('BUTTON', 'Connect'));
$this->elementEnd('fieldset');
$this->elementEnd('form');
......@@ -238,7 +244,7 @@ class FinishopenidloginAction extends Action
return;
} else if ($response->status == Auth_OpenID_FAILURE) {
// TRANS: OpenID authentication failed; display the error message. %s is the error message.
$this->message(sprintf(_m('OpenID authentication failed: %s'), $response->message));
$this->message(sprintf(_m('OpenID authentication failed: %s.'), $response->message));
} else if ($response->status == Auth_OpenID_SUCCESS) {
// This means the authentication succeeded; extract the
// identity URL and Simple Registration data (if it was
......@@ -258,7 +264,8 @@ class FinishopenidloginAction extends Action
// Launchpad teams extension
if (!oid_check_teams($response)) {
$this->message(_m('OpenID authentication aborted: you are not allowed to login to this site.'));
// TRANS: Message displayed when OpenID authentication is aborted.
$this->message(_m('OpenID authentication aborted: You are not allowed to login to this site.'));
return;
}
......@@ -490,7 +497,6 @@ class FinishopenidloginAction extends Action
function bestNewNickname($display, $sreg)
{
// Try the passed-in nickname
if (!empty($sreg['nickname'])) {
......@@ -549,7 +555,6 @@ class FinishopenidloginAction extends Action
// 1. Plain hostname, like http://evanp.myopenid.com/
// 2. One element in path, like http://profile.typekey.com/EvanProdromou/
// or http://getopenid.com/evanprodromou
function urlToNickname($openid)
{
return common_url_to_nickname($openid);
......@@ -579,7 +584,6 @@ class FinishopenidloginAction extends Action
}
// Given a string, try to make it work as a nickname
function nicknamize($str)
{
return common_nicknamize($str);
......
......@@ -85,7 +85,6 @@ function oid_get_last()
function oid_link_user($id, $canonical, $display)
{
$oid = new User_openid();
$oid->user_id = $id;
$oid->canonical = $canonical;
......@@ -152,7 +151,7 @@ function oid_authenticate($openid_url, $returnto, $immediate=false)
common_log(LOG_ERR, __METHOD__ . ": OpenID fail to $openid_url: $auth_request->message");
// TRANS: OpenID plugin server error. Given when the OpenID authentication request fails.
// TRANS: %s is the failure message.
return sprintf(_m('OpenID failure: %s'), $auth_request->message);
return sprintf(_m('OpenID failure: %s.'), $auth_request->message);
}
$sreg_request = Auth_OpenID_SRegRequest::build(// Required
......@@ -202,7 +201,7 @@ function oid_authenticate($openid_url, $returnto, $immediate=false)
} else if (Auth_OpenID::isFailure($redirect_url)) {
// TRANS: OpenID plugin server error. Given when the OpenID authentication request cannot be redirected.
// TRANS: %s is the failure message.
return sprintf(_m('Could not redirect to server: %s'), $redirect_url->message);
return sprintf(_m('Could not redirect to server: %s.'), $redirect_url->message);
} else {
common_redirect($redirect_url, 303);
}
......@@ -319,7 +318,7 @@ function oid_assert_allowed($url)
}
}
// TRANS: OpenID plugin client exception (403).
throw new ClientException(_m("Unauthorized URL used for OpenID login."), 403);
throw new ClientException(_m('Unauthorized URL used for OpenID login.'), 403);
}
}
......@@ -373,7 +372,7 @@ class AutosubmitAction extends Action
function showContent()
{
$this->raw('<p style="margin: 20px 80px">');
// @fixme this would be better using standard CSS class, but the present theme's a bit scary.
// @todo FIXME: This would be better using standard CSS class, but the present theme's a bit scary.
$this->element('img', array('src' => Theme::path('images/icons/icon_processing.gif', 'base'),
// for some reason the base CSS sets <img>s as block display?!
'style' => 'display: inline'));
......
......@@ -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 OpenidadminpanelAction extends AdminPanelAction
{
/**
......@@ -48,10 +47,10 @@ class OpenidadminpanelAction extends AdminPanelAction
*
* @return string page title
*/
function title()
{
return _m('OpenID');
// TRANS: Title for OpenID bridge administration page.
return _m('TITLE','OpenID Settings');
}
/**
......@@ -59,9 +58,9 @@ class OpenidadminpanelAction extends AdminPanelAction
*
* @return string instructions
*/
function getInstructions()
{
// TRANS: Page instructions.
return _m('OpenID settings');
}
......@@ -70,7 +69,6 @@ class OpenidadminpanelAction extends AdminPanelAction
*
* @return void
*/
function showForm()
{
$form = new OpenIDAdminPanelForm($this);
......@@ -83,7 +81,6 @@ class OpenidadminpanelAction extends AdminPanelAction
*
* @return void
*/
function saveSettings()
{
static $settings = array(
......@@ -144,13 +141,15 @@ class OpenidadminpanelAction extends AdminPanelAction
if (mb_strlen($values['openid']['trusted_provider']) > 255) {
$this->clientError(
_m("Invalid provider URL. Max length is 255 characters.")
// TRANS: Client error displayed when OpenID provider URL is too long.
_m('Invalid provider URL. Maximum length is 255 characters.')
);
}
if (mb_strlen($values['openid']['required_team']) > 255) {
$this->clientError(
_m("Invalid team name. Max length is 255 characters.")
// TRANS: Client error displayed when Launchpad team name is too long.
_m('Invalid team name. Maximum length is 255 characters.')
);
}
}
......@@ -163,7 +162,6 @@ class OpenIDAdminPanelForm extends AdminForm
*
* @return int ID of the form
*/
function id()
{
return 'openidadminpanel';
......@@ -174,7 +172,6 @@ class OpenIDAdminPanelForm extends AdminForm
*
* @return string class of the form
*/
function formClass()
{
return 'form_settings';
......@@ -185,7 +182,6 @@ class OpenIDAdminPanelForm extends AdminForm
*
* @return string URL of the action
*/
function action()
{
return common_local_url('openidadminpanel');
......@@ -200,15 +196,16 @@ class OpenIDAdminPanelForm extends AdminForm
* Make sure that the acting administrator has a valid OpenID matching,
* or more carefully warn folks.
*/
function formData()
{
$this->out->elementStart(
'fieldset',
array('id' => 'settings_openid')
);
$this->out->element('legend', null, _m('Trusted provider'));
// TRANS: Fieldset legend.
$this->out->element('legend', null, _m('LEGEND','Trusted provider'));
$this->out->element('p', 'form_guide',
// TRANS: Form guide.
_m('By default, users are allowed to authenticate with any OpenID provider. ' .
'If you are using your own OpenID service for shared sign-in, ' .
'you can restrict access to only your own users here.'));
......@@ -217,7 +214,9 @@ class OpenIDAdminPanelForm extends AdminForm
$this->li();
$this->input(
'trusted_provider',
// TRANS: Field label.
_m('Provider URL'),
// TRANS: Field title.
_m('All OpenID logins will be sent to this URL; other providers may not be used.'),
'openid'
);
......@@ -225,8 +224,10 @@ class OpenIDAdminPanelForm extends AdminForm
$this->li();
$this->out->checkbox(
// TRANS: Checkbox label.
'append_username', _m('Append a username to base URL'),
(bool) $this->value('append_username', 'openid'),
// TRANS: Checkbox title.
_m('Login form will show the base URL and prompt for a username to add at the end. Use when OpenID provider URL should be the profile page for individual users.'),
'true'
);
......@@ -235,7 +236,9 @@ class OpenIDAdminPanelForm extends AdminForm
$this->li();
$this->input(
'required_team',
_m('Required team'),
// TRANS: Field label.
_m('Required team'),
// TRANS: Field title.
_m('Only allow logins from users in the given team (Launchpad extension).'),
'openid'
);
......@@ -248,15 +251,18 @@ class OpenIDAdminPanelForm extends AdminForm
'fieldset',
array('id' => 'settings_openid-options')
);
$this->out->element('legend', null, _m('Options'));
// TRANS: Fieldset legend.
$this->out->element('legend', null, _m('LEGEND','Options'));
$this->out->elementStart('ul', 'form_data');
$this->li();
$this->out->checkbox(
// TRANS: Checkbox label.
'openidonly', _m('Enable OpenID-only mode'),
(bool) $this->value('openidonly', 'site'),
// TRANS: Checkbox title.
_m('Require all users to login via OpenID. Warning: disables password authentication for all users!'),
'true'
);
......@@ -272,9 +278,11 @@ class OpenIDAdminPanelForm extends AdminForm
*
* @return void
*/
function formActions()
{
$this->out->submit('submit', _m('Save'), 'submit', null, _m('Save OpenID settings.'));
// TRANS: Button text to save OpenID settings.
$this->out->submit('submit', _m('BUTTON','Save'), 'submit', null,
// TRANS: Button title to save OpenID settings.
_m('Save OpenID settings.'));
}
}
......@@ -111,7 +111,7 @@ class OpenidloginAction extends Action
function title()
{
// TRANS: OpenID plugin message. Title.
return _m('OpenID Login');
return _m('TITLE','OpenID Login');
}
function showForm($error=null, $openid_url)
......@@ -129,14 +129,14 @@ class OpenidloginAction extends Action