You are here

function swftools_menu in SWF Tools 5

Same name and namespace in other branches
  1. 6.3 swftools.module \swftools_menu()
  2. 6 swftools.module \swftools_menu()
  3. 6.2 swftools.module \swftools_menu()

Implementation of hook_menu().

File

./swftools.module, line 33

Code

function swftools_menu($may_cache) {
  if (variable_get('swftools_always_add_js', FALSE)) {
    swftools_push_js();
  }
  $items = array();
  $swf_admin = user_access('administer flash');
  if ($may_cache) {
    $items[] = array(
      'path' => 'admin/media/swf',
      'title' => t('SWF Tools'),
      'callback' => 'swftools_admin',
      'access' => $swf_admin,
      'position' => 'left',
      'description' => t('SWF Tools provide integration with Macromedia Flash related methods and tools like Video Players, MP3 Players and Image Viewers'),
    );
    $items[] = array(
      'path' => 'admin/media/swf/embed',
      'title' => t('Embedding settings'),
      'description' => t('Settings specific to Flash embedding. Object and embed attributes can be set here.'),
      'weight' => -2,
    );
    $items[] = array(
      'path' => 'admin/media/swf/handling',
      'title' => t('File handling'),
      'description' => t('Flash players and handling for various file types.'),
      'weight' => -1,
    );
    $items = array_merge($items, genericplayers_menu(TRUE));
  }
  return $items;
}