You are here

public function video_preset::getAllPresets in Video 6.4

2 calls to video_preset::getAllPresets()
video_preset::admin_settings in includes/preset.inc
video_preset::properties in includes/preset.inc

File

includes/preset.inc, line 44

Class

video_preset

Code

public function getAllPresets() {
  $presets = array();
  $files = array();
  foreach (module_list() as $module) {
    $module_files = file_scan_directory(drupal_get_path('module', $module) . '/video_preset', '^.*\\.inc$');
    $files = array_merge($files, $module_files);
  }
  foreach ($files as $file) {
    require_once $file->filename;
    $preset = new $file->name();
    $presets[$preset
      ->get_value()] = $preset;
  }
  ksort($presets);
  return $presets;
}