Index: trunk/phase3/includes/Linker.php |
— | — | @@ -531,6 +531,12 @@ |
532 | 532 | // Use image dimensions, don't scale |
533 | 533 | $thumb = $img->getUnscaledThumb( $page ); |
534 | 534 | } else { |
| 535 | + # Do not present an image bigger than the source, for bitmap-style images |
| 536 | + # This is a hack to maintain compatibility with arbitrary pre-1.10 behaviour |
| 537 | + $srcWidth = $img->getWidth( $page ); |
| 538 | + if ( $srcWidth && !$img->mustRender() && $params['width'] > $srcWidth ) { |
| 539 | + $params['width'] = $srcWidth; |
| 540 | + } |
535 | 541 | $thumb = $img->transform( $params ); |
536 | 542 | } |
537 | 543 | |