| 1 | diff --git wp-admin/includes/image-edit.php wp-admin/includes/image-edit.php |
|---|
| 2 | index f390b5e..0b06926 100644 |
|---|
| 3 | --- wp-includes/class-wp-image-editor-gd.php |
|---|
| 4 | +++ wp-includes/class-wp-image-editor-gd.php |
|---|
| 5 | @@ -32,7 +32,7 @@ class WP_Image_Editor_GD extends WP_Image_Editor { |
|---|
| 6 | * |
|---|
| 7 | * @return boolean |
|---|
| 8 | */ |
|---|
| 9 | - public static function test() { |
|---|
| 10 | + public function test() { |
|---|
| 11 | if ( ! extension_loaded('gd') || ! function_exists('gd_info') ) |
|---|
| 12 | return false; |
|---|
| 13 | |
|---|
| 14 | @@ -99,7 +99,7 @@ class WP_Image_Editor_GD extends WP_Image_Editor { |
|---|
| 15 | * @param string $mime_type |
|---|
| 16 | * @return boolean |
|---|
| 17 | */ |
|---|
| 18 | - public static function supports_mime_type( $mime_type ) { |
|---|
| 19 | + public function supports_mime_type( $mime_type ) { |
|---|
| 20 | $allowed_mime_types = array( 'image/gif', 'image/png', 'image/jpeg' ); |
|---|
| 21 | |
|---|
| 22 | return in_array( $mime_type, $allowed_mime_types ); |
|---|
| 23 | diff --git wp-includes/class-wp-image-editor-imagick.php wp-includes/class-wp-image-editor-imagick.php |
|---|
| 24 | index 3e35775..7954206 100644 |
|---|
| 25 | --- wp-includes/class-wp-image-editor-imagick.php |
|---|
| 26 | +++ wp-includes/class-wp-image-editor-imagick.php |
|---|
| 27 | @@ -33,7 +33,7 @@ class WP_Image_Editor_Imagick extends WP_Image_Editor { |
|---|
| 28 | * |
|---|
| 29 | * @return boolean |
|---|
| 30 | */ |
|---|
| 31 | - public static function test() { |
|---|
| 32 | + public function test() { |
|---|
| 33 | if ( ! extension_loaded( 'imagick' ) ) |
|---|
| 34 | return false; |
|---|
| 35 | |
|---|
| 36 | @@ -143,7 +143,7 @@ class WP_Image_Editor_Imagick extends WP_Image_Editor { |
|---|
| 37 | * @param string $mime_type |
|---|
| 38 | * @return boolean |
|---|
| 39 | */ |
|---|
| 40 | - public static function supports_mime_type( $mime_type ) { |
|---|
| 41 | + public function supports_mime_type( $mime_type ) { |
|---|
| 42 | if ( ! $mime_type ) |
|---|
| 43 | return false; |
|---|
| 44 | |
|---|
| 45 | diff --git wp-includes/class-wp-image-editor.php wp-includes/class-wp-image-editor.php |
|---|
| 46 | index 27df919..83c6b94 100644 |
|---|
| 47 | --- wp-includes/class-wp-image-editor.php |
|---|
| 48 | +++ wp-includes/class-wp-image-editor.php |
|---|
| 49 | @@ -76,9 +76,9 @@ abstract class WP_Image_Editor { |
|---|
| 50 | return self::$implementation; |
|---|
| 51 | } |
|---|
| 52 | |
|---|
| 53 | - abstract public static function test(); // returns bool |
|---|
| 54 | + abstract public function test(); // returns bool |
|---|
| 55 | abstract protected function load(); // returns bool|WP_Error |
|---|
| 56 | - abstract public static function supports_mime_type( $mime_type ); // returns bool |
|---|
| 57 | + abstract public function supports_mime_type( $mime_type ); // returns bool |
|---|
| 58 | abstract public function resize( $max_w, $max_h, $crop = false ); |
|---|
| 59 | abstract public function multi_resize( $sizes ); |
|---|
| 60 | abstract public function crop( $src_x, $src_y, $src_w, $src_h, $dst_w = null, $dst_h = null, $src_abs = false ); |
|---|