Merge "Fix positioning of jQuery.tipsy tooltip arrows"
[lhc/web/wiklou.git] / includes / media / MediaHandler.php
index 3a59996..bad1468 100644 (file)
@@ -180,7 +180,7 @@ abstract class MediaHandler {
        function convertMetadataVersion( $metadata, $version = 1 ) {
                if ( !is_array( $metadata ) ) {
 
-                       //unserialize to keep return parameter consistent.
+                       // unserialize to keep return parameter consistent.
                        MediaWiki\suppressWarnings();
                        $ret = unserialize( $metadata );
                        MediaWiki\restoreWarnings();
@@ -373,7 +373,7 @@ abstract class MediaHandler {
         * @param File $file
         * @return bool
         */
-       function pageCount( $file ) {
+       function pageCount( File $file ) {
                return false;
        }
 
@@ -434,7 +434,7 @@ abstract class MediaHandler {
         * @param int $page What page to get dimensions of
         * @return array|bool
         */
-       function getPageDimensions( $image, $page ) {
+       function getPageDimensions( File $image, $page ) {
                $gis = $this->getImageSize( $image, $image->getLocalRefPath() );
                if ( $gis ) {
                        return array(
@@ -454,7 +454,7 @@ abstract class MediaHandler {
         * @return bool|string Page text or false when no text found or if
         *   unsupported.
         */
-       function getPageText( $image, $page ) {
+       function getPageText( File $image, $page ) {
                return false;
        }
 
@@ -866,14 +866,21 @@ abstract class MediaHandler {
         * Gets configuration for the file warning message. Return value of
         * the following structure:
         *   array(
-        *     'module' => 'example.filewarning.messages', // Required, module with messages loaded for the client
-        *     'messages' => array( // Required, array of names of messages
-        *       'main' => 'example-filewarning-main', // Required, main warning message
-        *       'header' => 'example-filewarning-header', // Optional, header for warning dialog
-        *       'footer' => 'example-filewarning-footer', // Optional, footer for warning dialog
-        *       'info' => 'example-filewarning-info', // Optional, text for more-information link (see below)
+        *     // Required, module with messages loaded for the client
+        *     'module' => 'example.filewarning.messages',
+        *     // Required, array of names of messages
+        *     'messages' => array(
+        *       // Required, main warning message
+        *       'main' => 'example-filewarning-main',
+        *       // Optional, header for warning dialog
+        *       'header' => 'example-filewarning-header',
+        *       // Optional, footer for warning dialog
+        *       'footer' => 'example-filewarning-footer',
+        *       // Optional, text for more-information link (see below)
+        *       'info' => 'example-filewarning-info',
         *     ),
-        *     'link' => 'http://example.com', // Optional, link for more information
+        *     // Optional, link for more information
+        *     'link' => 'http://example.com',
         *   )
         *
         * Returns null if no warning is necessary.