r53203 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r53202‎ | r53203 | r53204 >
Date:22:48, 13 July 2009
Author:tparscal
Status:ok
Tags:
Comment:
Fixed bug caused in r52944 - where the inclusion of csshover.htc was lost in the move towards $wgOut->headElement(). Also, simplified the LTR/RTL inclusion - bringing the logic into the output page object.
Modified paths:
  • /trunk/phase3/skins/Vector.php (modified) (history)

Diff [purge]

Index: trunk/phase3/skins/Vector.php
@@ -24,29 +24,26 @@
2525 * @param object $out Output page object to initialize
2626 */
2727 public function initPage( OutputPage $out ) {
 28+ global $wgStylePath;
 29+
2830 parent::initPage( $out );
2931 $this->skinname = 'vector';
3032 $this->stylename = 'vector';
3133 $this->template = 'VectorTemplate';
 34+
 35+ // Append skin-specific styles
 36+ $out->addStyle( 'vector/main-rtl.css', 'screen', '', 'rtl' );
 37+ $out->addStyle( 'vector/main-ltr.css', 'screen', '', 'ltr' );
 38+ // Append CSS which includes IE only behavior fixes for hover support -
 39+ // this is better than including this in a CSS fille since it doesn't
 40+ // wait for the CSS file to load before fetching the HTC file.
 41+ $out->addScript(
 42+ '<!--[if lt IE 7]><style type="text/css">body{behavior:url("' .
 43+ $wgStylePath .
 44+ '/vector/csshover.htc")}</style><![endif]-->'
 45+ );
3246 }
33 -
3447 /**
35 - * Defines CSS files to be included
36 - * @param object $out Output page to add styles to
37 - */
38 - public function setupSkinUserCss( OutputPage $out ) {
39 - global $wgContLang;
40 - // Append to the default screen common & print styles...
41 - if ( $wgContLang->isRTL() ) {
42 - $out->addStyle( 'vector/main-rtl.css', 'screen' );
43 - } else {
44 - $out->addStyle( 'vector/main-ltr.css', 'screen' );
45 - }
46 - // Add common styles
47 - parent::setupSkinUserCss( $out );
48 - }
49 -
50 - /**
5148 * Builds a structured array of links used for tabs and menus
5249 * @return array
5350 * @private

Follow-up revisions

RevisionCommit summaryAuthorDate
r53410Merging UI fixes from trunk; second batch from http://www.mediawiki.org/wiki/......brion18:05, 17 July 2009

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r52944Moved buildNavigationUrls into SkinTemplate from SkinVector which inherits Sk...tparscal20:59, 8 July 2009

Status & tagging log