+ $msgbig = wfMsgHtml( 'show-big-image' );
+ if ( $this->displayImg->getRepo()->canTransformVia404() ) {
+ $thumbSizes = $wgImageLimits;
+ } else {
+ # Creating thumb links triggers thumbnail generation.
+ # Just generate the thumb for the current users prefs.
+ $thumbOption = $user->getOption( 'thumbsize' );
+ $thumbSizes = array( isset( $wgImageLimits[$thumbOption] )
+ ? $wgImageLimits[$thumbOption]
+ : $wgImageLimits[User::getDefaultOption( 'thumbsize' )] );
+ }
+ # Generate thumbnails or thumbnail links as needed...