MediaWiki r5662 - Code Review

Jump to: navigation, search
Repository:MediaWiki
Revision:r5661‎ | r5662 (on ViewVC)‎ | r5663 >
Date:08:43, 3 October 2004
Author:jeluf
Status:old
Tags:
Comment:
BUG#419 Use $wgNavigationLinks for quickbar links, like in MonoBook
Modified paths:

Diff [purge]

Index: trunk/phase3/skins/CologneBlue.php
@@ -150,9 +150,13 @@
151151 return $s;
152152 }
153153
 154+ /**
 155+ * Compute the sidebar
 156+ * @private
 157+ */
154158 function quickBar()
155159 {
156 - global $wgOut, $wgTitle, $wgUser, $wgLang, $wgContLang, $wgDisableUploads;
 160+ global $wgOut, $wgTitle, $wgUser, $wgLang, $wgContLang, $wgDisableUploads, $wgNavigationLinks;
157161
158162 $tns=$wgTitle->getNamespace();
159163
@@ -162,13 +166,16 @@
163167 $s .= $this->menuHead( "qbfind" );
164168 $s .= $this->searchForm();
165169
166 - $s .= $this->menuHead( "qbbrowse" )
167 - . $this->mainPageLink()
168 - . $sep . $this->specialLink( "recentchanges" )
169 - . $sep . $this->specialLink( "randompage" );
170 - if ( wfMsgForContent ( "currentevents" ) != "-" ) $s .= $sep . $this->makeKnownLink( wfMsgForContent( "currentevents" ), "" ) ;
171 - $s .= "\n";
 170+ $s .= $this->menuHead( "qbbrowse" );
172171
 172+ foreach ( $wgNavigationLinks as $link ) {
 173+ $msg = wfMsgForContent( $link['href'] );
 174+ if ( $msg != '-' ) {
 175+ $s .= '<a href="' . $this->makeInternalOrExternalUrl( $msg ) . '">' .
 176+ wfMsg( $link['text'] ) . '</a>' . $sep;
 177+ }
 178+ }
 179+
173180 if ( $wgOut->isArticle() ) {
174181 $s .= $this->menuHead( "qbedit" );
175182 $s .= "<strong>" . $this->editThisPage() . "</strong>";

Follow-up revisions

Rev.Commit summaryAuthorDate
r5669Moved quickBar from Skin.php to Standard.php, only used by this skin....jeluf11:26, 3 October 2004
r9152* (bug 419) The contents of the navigation toolbar are now editable through...avar14:57, 23 May 2005
r9177* (bug 419, 1764) Using a custom syntax for the sidebar and supporting multiple...avar20:06, 24 May 2005
r9181* Moved the note about bug 419 under the correct heading...avar20:29, 24 May 2005

Past revisions this follows-up on

Rev.Commit summaryAuthorDate
r5528BUG#419 Added global variable that defines the elements of the navigation sid...jeluf09:45, 26 September 2004

Status & tagging log

  • 01:56, 13 October 2010 ^demon (Talk | contribs) changed the status of r5662 [removed: new added: old]
Personal tools
Namespaces

Variants
Views
Actions
Navigation
Support
Download
Development
Communication
Toolbox