Legoktm has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/236731

Change subject: Generate personal tools before head element
......................................................................

Generate personal tools before head element

So if extensions (or skins I suppose) add things using the PersonalUrls
hook, they will be included properly.

Bug: T111668
Change-Id: I5d024a42421423c5d0c5ebe2123ebdffa5e9c3b2
---
M specials/SpecialContentTranslation.php
1 file changed, 7 insertions(+), 3 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ContentTranslation 
refs/changes/31/236731/1

diff --git a/specials/SpecialContentTranslation.php 
b/specials/SpecialContentTranslation.php
index 7ca8927..e76aa7c 100644
--- a/specials/SpecialContentTranslation.php
+++ b/specials/SpecialContentTranslation.php
@@ -134,6 +134,13 @@
 
                Hooks::run( 'BeforePageDisplay', array( &$out, &$skin ) );
 
+               // T111668: Make sure we generate the personal tools
+               // before we output the head, as extensions may add
+               // things using the PersonalUrls hook.
+               $toolbarList = Html::rawElement( 'ul',
+                               null,
+                               $skin->getPersonalToolsList() );
+
                $out->addHTML( $out->headElement( $skin ) );
                $out->addHTML( Html::element(
                        'noscript',
@@ -141,9 +148,6 @@
                        $this->msg( 'cx-javascript' )->text()
                ) );
                $out->addHtml( MWDebug::getDebugHTML( $this->getContext() ) );
-               $toolbarList = Html::rawElement( 'ul',
-                       null,
-                       $skin->getPersonalToolsList() );
                $out->addHTML( Html::rawElement( 'div',
                        array( 'id' => 'p-personal' ),
                        $toolbarList ) );

-- 
To view, visit https://gerrit.wikimedia.org/r/236731
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I5d024a42421423c5d0c5ebe2123ebdffa5e9c3b2
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ContentTranslation
Gerrit-Branch: master
Gerrit-Owner: Legoktm <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to