[wp-trac] [WordPress Trac] #22538: 'wp_image_editor_class' vs. 'wp_image_editors'
WordPress Trac
noreply at wordpress.org
Thu Nov 22 18:00:22 UTC 2012
#22538: 'wp_image_editor_class' vs. 'wp_image_editors'
--------------------------+--------------------
Reporter: scribu | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 3.5
Component: Media | Version: trunk
Severity: normal | Resolution:
Keywords: dev-feedback |
--------------------------+--------------------
Comment (by scribu):
> if a plugin developer wants to add or change functionality, he has to
extend both WP_Image_Editor_GD and WP_Image_Editor_Imagick.
You could avoid that duplication by creating a
[http://en.wikipedia.org/wiki/Decorator_pattern decorator] that contains
the image editor instance chosen by WP.
However, that's not possible with the 'wp_image_editor_class' hook. We'd
need something like 'wp_image_editor_instance' instead. Looking into it.
--
Ticket URL: <http://core.trac.wordpress.org/ticket/22538#comment:8>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list