From: Siebrand Mazeland Date: Thu, 5 Dec 2013 13:45:15 +0000 (+0100) Subject: Declare visibility on class properties of GIFMetadataExtractor X-Git-Tag: 1.31.0-rc.0~17737^2~2 X-Git-Url: https://git.cyclocoop.org/%28%28?a=commitdiff_plain;h=bd9254daa8246579f2f0fec1c55f6f44659d777a;p=lhc%2Fweb%2Fwiklou.git Declare visibility on class properties of GIFMetadataExtractor Change-Id: I4338caadaf69471084f3365ba9ce96f652d77374 --- diff --git a/includes/media/GIFMetadataExtractor.php b/includes/media/GIFMetadataExtractor.php index a9b5b91987..f8f744b62c 100644 --- a/includes/media/GIFMetadataExtractor.php +++ b/includes/media/GIFMetadataExtractor.php @@ -32,11 +32,14 @@ * @ingroup Media */ class GIFMetadataExtractor { - static $gif_frame_sep; + /** @var string */ + private static $gifFrameSep; - static $gif_extension_sep; + /** @var string */ + private static $gifExtensionSep; - static $gif_term; + /** @var string */ + private static $gifTerm; const VERSION = 1; @@ -51,9 +54,9 @@ class GIFMetadataExtractor { * @return array */ static function getMetadata( $filename ) { - self::$gif_frame_sep = pack( "C", ord( "," ) ); - self::$gif_extension_sep = pack( "C", ord( "!" ) ); - self::$gif_term = pack( "C", ord( ";" ) ); + self::$gifFrameSep = pack( "C", ord( "," ) ); + self::$gifExtensionSep = pack( "C", ord( "!" ) ); + self::$gifTerm = pack( "C", ord( ";" ) ); $frameCount = 0; $duration = 0.0; @@ -95,7 +98,7 @@ class GIFMetadataExtractor { while ( !feof( $fh ) ) { $buf = fread( $fh, 1 ); - if ( $buf == self::$gif_frame_sep ) { + if ( $buf == self::$gifFrameSep ) { // Found a frame $frameCount++; @@ -110,7 +113,7 @@ class GIFMetadataExtractor { self::readGCT( $fh, $bpp ); fread( $fh, 1 ); self::skipBlock( $fh ); - } elseif ( $buf == self::$gif_extension_sep ) { + } elseif ( $buf == self::$gifExtensionSep ) { $buf = fread( $fh, 1 ); if ( strlen( $buf ) < 1 ) { throw new Exception( "Ran out of input" ); @@ -236,7 +239,7 @@ class GIFMetadataExtractor { } else { self::skipBlock( $fh ); } - } elseif ( $buf == self::$gif_term ) { + } elseif ( $buf == self::$gifTerm ) { break; } else { if ( strlen( $buf ) < 1 ) {