Refactor ime lazy loading
* Do not load anything unless input field is focused * Split the setup function to smaller functions * Introduce $wgULSImeSelectors to allow configuration and avoid duplication of selectors in two places. Change-Id: If5a476e66681dde9f0b72f619d35ddf6255246ac
This commit is contained in:
committed by
Santhosh Thottingal
parent
39faf1a72e
commit
193f69b017
@@ -256,8 +256,8 @@ class UniversalLanguageSelectorHooks {
|
||||
*/
|
||||
public static function addConfig( &$vars ) {
|
||||
global $wgULSGeoService, $wgULSIMEEnabled, $wgULSPosition, $wgULSNoWebfontsSelectors,
|
||||
$wgULSAnonCanChangeLanguage, $wgULSEventLogging, $wgULSNoImeSelectors,
|
||||
$wgULSFontRepositoryBasePath, $wgExtensionAssetsPath;
|
||||
$wgULSAnonCanChangeLanguage, $wgULSEventLogging, $wgULSImeSelectors,
|
||||
$wgULSNoImeSelectors, $wgULSFontRepositoryBasePath, $wgExtensionAssetsPath;
|
||||
|
||||
// Place constant stuff here (not depending on request context)
|
||||
if ( is_string( $wgULSGeoService ) ) {
|
||||
@@ -267,6 +267,7 @@ class UniversalLanguageSelectorHooks {
|
||||
$vars['wgULSPosition'] = $wgULSPosition;
|
||||
$vars['wgULSAnonCanChangeLanguage'] = $wgULSAnonCanChangeLanguage;
|
||||
$vars['wgULSEventLogging'] = $wgULSEventLogging;
|
||||
$vars['wgULSImeSelectors'] = $wgULSImeSelectors;
|
||||
$vars['wgULSNoImeSelectors'] = $wgULSNoImeSelectors;
|
||||
$vars['wgULSNoWebfontsSelectors'] = $wgULSNoWebfontsSelectors;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user