You are here

function multiupload_filefield_widget_element_info in Multiupload Filefield Widget 7

Implements hook_element_info().

File

./multiupload_filefield_widget.module, line 12

Code

function multiupload_filefield_widget_element_info() {
  $file_path = drupal_get_path('module', 'file');
  $mfw_path = drupal_get_path('module', 'multiupload_filefield_widget');
  $types['mfw_managed_file'] = array(
    '#input' => TRUE,
    '#process' => array(
      'mfw_managed_file_process',
    ),
    '#value_callback' => 'mfw_managed_file_value',
    '#element_validate' => array(
      'file_managed_file_validate',
    ),
    '#pre_render' => array(
      'file_managed_file_pre_render',
    ),
    '#theme' => 'file_managed_file',
    '#theme_wrappers' => array(
      'form_element',
    ),
    '#progress_indicator' => 'throbber',
    '#progress_message' => NULL,
    '#upload_validators' => array(),
    '#upload_location' => NULL,
    '#extended' => FALSE,
    '#size' => 22,
    '#attached' => array(
      'css' => array(
        $file_path . '/file.css',
      ),
      'js' => array(
        $mfw_path . '/mfw.js',
        $file_path . '/file.js',
      ),
    ),
  );
  return $types;
}