You are here

function manualcrop_form_image_effect_delete_form_alter in Manual Crop 7

Implements hook_form_FORM_ID_alter().

File

./manualcrop.admin.inc, line 451
Admin functionality for the Manual Crop module.

Code

function manualcrop_form_image_effect_delete_form_alter(&$form, &$form_state) {
  if (!is_array($form['#submit'])) {
    $form['#submit'] = array(
      'image_effect_delete_form_submit',
    );
  }
  if (_manualcrop_is_own_effect($form_state['image_effect'], TRUE)) {

    // Submit handler to cleanup the crop selections.
    array_unshift($form['#submit'], 'manualcrop_image_effect_delete_form_submit');
  }
}