You are here

function media_bulk_upload_forms in D7 Media 7.4

Same name and namespace in other branches
  1. 7.2 modules/media_bulk_upload/media_bulk_upload.module \media_bulk_upload_forms()
  2. 7.3 modules/media_bulk_upload/media_bulk_upload.module \media_bulk_upload_forms()

Implements hook_forms().

File

modules/media_bulk_upload/media_bulk_upload.module, line 184
Primarily Drupal hooks.

Code

function media_bulk_upload_forms($form_id, $args) {
  $forms = array();

  // To support the multiedit form, each form has to have a unique ID.
  // So we name all the forms media_edit_N where the first requested form is
  // media_edit_0, 2nd is media_edit_1, etc.
  module_load_include('inc', 'file_entity', 'file_entity.pages');
  if ($form_id != 'media_edit' && strpos($form_id, 'media_edit') === 0) {
    $forms[$form_id] = array(
      'callback' => 'file_entity_edit',
      'wrapper_callback' => 'media_bulk_upload_prepare_edit_form',
    );
  }
  return $forms;
}