Jdlrobson has uploaded a new change for review.
https://gerrit.wikimedia.org/r/68720
Change subject: Make desktop Minerva mobile Minerva
......................................................................
Make desktop Minerva mobile Minerva
The only difference now being the menus...
Trip balls.
Change-Id: I89716133324244118e0d1bb819bb4e445a698df0
---
M includes/skins/SkinMinerva.php
M includes/skins/SkinMobileBase.php
2 files changed, 3 insertions(+), 8 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/MobileFrontend
refs/changes/20/68720/1
diff --git a/includes/skins/SkinMinerva.php b/includes/skins/SkinMinerva.php
index 9ce50e6..8dd66b4 100644
--- a/includes/skins/SkinMinerva.php
+++ b/includes/skins/SkinMinerva.php
@@ -23,10 +23,12 @@
}
public function prepareData( BaseTemplate $tpl ) {
- global $wgMFEnableSiteNotice;
+ global $wgMFEnableSiteNotice, $wgExtMobileFrontend;
$title = $this->getTitle();
$user = $this->getUser();
$out = $this->getOutput();
+ $html = $wgExtMobileFrontend->DOMParse( $out );
+ $tpl->set( 'bodytext', $html );
if ( $title->isMainPage() ) {
$out->setPageTitle( $user->isLoggedIn() ?
wfMessage(
'mobile-frontend-logged-in-homepage-notification', $user->getName() )->text() :
'' );
diff --git a/includes/skins/SkinMobileBase.php
b/includes/skins/SkinMobileBase.php
index 658eb28..f02655c 100644
--- a/includes/skins/SkinMobileBase.php
+++ b/includes/skins/SkinMobileBase.php
@@ -1,10 +1,6 @@
<?php
class SkinMobileBase extends SkinMinerva {
- /**
- * @var ExtMobileFrontend
- */
- protected $extMobileFrontend;
protected $hookOptions;
/** @var array of classes that should be present on the body tag */
@@ -165,7 +161,6 @@
public function __construct( ExtMobileFrontend $extMobileFrontend ) {
$this->setContext( $extMobileFrontend );
- $this->extMobileFrontend = $extMobileFrontend;
$ctx = MobileContext::singleton();
$this->addPageClass( 'mobile' );
if ( $ctx->isAlphaGroupMember() ) {
@@ -193,12 +188,10 @@
$this->hookOptions = $options;
}
}
- $html = $this->extMobileFrontend->DOMParse( $out );
wfProfileIn( __METHOD__ . '-tpl' );
$tpl = $this->prepareTemplate();
$tpl->set( 'headelement', $out->headElement( $this ) );
- $tpl->set( 'bodytext', $html );
// FIXME: Move to ZeroRatedMobileAccess extension
$tpl->set( 'zeroRatedBanner',
$this->extMobileFrontend->getZeroRatedBanner() );
$notice = '';
--
To view, visit https://gerrit.wikimedia.org/r/68720
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I89716133324244118e0d1bb819bb4e445a698df0
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits