+
+ protected function getThumbForLine( $file ) {
+ global $wgLang;
+
+ if ( $file->allowInlineDisplay() && $file->userCan( File::DELETED_FILE ) && !$file->isDeleted( File::DELETED_FILE ) ) {
+ $params = array(
+ 'width' => '120',
+ 'height' => '120',
+ );
+ $timestamp = wfTimestamp( TS_MW, $file->getTimestamp() );
+
+ $thumbnail = $file->transform( $params );
+ $options = array(
+ 'alt' => wfMsg( 'filehist-thumbtext',
+ $wgLang->timeAndDate( $timestamp, true ),
+ $wgLang->date( $timestamp, true ),
+ $wgLang->time( $timestamp, true ) ),
+ 'file-link' => true,
+ );
+
+ if ( !$thumbnail ) return wfMsgHtml( 'filehist-nothumb' );
+
+ return $thumbnail->toHtml( $options );
+ } else {
+ return wfMsgHtml( 'filehist-nothumb' );
+ }
+ }