http://www.mediawiki.org/wiki/Special:Code/MediaWiki/90580

Revision: 90580
Author:   reedy
Date:     2011-06-22 12:03:23 +0000 (Wed, 22 Jun 2011)
Log Message:
-----------
Followup r87593, fix calls to removed methods

Modified Paths:
--------------
    trunk/extensions/Asksql/Asksql_body.php
    trunk/extensions/ImageTagging/ImageTagging_body.php
    trunk/extensions/MetavidWiki/includes/MV_ImageGallery.php
    trunk/extensions/TalkHere/TalkHere.php
    trunk/extensions/WikiForum/WikiForumClass.php
    trunk/extensions/Wikidata/OmegaWiki/Editor.php

Modified: trunk/extensions/Asksql/Asksql_body.php
===================================================================
--- trunk/extensions/Asksql/Asksql_body.php     2011-06-22 11:52:11 UTC (rev 
90579)
+++ trunk/extensions/Asksql/Asksql_body.php     2011-06-22 12:03:23 UTC (rev 
90580)
@@ -13,8 +13,8 @@
        function execute( $par ) {
                global $wgAllowSysopQueries, $wgUser, $wgRequest, $wgOut;
 
-               
 
+
                if ( !$wgAllowSysopQueries ) {
                        throw new ErrorPageError( 'nosuchspecialpage', 
'nospecialpagetext' );
                }
@@ -141,8 +141,9 @@
                                        } else {
                                                $link = "$sTitle";
                                        }
+                                       $title = Title::newFromText( $link );
                                        $skin = $wgUser->getSkin();
-                                       $link = $skin->makeLink( $link );
+                                       $link = $skin->makeLinkObj( $title );
                                        $r .= "* [[$link]]<br />\n";
                                }
                        } else {

Modified: trunk/extensions/ImageTagging/ImageTagging_body.php
===================================================================
--- trunk/extensions/ImageTagging/ImageTagging_body.php 2011-06-22 11:52:11 UTC 
(rev 90579)
+++ trunk/extensions/ImageTagging/ImageTagging_body.php 2011-06-22 12:03:23 UTC 
(rev 90580)
@@ -1,6 +1,6 @@
 <?php
 /**
- * TaggedImages class 
+ * TaggedImages class
  *
  * @file
  * @ingroup Extensions
@@ -235,7 +235,7 @@
         * - the size of the image
         */
        function toHTML() {
-               global $wgLang, $wgUser, $wgOut;
+               global $wgLang, $wgUser;
 
                $sk = $wgUser->getSkin();
 
@@ -261,9 +261,6 @@
                                continue;
                        }
 
-                       // TODO - getUser() doesn't exist, do you mean NS_USER?
-                       // $ul = $sk->makeLink( $wgContLang->getNsText( 
MWNamespace::getUser() ) . ":{$ut}", $ut );
-
                        $nb = '';
                        $textlink = $this->mShowFilename ?
                        $sk->makeKnownLinkObj( $nt, htmlspecialchars( 
$wgLang->truncate( $nt->getText(), 20 ) ) ) . "<br />\n" :

