Form submission handler for custom_block_type_delete_form().
function custom_block_type_delete_form_submit($form, &$form_state) {
$block_type = $form_state['custom_block_type'];
$block_type
->delete();
drupal_set_message(t('Custom block type %label has been deleted.', array(
'%label' => $block_type
->label(),
)));
watchdog('custom_block', 'Custom block type %label has been deleted.', array(
'%label' => $block_type
->label(),
), WATCHDOG_NOTICE);
$form_state['redirect'] = 'admin/structure/custom-blocks';
}