From: Daniel Friesen Date: Sat, 30 Apr 2011 12:04:00 +0000 (+0000) Subject: Use a reversed magnify image for framed image thumbnails when on a RTL wiki. X-Git-Tag: 1.31.0-rc.0~30497 X-Git-Url: https://git.cyclocoop.org/%242?a=commitdiff_plain;h=8ae8bd5a989a43e87ced8e3d1afed7d83b90c91a;p=lhc%2Fweb%2Fwiklou.git Use a reversed magnify image for framed image thumbnails when on a RTL wiki. --- diff --git a/includes/Linker.php b/includes/Linker.php index 2274ff54bb..61d8b83850 100644 --- a/includes/Linker.php +++ b/includes/Linker.php @@ -629,7 +629,7 @@ class Linker { static function makeThumbLink2( Title $title, $file, $frameParams = array(), $handlerParams = array(), $time = false, $query = "" ) { - global $wgStylePath; + global $wgStylePath, $wgContLang; $exists = $file && $file->exists(); # Shortcuts @@ -707,11 +707,16 @@ class Linker { if ( isset( $fp['framed'] ) ) { $zoomIcon = ""; } else { - $zoomIcon = '
' . - '' . - '
'; + $zoomIcon = Html::rawElement( 'div', array( 'class' => 'magnify' ), + Html::rawElement( 'a', array( + 'href' => $url, + 'class' => 'internal', + 'title' => wfMsg( 'thumbnail-more' ) ), + Html::element( 'img', array( + 'src' => $wgStylePath . '/common/images/magnify-clip' . ( $wgContLang->isRTL() ? '-rtl' : '' ) . '.png', + 'width' => 15, + 'height' => 11, + 'alt' => "" ) ) ) ); } } $s .= '
' . $zoomIcon . $fp['caption'] . "
"; diff --git a/skins/common/images/magnify-clip-rtl.png b/skins/common/images/magnify-clip-rtl.png new file mode 100644 index 0000000000..8398a82c9e Binary files /dev/null and b/skins/common/images/magnify-clip-rtl.png differ