Update ImagePage to use HiDPI
Changed processResponsiveImages method in Linker class from protected to public so that it may be used in the ImagePage class. called the method in the openShowImage method to generate the srcset. Bug: 56969 Change-Id: I2494ce98ba1a32d5a963b53482929de9abb048fd
This commit is contained in:
parent
1d0b2e03eb
commit
4563a42e0d
2 changed files with 2 additions and 1 deletions
|
|
@ -415,6 +415,7 @@ class ImagePage extends Article {
|
|||
$params['width'] = $width;
|
||||
$params['height'] = $height;
|
||||
$thumbnail = $this->displayImg->transform( $params );
|
||||
Linker::processResponsiveImages( $this->displayImg, $thumbnail, $params );
|
||||
|
||||
$anchorclose = Html::rawElement( 'div', array( 'class' => 'mw-filepage-resolutioninfo' ), $msgsmall );
|
||||
|
||||
|
|
|
|||
|
|
@ -902,7 +902,7 @@ class Linker {
|
|||
* @param MediaOutput $thumb
|
||||
* @param array $hp image parameters
|
||||
*/
|
||||
protected static function processResponsiveImages( $file, $thumb, $hp ) {
|
||||
public static function processResponsiveImages( $file, $thumb, $hp ) {
|
||||
global $wgResponsiveImages;
|
||||
if ( $wgResponsiveImages ) {
|
||||
$hp15 = $hp;
|
||||
|
|
|
|||
Loading…
Reference in a new issue