* (bug 2534) Hide edit sections with CSS to make right click to edit section work
authorNiklas Laxström <nikerabbit@users.mediawiki.org>
Tue, 5 Jul 2005 19:15:13 +0000 (19:15 +0000)
committerNiklas Laxström <nikerabbit@users.mediawiki.org>
Tue, 5 Jul 2005 19:15:13 +0000 (19:15 +0000)
* Remove some unneeded stuff!?

RELEASE-NOTES
includes/Parser.php
includes/Skin.php
includes/User.php

index aa20ded..86d1b8e 100644 (file)
@@ -503,6 +503,7 @@ of MediaWiki:Newpagetext) to &action=edit, if page is new.
 
 == Changes since 1.5beta2 ==
 * Escaped & correctly in Special:Contributions
+* (bug 2534) Hide edit sections with CSS to make right click to edit section work 
 
 === Caveats ===
 
index 163e654..bff43b9 100644 (file)
@@ -3427,7 +3427,7 @@ class ParserOptions
                $this->mSkin =& $user->getSkin();
                wfProfileOut( $fname.'-skin' );
                $this->mDateFormat = $user->getOption( 'date' );
-               $this->mEditSection = $user->getOption( 'editsection' );
+               $this->mEditSection = true;
                $this->mNumberHeadings = $user->getOption( 'numberheadings' );
                $this->mAllowSpecialInclusion = $wgAllowSpecialInclusion;
                wfProfileOut( $fname );
index ad48e25..b6405a3 100644 (file)
@@ -293,6 +293,9 @@ END;
                if( !$wgUser->getOption( 'showtoc' ) ) {
                        $s .= "#toc { display: none; }\n";
                }
+               if( !$wgUser->getOption( 'editsection' ) ) {
+                       $s .= ".editsection { display: none; }\n";
+               }
                return $s;
        }
 
@@ -495,7 +498,7 @@ END;
        function doAfterContent() { }
 
        function pageTitleLinks() {
-               global $wgOut, $wgTitle, $wgUser, $wgContLang, $wgUseApproval, $wgRequest;
+               global $wgOut, $wgTitle, $wgUser, $wgContLang, $wgRequest;
 
                extract( $wgRequest->getValues( 'oldid', 'diff' ) );
                $action = $wgRequest->getText( 'action' );
@@ -516,16 +519,6 @@ END;
                                        $s .= " | <a href=\"{$link}\"{$style}>{$name}</a>";
                                }
                        }
-                       # This will show the "Approve" link if $wgUseApproval=true;
-                       if ( isset ( $wgUseApproval ) && $wgUseApproval )
-                       {
-                               $t = $wgTitle->getDBkey();
-                               $name = 'Approve this article' ;
-                               $link = "http://test.wikipedia.org/w/magnus/wiki.phtml?title={$t}&action=submit&doit=1" ;
-                               #htmlspecialchars( wfImageUrl( $name ) );
-                               $style = $this->getExternalLinkAttributes( $link, $name );
-                               $s .= " | <a href=\"{$link}\"{$style}>{$name}</a>" ;
-                       }
                }
                if ( 'history' == $action || isset( $diff ) || isset( $oldid ) ) {
                        $s .= ' | ' . $this->makeKnownLinkObj( $wgTitle,
index edf98ef..2d676c6 100644 (file)
@@ -1435,7 +1435,6 @@ class User {
 
                $confstr =        $this->getOption( 'math' );
                $confstr .= '!' . $this->getOption( 'stubthreshold' );
-               $confstr .= '!' . $this->getOption( 'editsection' );
                $confstr .= '!' . $this->getOption( 'date' );
                $confstr .= '!' . $this->getOption( 'numberheadings' );
                $confstr .= '!' . $this->getOption( 'language' );