From 7ca95e3d32a7dde15fa7f412b070b1d97c14e412 Mon Sep 17 00:00:00 2001 From: Timo Tijhof Date: Wed, 31 Jul 2013 02:31:12 +0200 Subject: [PATCH] VisualEditor.hooks: Sort keys Change-Id: I68f9258f739532ca30d2fdc91e62d6a2f87a5180 --- VisualEditor.hooks.php | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/VisualEditor.hooks.php b/VisualEditor.hooks.php index 37744e849d..668c449350 100644 --- a/VisualEditor.hooks.php +++ b/VisualEditor.hooks.php @@ -125,12 +125,12 @@ class VisualEditorHooks { global $wgStylePath, $wgContLang; $vars['wgVisualEditor'] = array( 'isPageWatched' => $out->getUser()->isWatched( $out->getTitle() ), - 'pageLanguageCode' => $out->getTitle()->getPageLanguage()->getHtmlCode(), - 'pageLanguageDir' => $out->getTitle()->getPageLanguage()->getDir(), // Same as in Linker.php 'magnifyClipIconURL' => $wgStylePath . '/common/images/magnify-clip' . - ( $wgContLang->isRTL() ? '-rtl' : '' ) . '.png' + ( $wgContLang->isRTL() ? '-rtl' : '' ) . '.png', + 'pageLanguageCode' => $out->getTitle()->getPageLanguage()->getHtmlCode(), + 'pageLanguageDir' => $out->getTitle()->getPageLanguage()->getDir(), ); return true; @@ -140,18 +140,21 @@ class VisualEditorHooks { * Adds extra variables to the global config */ public static function onResourceLoaderGetConfigVars( array &$vars ) { - global $wgVisualEditorEnableEventLogging, $wgVisualEditorPluginModules, - $wgVisualEditorEnableExperimentalCode, $wgVisualEditorTabLayout, - $wgVisualEditorDisableForAnons, $wgVisualEditorNamespaces; + global $wgVisualEditorDisableForAnons, + $wgVisualEditorEnableEventLogging, + $wgVisualEditorEnableExperimentalCode, + $wgVisualEditorNamespaces, + $wgVisualEditorPluginModules, + $wgVisualEditorTabLayout; $vars['wgVisualEditorConfig'] = array( - 'enableExperimentalCode' => $wgVisualEditorEnableExperimentalCode, - 'enableEventLogging' => $wgVisualEditorEnableEventLogging, - 'tabLayout' => $wgVisualEditorTabLayout, 'disableForAnons' => $wgVisualEditorDisableForAnons, + 'enableEventLogging' => $wgVisualEditorEnableEventLogging, + 'enableExperimentalCode' => $wgVisualEditorEnableExperimentalCode, 'namespaces' => $wgVisualEditorNamespaces, - 'skins' => self::$supportedSkins, 'pluginModules' => $wgVisualEditorPluginModules, + 'skins' => self::$supportedSkins, + 'tabLayout' => $wgVisualEditorTabLayout, ); return true;