Merge "Remove deprecated function mw.util.toggleToc"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Thu, 17 Apr 2014 15:32:28 +0000 (15:32 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Thu, 17 Apr 2014 15:32:28 +0000 (15:32 +0000)
1  2 
RELEASE-NOTES-1.24
includes/parser/Parser.php
resources/Resources.php

diff --combined RELEASE-NOTES-1.24
@@@ -13,11 -13,6 +13,11 @@@ production
  === New features in 1.24 ===
  
  === Bug fixes in 1.24 ===
 +* (bug 62258) A bug was fixed in File::getUnscaledThumb when a height
 +  restriction was present in the parameters.  Images with both the "frame"
 +  option and a size specification set will now always ignore the provided
 +  size and display an unscaled image, as the documentation has always
 +  claimed it would.
  
  === Web API changes in 1.24 ===
  
@@@ -29,6 -24,7 +29,7 @@@ changes to languages because of Bugzill
  
  === Other changes in 1.24 ===
  * The deprecated jquery.delayedBind ResourceLoader module was removed.
+ * The deprecated function mw.util.toggleToc was removed.
  
  == Compatibility ==
  
@@@ -710,7 -710,7 +710,7 @@@ class Parser 
         * @param $t Title
         */
        function setTitle( $t ) {
 -              if ( !$t || $t instanceof FakeTitle ) {
 +              if ( !$t ) {
                        $t = Title::newFromText( 'NO TITLE' );
                }
  
                        $toc = Linker::tocList( $toc, $this->mOptions->getUserLangObj() );
                        $this->mOutput->setTOCHTML( $toc );
                        $toc = self::TOC_START . $toc . self::TOC_END;
+                       $this->mOutput->addModules( 'mediawiki.toc' );
                }
  
                if ( $isMain ) {
                $caption = '';
                $params = array( 'frame' => array(), 'handler' => array(),
                        'horizAlign' => array(), 'vertAlign' => array() );
 +              $seenformat = false;
                foreach ( $parts as $part ) {
                        $part = trim( $part );
                        list( $magicName, $value ) = $mwArray->matchVariableStartToEnd( $part );
                                                                }
                                                        }
                                                        break;
 +                                              case 'frameless':
 +                                              case 'framed':
 +                                              case 'thumbnail':
 +                                                      // use first appearing option, discard others.
 +                                                      $validated = ! $seenformat;
 +                                                      $seenformat = true;
 +                                                      break;
                                                default:
                                                        # Most other things appear to be empty or numeric...
                                                        $validated = ( $value === false || is_numeric( trim( $value ) ) );
diff --combined resources/Resources.php
@@@ -691,12 -691,11 +691,12 @@@ return array
                        'pt-br' => 'resources/lib/moment/lang/pt-br.js',
                        'pt' => 'resources/lib/moment/lang/pt.js',
                        'ro' => 'resources/lib/moment/lang/ro.js',
 -                      'rs' => 'resources/lib/moment/lang/rs.js',
                        'ru' => 'resources/lib/moment/lang/ru.js',
                        'sk' => 'resources/lib/moment/lang/sk.js',
                        'sl' => 'resources/lib/moment/lang/sl.js',
                        'sq' => 'resources/lib/moment/lang/sq.js',
 +                      'sr-el' => 'resources/lib/moment/lang/sr.js',
 +                      'sr-ec' => 'resources/lib/moment/lang/sr-cyr.js',
                        'sv' => 'resources/lib/moment/lang/sv.js',
                        'ta' => 'resources/lib/moment/lang/ta.js',
                        'th' => 'resources/lib/moment/lang/th.js',
                        'tzm' => 'resources/lib/moment/lang/tzm.js',
                        'uk' => 'resources/lib/moment/lang/uk.js',
                        'uz' => 'resources/lib/moment/lang/uz.js',
 -                      'vn' => 'resources/lib/moment/lang/vn.js',
 +                      'vi' => 'resources/lib/moment/lang/vi.js',
                        'zh-cn' => 'resources/lib/moment/lang/zh-cn.js',
                        'zh-tw' => 'resources/lib/moment/lang/zh-tw.js',
                ),
                        'jquery.client',
                        'jquery.mwExtension',
                        'mediawiki.notify',
-                       'mediawiki.toc',
                ),
                'position' => 'top', // For $wgPreloadJavaScriptMwUtil
                'targets' => array( 'desktop', 'mobile' ),