Modified: trunk/extensions/MetavidWiki/includes/MV_ImageGallery.php
===================================================================
--- trunk/extensions/MetavidWiki/includes/MV_ImageGallery.php   2011-06-22 
11:52:11 UTC (rev 90579)
+++ trunk/extensions/MetavidWiki/includes/MV_ImageGallery.php   2011-06-22 
12:03:23 UTC (rev 90580)
@@ -1,10 +1,10 @@
 <?php
 /*
  * MV_ImageGallery.php Created on Oct 22, 2007
- * 
+ *
  * All Metavid Wiki code is Released Under the GPL2
  * for more info visit http://metavid.org/wiki/Code
- * 
+ *
  * @author Michael Dale
  * @email [email protected]
  * @url http://metavid.org
@@ -37,20 +37,19 @@
                foreach ( $this->mImages as $pair ) {
                        $nt = $pair[0];
                        $text = $pair[1];
-                       
+
                        # Give extensions a chance to select the file revision 
for us
                        $time = false;
                        wfRunHooks( 'BeforeGalleryFindFile', array( &$this, 
&$nt, &$time ) );
 
                        $img = wfFindFile( $nt, array( 'time' => $time ) );
-                       
-                       
+
                        if ( $nt->getNamespace() == MV_NS_MVD ||
                                $nt->getNamespace() == MV_NS_STREAM ||
                                $nt->getNamespace() == MV_NS_SEQUENCE ) { // 
@@todo fix sequence embed
-                               // $vpad = floor( ( 1.25*$this->mHeights - 
$thumb->height ) /2 ) - 2;                           
+                               // $vpad = floor( ( 1.25*$this->mHeights - 
$thumb->height ) /2 ) - 2;
                                $mvTitle = new MV_Title( $nt );
-                               
+
                                // remap MVD namespace links into the Stream 
view (so contextual metadata is present)
                                if ( $nt->getNamespace() == MV_NS_MVD ) {
                                        $nt = Title::MakeTitle( MV_NS_STREAM, 
ucfirst( $mvTitle->getStreamName() ) . '/' . $mvTitle->getTimeRequest() );
@@ -62,7 +61,7 @@
                                        '<div class="thumb" style="padding: 4px 
0; width: ' . htmlspecialchars( $this->mWidths + 5 ) . 'px;">'
                                        # Auto-margin centering for block-level 
elements. Needed now that we have video
                                        # handlers since they may emit 
block-level elements as opposed to simple <img> tags.
-                                       # ref 
http://css-discuss.incutio.com/?page=CenteringBlockElement                      
          
+                                       # ref 
http://css-discuss.incutio.com/?page=CenteringBlockElement
                                        . '<div style="margin-left: auto; 
margin-right: auto; width: ' . htmlspecialchars( $this->mWidths ) . 'px;">'
                                        .  $sk->makeKnownLinkObj( $nt, '<img 
title="'. htmlspecialchars($mvTitle->getStreamNameText()) .'"'
                                                        . ' width="160" 
height="120" src="'.$mvTitle->getStreamImageURL('160x120') . '">')
@@ -76,7 +75,7 @@
                                        $nb = '';
                                        $textlink = '';
                        } else {
-                               
+
                                if ( $nt->getNamespace() != NS_IMAGE || !$img ) 
{
                                        # We're dealing with a non-image, spit 
out the name and be done with it.
                                        $thumbhtml = "\n\t\t\t" . '<div 
style="height: ' . ( $this->mHeights * 1.25 + 2 ) . 'px;">'
@@ -91,7 +90,7 @@
                                                . htmlspecialchars( 
$img->getLastError() ) . '</div>';
                                } else {
                                        $vpad = floor( ( 1.25 * $this->mHeights 
- $thumb->height ) / 2 ) - 2;
-                                               
+
                                        $thumbhtml = "\n\t\t\t" .
                                                '<div class="thumb" 
style="padding: ' . htmlspecialchars( $vpad ) . 'px 0; width: ' . 
htmlspecialchars( $this->mWidths + 30 ) . 'px;">'
                                                # Auto-margin centering for 
block-level elements. Needed now that we have video
@@ -99,15 +98,12 @@
                                                # ref 
http://css-discuss.incutio.com/?page=CenteringBlockElement
                                                . '<div style="margin-left: 
auto; margin-right: auto; width: ' . htmlspecialchars( $this->mWidths ) . 
'px;">'
                                                . $thumb->toHtml( array( 
'desc-link' => true ) ) . '</div></div>';
-       
+
                                        // Call parser transform hook
                                        if ( $this->mParser && 
$img->getHandler() ) {
                                                
$img->getHandler()->parserTransformHook( $this->mParser, $img );
                                        }
                                }
-       
-                               // TODO
-                               // $ul = $sk->makeLink( $wgContLang->getNsText( 
MWNamespace::getUser() ) . ":{$ut}", $ut );
 
                                if ( $this->mShowBytes ) {
                                        if ( $img ) {
@@ -120,7 +116,7 @@
                                } else {
                                        $nb = '';
                                }
-       
+
                                $textlink = $this->mShowFilename ?
                                        $sk->makeKnownLinkObj( $nt, 
htmlspecialchars( $wgLang->truncate( $nt->getText(), 20 ) ) ) . "<br />\n" :
                                        '' ;

Modified: trunk/extensions/TalkHere/TalkHere.php
===================================================================
--- trunk/extensions/TalkHere/TalkHere.php      2011-06-22 11:52:11 UTC (rev 
90579)
+++ trunk/extensions/TalkHere/TalkHere.php      2011-06-22 12:03:23 UTC (rev 
90580)
@@ -47,7 +47,7 @@
        $html = $out->getHTML();
 
        if ( $returnto ) { //re-target cancel link
-               $cancel = $sk->makeLink( $returnto, wfMsgExt('cancel', 
array('parseinline')) );
+               $cancel = $sk->makeLinkObj( Title::newFromText( $returnto ), 
wfMsgExt('cancel', array( 'parseinline' ) ) );
                $html = preg_replace( '!<a[^<>]+>[^<>]+</a>( *\| *<a 
target=["\']helpwindow["\'])!smi', $cancel . '\1', $html );
        }
        else  {

Modified: trunk/extensions/WikiForum/WikiForumClass.php
===================================================================
--- trunk/extensions/WikiForum/WikiForumClass.php       2011-06-22 11:52:11 UTC 
(rev 90579)
+++ trunk/extensions/WikiForum/WikiForumClass.php       2011-06-22 12:03:23 UTC 
(rev 90580)
@@ -2341,8 +2341,8 @@
 
                if( $username ) {
                        $sk = $wgUser->getSkin();
-                       $retVal = $sk->makeLink(
-                               $wgContLang->getNsText( NS_USER ) . ':' . 
$username,
+                       $retVal = $sk->makeLinkObj(
+                               Title::newFromText( $wgContLang->getNsText( 
NS_USER ) . ':' . $username ),
                                htmlspecialchars( $username )
                        );
 

Modified: trunk/extensions/Wikidata/OmegaWiki/Editor.php
===================================================================
--- trunk/extensions/Wikidata/OmegaWiki/Editor.php      2011-06-22 11:52:11 UTC 
(rev 90579)
+++ trunk/extensions/Wikidata/OmegaWiki/Editor.php      2011-06-22 12:03:23 UTC 
(rev 90580)
@@ -2107,7 +2107,7 @@
                        $wgUser;
                        
                if ( $value != "" )
-                       return $wgUser->getSkin()->makeLink( "User:" . $value, 
$value );
+                       return $wgUser->getSkin()->makeLinkObj( 
Title::newFromText( "User:" . $value ), $value );
                else
                        return "";
        }


_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to