Convert simple skin to Resource loader.
authorDerk-Jan Hartman <hartman@users.mediawiki.org>
Thu, 13 Jan 2011 11:28:35 +0000 (11:28 +0000)
committerDerk-Jan Hartman <hartman@users.mediawiki.org>
Thu, 13 Jan 2011 11:28:35 +0000 (11:28 +0000)
I removed all of the useroptions generators that were dupe with resourceloaderuseroptions.
The 'highlightbroken' option differs from what is in resourceloaderuseroptions and still remains to be ported.

Bugzilla #26649

skins/Simple.php
skins/simple/rtl.css [deleted file]

index 61564c2..32d7491 100644 (file)
@@ -25,16 +25,11 @@ class SkinSimple extends SkinTemplate {
                parent::setupSkinUserCss( $out );
 
                $out->addStyle( 'simple/main.css', 'screen' );
-               $out->addStyle( 'simple/rtl.css', '', '', 'rtl' );
        }
 
        function reallyGenerateUserStylesheet() {
                global $wgUser;
                $s = '';
-               if( ( $undopt = $wgUser->getOption( 'underline' ) ) != 2 ) {
-                       $underline = $undopt ? 'underline' : 'none';
-                       $s .= "a { text-decoration: $underline; }\n";
-               }
                if( $wgUser->getOption( 'highlightbroken' ) ) {
                        $s .= "a.new, #quickbar a.new { text-decoration: line-through; }\n";
                } else {
@@ -56,15 +51,6 @@ a.stub:after, #quickbar a.stub:after {
 }
 CSS;
                }
-               if( $wgUser->getOption( 'justify' ) ) {
-                       $s .= "#article, #bodyContent { text-align: justify; }\n";
-               }
-               if( !$wgUser->getOption( 'showtoc' ) ) {
-                       $s .= "#toc { display: none; }\n";
-               }
-               if( !$wgUser->getOption( 'editsection' ) ) {
-                       $s .= ".editsection { display: none; }\n";
-               }
                return $s;
        }
 }
diff --git a/skins/simple/rtl.css b/skins/simple/rtl.css
deleted file mode 100644 (file)
index 61470ca..0000000
+++ /dev/null
@@ -1,186 +0,0 @@
-/*
-Right-to-left fixes for Simple.
-Places sidebar on right, tweaks various alignment issues.
-
-Works mostly ok nicely on Safari 1.2.1; fine in Mozilla.
-
-Safari bugs (1.2.1):
-* Tabs are still appearing in left-to-right order. (Try after localizing)
-
-Opera bugs (7.23 linux):
-* Some bits of ltr text (sidebar box titles) have forward and backward versions overlapping each other
-
-IE/mac bugs:
-* The thing barfs on Hebrew and Arabic anyway, so no point testing.
-
-Missing features due to lack of support:
-* external link icons
-
-To test:
-* Opera6
-* IE 5.0
-* etc
-
-*/
-body {
-       direction: rtl;
-       unicode-bidi: embed;
-}
-#column-content {
-       margin: 0 -12.2em 0 0;
-       float: left;
-}
-#column-content #content{
-       margin-left: 0;
-       margin-right: 12.2em;
-       border-right: 1px solid #aaaaaa;
-       border-left: none;
-}
-html>body .portlet {
-       float: right;
-       clear: right;
-}
-.editsection {
-       float: left;
-       margin-right: 5px;
-       margin-left: 0; /* bug 9122: undo default LTR */
-}
-/* recover IEMac (might be fine with the float, but usually it's close to IE */
-*>body .portlet {
-       float: none;
-       clear: none;
-}
-.pBody {
-       padding: 0 0.5em 0.3em 0.8em;
-}
-
-/* Fix alignment */
-.documentByLine,
-.portletDetails,
-.portletMore {
-       text-align: left;
-}
-
-div div.thumbcaption {
-       text-align: right;
-}
-
-div.magnify,
-#p-logo {
-       left: auto;
-       right: 0;
-}
-
-/* Fix margins for non-css2 browsers */
-/* top right bottom left */
-
-dd {
-       margin-left: 0;
-       margin-right: 1.6em;
-}
-#contentSub {
-       margin-right: 1em;
-       margin-left: 0;
-}
-.tocindent {
-       margin-left: 0;
-       margin-right: 2em;
-}
-div.tright, div.floatright, table.floatright {
-       clear: none;
-}
-div.tleft, div.floatleft, table.floatleft {
-       clear: left;
-}
-
-/* Fix link icons */
-.external, a.feedlink {
-       padding: 0 !important;
-       background: none !important;
-}
-#footer {
-       clear: both;
-}
-* html #footer {
-       margin-left: 0;
-       margin-right: 13.6em;
-       border-left: 0;
-       border-right: 1px solid #fabd23;
-} 
-* html #column-content { 
-       float: none;
-       margin-left: 0;
-       margin-right: 0;
-}
-* html #column-content #content {
-       margin-left: 0;
-       margin-top: 3em;
-}
-* html #column-one { right: 0; }
-
-/* js pref toc */
-
-#preftoc {
-       margin-right: 1em;
-}
-
-.errorbox, .successbox, #preftoc li, .prefsection fieldset {
-       float: right;
-}
-
-.prefsection {
-       padding-right: 2em;
-}
-
-/* workaround for moz bug, displayed bullets on left side */
-
-#toc ul {
-       text-align: right;
-}
-
-#toc ul ul {
-       margin: 0 2em 0 0;
-}
-
-input#wpSave, input#wpDiff {
-       margin-right: 0;
-       margin-left: .33em;
-}
-
-#userlogin {
-       margin: 0 0 1em 3em;
-}
-/* Convenience links to edit block, delete and protect reasons */
-p.mw-ipb-conveniencelinks, p.mw-protect-editreasons,
-p.mw-filedelete-editreasons, p.mw-delete-editreasons {
-       float: left;
-}
-
-.toggle {
-       margin-left: 0em;
-       margin-right: 2em;
-}
-table.filehistory th {
-       text-align: right;
-}
-
-/**
- * Lists:
- * The following lines don't have a visible effect on non-Gecko browsers
- * They fix a problem ith Gecko browsers rendering lists to the right of
- * left-floated objects in an RTL layout.
- */
-html > body div#bodyContent ul {
-       display: table;
-}
-
-/* Special:Allpages styling */
-td.mw-allpages-nav, p.mw-allpages-nav, td.mw-allpages-alphaindexline {
-       text-align: left;
-}
-
-/* Special:Prefixindex styling */
-td#mw-prefixindex-nav-form  {
-       text-align: left;
-}
-