Initial support for webfonts in MobileFrontend

Written in pair-programming with Ryan Kaldari.

This adds a version of webfonts initialization that is stripped
of any smart features. It only loads the basic jquery.webfonts
library and the fonts repository in a way that is usable
with the MobileFronted extension.

It is completely disabled by default.

It can be enabled by setting
$wgULSMobileWebfontsEnabled = true;
and even then it will only be enabled for users
who opted in for the mobile beta mode.

Change-Id: I488e411232a1192bbf46ae5675c701366bda9a3e
This commit is contained in:
Amir E. Aharoni
2013-09-27 16:42:37 -07:00
parent 78152b95c0
commit fd885d9881
4 changed files with 84 additions and 0 deletions

View File

@@ -104,6 +104,12 @@ $wgULSLanguageDetection = true;
*/
$wgULSIMEEnabled = true;
/**
* Set whether webfont support is loaded within the mobile interface (via the
* MobileFrontend extension).
*/
$wgULSMobileWebfontsEnabled = false;
/**
* The location and the form of the language selection trigger.
* The possible values are:
@@ -184,6 +190,7 @@ $wgAPIModules['ulslocalization'] = 'ApiULSLocalization';
$wgHooks['UserGetLanguageObject'][] = 'UniversalLanguageSelectorHooks::getLanguage';
$wgHooks['SkinTemplateOutputPageBeforeExec'][] =
'UniversalLanguageSelectorHooks::onSkinTemplateOutputPageBeforeExec';
$wgHooks['EnterMobileMode'][] = 'UniversalLanguageSelectorHooks::onEnterMobileMode';
$wgDefaultUserOptions['uls-preferences'] = '';
$wgHooks['GetPreferences'][] = 'UniversalLanguageSelectorHooks::onGetPreferences';