diff options
author | Dries Buytaert <dries@buytaert.net> | 2010-09-11 01:54:43 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2010-09-11 01:54:43 +0000 |
commit | 8e93aade95aaa505bd051f5e9710a9361ec77978 (patch) | |
tree | bfc30bc9f8d11800bf011a9f9b70b773f86ff91d /modules/image/image.api.php | |
parent | dde18582493270fadd9aefa4d5569faa9cc6f269 (diff) | |
download | brdo-8e93aade95aaa505bd051f5e9710a9361ec77978.tar.gz brdo-8e93aade95aaa505bd051f5e9710a9361ec77978.tar.bz2 |
- Patch #875326 by effulgentsia: add hook_image_effect_info_alter().
Diffstat (limited to 'modules/image/image.api.php')
-rw-r--r-- | modules/image/image.api.php | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/modules/image/image.api.php b/modules/image/image.api.php index 6f1ff37ac..298a3beb9 100644 --- a/modules/image/image.api.php +++ b/modules/image/image.api.php @@ -29,6 +29,8 @@ * $form array providing a configuration form for this image effect. * - "summary theme": (optional) The name of a theme function that will output * a summary of this image effect's configuration. + * + * @see hook_image_effect_info_alter() */ function hook_image_effect_info() { $effects = array(); @@ -45,6 +47,20 @@ function hook_image_effect_info() { } /** + * Alter the information provided in hook_image_effect_info(). + * + * @param $effects + * The array of image effects, keyed on the machine-readable effect name. + * + * @see hook_image_effect_info() + */ +function hook_image_effect_info_alter(&$effects) { + // Override the Image module's crop effect with more options. + $effect['image_crop']['effect callback'] = 'mymodule_crop_effect'; + $effect['image_crop']['form callback'] = 'mymodule_crop_form'; +} + +/** * Respond to image style updating. * * This hook enables modules to update settings that might be affected by |