}
$qbs = $wgLang->getQuickbarSettings();
- $skinNames = $wgLang->getSkinNames();
$mathopts = $wgLang->getMathNames();
$dateopts = $wgLang->getDatePreferences();
$togs = User::getToggles();
#
global $wgAllowUserSkin;
if( $wgAllowUserSkin ) {
- $wgOut->addHTML( "<fieldset>\n<legend>\n" . wfMsg('skin') . "</legend>\n" );
+ $wgOut->addHTML( "<fieldset>\n<legend>\n" . wfMsg( 'skin' ) . "</legend>\n" );
$mptitle = Title::newMainPage();
- $previewtext = wfMsg('skin-preview');
+ $previewtext = wfMsg( 'skin-preview' );
# Only show members of Skin::getSkinNames() rather than
# $skinNames (skins is all skin names from Language.php)
$validSkinNames = Skin::getUsableSkins();
# Sort by UI skin name. First though need to update validSkinNames as sometimes
# the skinkey & UI skinname differ (e.g. "standard" skinkey is "Classic" in the UI).
- foreach ($validSkinNames as $skinkey => & $skinname ) {
- if ( isset( $skinNames[$skinkey] ) ) {
- $skinname = $skinNames[$skinkey];
+ foreach ( $validSkinNames as $skinkey => &$skinname ) {
+ $msgName = "skinname-{$skinkey}";
+ $localisedSkinName = wfMsg( $msgName );
+ if ( !wfEmptyMsg( $msgName, $localisedSkinName ) ) {
+ $skinname = $localisedSkinName;
}
}
asort($validSkinNames);
foreach ($validSkinNames as $skinkey => $sn ) {
$checked = $skinkey == $this->mSkin ? ' checked="checked"' : '';
- $mplink = htmlspecialchars($mptitle->getLocalURL("useskin=$skinkey"));
+ $mplink = htmlspecialchars( $mptitle->getLocalURL( "useskin=$skinkey" ) );
$previewlink = "(<a target='_blank' href=\"$mplink\">$previewtext</a>)";
if( $skinkey == $wgDefaultSkin )
$sn .= ' (' . wfMsg( 'default' ) . ')';
var $mConverter, $mVariants, $mCode, $mLoaded = false;
var $mMagicExtensions = array(), $mMagicHookDone = false;
- static public $mLocalisationKeys = array( 'fallback', 'namespaceNames',
- 'skinNames', 'mathNames',
- 'bookstoreList', 'magicWords', 'messages', 'rtl', 'digitTransformTable',
+ static public $mLocalisationKeys = array(
+ 'fallback', 'namespaceNames', 'mathNames', 'bookstoreList',
+ 'magicWords', 'messages', 'rtl', 'digitTransformTable',
'separatorTransformTable', 'fallback8bitEncoding', 'linkPrefixExtension',
'defaultUserOptionOverrides', 'linkTrail', 'namespaceAliases',
'dateFormats', 'datePreferences', 'datePreferenceMigrationMap',
if ( isset( $aliases[$name][0] ) ) {
$name = $aliases[$name][0];
}
- return $this->getNsText(NS_SPECIAL) . ':' . $name;
+ return $this->getNsText( NS_SPECIAL ) . ':' . $name;
}
function getQuickbarSettings() {
);
}
- function getSkinNames() {
- $this->load();
- return $this->skinNames;
- }
-
function getMathNames() {
$this->load();
return $this->mathNames;
*/
$namespaceAliases = array();
-/**
- * Skin names. If any key is not specified, the English one will be used.
- */
-$skinNames = array(
- 'standard' => 'Classic',
- 'nostalgia' => 'Nostalgia',
- 'cologneblue' => 'Cologne Blue',
- 'monobook' => 'MonoBook',
- 'myskin' => 'MySkin',
- 'chick' => 'Chick',
- 'simple' => 'Simple',
- 'modern' => 'Modern',
-);
-
/**
* Deprecated, use the message array
*/
'numauthors' => 'Number of distinct authors (page): $1',
'numtalkauthors' => 'Number of distinct authors (discussion page): $1',
+# Skins names
+'skinname-standard' => 'Classic',
+'skinname-nostalgia' => 'Nostalgia',
+'skinname-cologneblue' => 'Cologne Blue',
+'skinname-monobook' => 'MonoBook',
+'skinname-myskin' => 'MySkin',
+'skinname-chick' => 'Chick',
+'skinname-simple' => 'Simple',
+'skinname-modern' => 'Modern',
+
# Math options
'mw_math_png' => 'Always render PNG',
'mw_math_simple' => 'HTML if very simple or else PNG',
return array(
'untranslated', 'duplicate', 'obsolete', 'variables', 'empty', 'plural',
'whitespace', 'xhtml', 'chars', 'links', 'unbalanced', 'namespace',
- 'projecttalk', 'skin', 'magic', 'magic-old', 'magic-over', 'magic-case',
+ 'projecttalk', 'magic', 'magic-old', 'magic-over', 'magic-case',
'special', 'special-old',
);
}
*/
protected function nonMessageChecks() {
return array(
- 'namespace', 'projecttalk', 'skin', 'magic', 'magic-old', 'magic-over',
+ 'namespace', 'projecttalk', 'magic', 'magic-old', 'magic-over',
'magic-case', 'special', 'special-old',
);
}
'unbalanced' => 'getMessagesWithUnbalanced',
'namespace' => 'getUntranslatedNamespaces',
'projecttalk' => 'getProblematicProjectTalks',
- 'skin' => 'getUntranslatedSkins',
'magic' => 'getUntranslatedMagicWords',
'magic-old' => 'getObsoleteMagicWords',
'magic-over' => 'getOverridingMagicWords',
return array(
'namespace' => array( 'getNamespaceNames', 'en' ),
'projecttalk' => null,
- 'skin' => array( 'getSkinNames', 'en' ),
'magic' => array( 'getMagicWords', 'en' ),
'magic-old' => array( 'getMagicWords', null ),
'magic-over' => array( 'getMagicWords', null ),
'unbalanced' => '$1 message(s) of $2 in $3 have unbalanced {[]}:',
'namespace' => '$1 namespace name(s) of $2 are not translated to $3, but exist in en:',
'projecttalk' => '$1 namespace name(s) and alias(es) in $3 are project talk namespaces without the parameter:',
- 'skin' => '$1 skin name(s) of $2 are not translated to $3, but exist in en:',
'magic' => '$1 magic word(s) of $2 are not translated to $3, but exist in en:',
'magic-old' => '$1 magic word(s) of $2 do not exist in en, but exist in $3:',
'magic-over' => '$1 magic word(s) of $2 in $3 do not contain the original en word(s):',
* unbalanced: Messages which contains unequal numbers of opening {[ and closing ]}.
* namespace: Namespace names that were not translated.
* projecttalk: Namespace names and aliases where the project talk does not contain $1.
- * skin: Skin names that were not translated.
* magic: Magic words that were not translated.
* magic-old: Magic words which do not exist.
* magic-over: Magic words that override the original English word.
protected $mNamespaceNames; # Namespace names
protected $mNamespaceAliases; # Namespace aliases
- protected $mSkinNames; # Skin names
protected $mMagicWords; # Magic words
protected $mSpecialPageAliases; # Special page aliases
if ( isset( $this->mRawMessages[$code] ) &&
isset( $this->mNamespaceNames[$code] ) &&
isset( $this->mNamespaceAliases[$code] ) &&
- isset( $this->mSkinNames[$code] ) &&
isset( $this->mMagicWords[$code] ) &&
isset( $this->mSpecialPageAliases[$code] ) ) {
return;
$this->mRawMessages[$code] = array();
$this->mNamespaceNames[$code] = array();
$this->mNamespaceAliases[$code] = array();
- $this->mSkinNames[$code] = array();
$this->mMagicWords[$code] = array();
$this->mSpecialPageAliases[$code] = array();
$filename = Language::getMessagesFileName( $code );
if ( isset( $namespaceAliases ) ) {
$this->mNamespaceAliases[$code] = $namespaceAliases;
}
- if ( isset( $skinNames ) ) {
- $this->mSkinNames[$code] = $skinNames;
- }
if ( isset( $magicWords ) ) {
$this->mMagicWords[$code] = $magicWords;
}
return $this->mNamespaceAliases[$code];
}
- /**
- * Get skin names for a specific language.
- *
- * @param $code The language code.
- *
- * @return Skin names.
- */
- public function getSkinNames( $code ) {
- $this->loadFile( $code );
- return $this->mSkinNames[$code];
- }
-
/**
* Get magic words for a specific language.
*
return $namespaces;
}
- /**
- * Get the untranslated skin names.
- *
- * @param $code The language code.
- *
- * @return The untranslated skin names in this language.
- */
- public function getUntranslatedSkins( $code ) {
- $this->loadFile( 'en' );
- $this->loadFile( $code );
- return array_diff_key( $this->mSkinNames['en'], $this->mSkinNames[$code] );
- }
-
/**
* Get the untranslated magic words.
*
'numauthors',
'numtalkauthors',
),
+ 'skin' => array(
+ 'skinname-standard',
+ 'skinname-nostalgia',
+ 'skinname-cologneblue',
+ 'skinname-monobook',
+ 'skinname-myskin',
+ 'skinname-chick',
+ 'skinname-simple',
+ 'skinname-modern',
+ ),
'math' => array(
'mw_math_png',
'mw_math_simple',
'attribution' => 'Attribution',
'spamprotection' => 'Spam protection',
'info' => 'Info page',
+ 'skin' => 'Skins names',
'math' => 'Math options',
'patrolling' => 'Patrolling',
'patrol-log' => 'Patrol log',