X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fmedia%2FExifBitmap.php;h=0e10abb9f9329ee7c8942e3c9826c3155b2231a4;hb=c9be16a35596ff369bb5f700c20ae8dc2f7def48;hp=cf4b12ef3ba646a1e8d0d7c927184e65a1d94bd1;hpb=c6d01b6e43cd9aefe5616795dfafea8b9675515f;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/media/ExifBitmap.php b/includes/media/ExifBitmap.php index cf4b12ef3b..0e10abb9f9 100644 --- a/includes/media/ExifBitmap.php +++ b/includes/media/ExifBitmap.php @@ -242,36 +242,4 @@ class ExifBitmapHandler extends BitmapHandler { return 0; } - - /** - * Get useful response headers for GET/HEAD requests for a file with the given metadata - * @param $metadata Array Contains this handler's unserialized getMetadata() for a file - * @return Array - */ - public function getContentHeaders( $metadata ) { - if ( !isset( $metadata['Width'] ) || !isset( $metadata['Height'] ) ) { - return []; - } - - $dimensionsMetadata = []; - - if ( $this->autoRotateEnabled() && isset( $metadata['Orientation'] ) ) { - switch ( $metadata['Orientation'] ) { - case 5: // CCW flipped - case 6: // CCW - case 7: // CW flipped - case 8: // CW - $dimensionsMetadata['width'] = $metadata['Height']; - $dimensionsMetadata['height'] = $metadata['Width']; - break; - } - } - - if ( !isset( $dimensionsMetadata['width'] ) ) { - $dimensionsMetadata['width'] = $metadata['Width']; - $dimensionsMetadata['height'] = $metadata['Height']; - } - - return parent::getContentHeaders( $dimensionsMetadata ); - } }