r88922 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r88921‎ | r88922 | r88923 >
Date:20:05, 26 May 2011
Author:mkroetzsch
Status:deferred
Tags:
Comment:
renamed method
Modified paths:
  • /trunk/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_Types.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticMediaWiki/includes/datavalues/SMW_DV_Types.php
@@ -100,7 +100,7 @@
101101 if ( ( $linked === null ) || ( $linked === false ) || ( $this->m_outformat == '-' ) || ( $this->m_caption == '' ) ) {
102102 return $this->m_caption;
103103 } else {
104 - $titleText = $this->getTitleText();
 104+ $titleText = $this->getSpecialPageTitleText();
105105 $namespace = $wgContLang->getNsText( NS_SPECIAL );
106106 return "[[$namespace:$titleText|{$this->m_caption}]]";
107107 }
@@ -110,7 +110,7 @@
111111 if ( ( $linked === null ) || ( $linked === false ) || ( $this->m_outformat == '-' ) || ( $this->m_caption == '' ) ) {
112112 return htmlspecialchars( $this->m_caption );
113113 } else {
114 - $title = Title::makeTitle( NS_SPECIAL, $this->getTitleText() );
 114+ $title = Title::makeTitle( NS_SPECIAL, $this->getSpecialPageTitleText() );
115115 return $linker->makeLinkObj( $title, htmlspecialchars( $this->m_caption ) );
116116 }
117117 }
@@ -120,7 +120,7 @@
121121 if ( ( $linked === null ) || ( $linked === false ) ) {
122122 return $this->m_realLabel;
123123 } else {
124 - $titleText = $this->getTitleText();
 124+ $titleText = $this->getSpecialPageTitleText();
125125 $namespace = $wgContLang->getNsText( NS_SPECIAL );
126126 return "[[$namespace:$titleText|{$this->m_realLabel}]]";
127127 }
@@ -130,7 +130,7 @@
131131 if ( ( $linker === null ) || ( $linker === false ) ) {
132132 return htmlspecialchars( $this->m_realLabel );
133133 } else {
134 - $title = Title::makeTitle( NS_SPECIAL, $this->getTitleText() );
 134+ $title = Title::makeTitle( NS_SPECIAL, $this->getSpecialPageTitleText() );
135135 return $linker->makeLinkObj( $title, htmlspecialchars( $this->m_realLabel ) );
136136 }
137137 }
@@ -145,7 +145,7 @@
146146 *
147147 * @return string
148148 */
149 - protected function getTitleText() {
 149+ protected function getSpecialPageTitleText() {
150150 return is_callable( array( 'SpecialPageFactory', 'getLocalNameFor' ) ) ?
151151 SpecialPageFactory::getLocalNameFor( 'Types', $this->m_realLabel )
152152 : SpecialPage::getLocalNameFor( 'Types', $this->m_realLabel );

Status & tagging log