You are here

function language_hierarchy_language_list in Language Hierarchy 7

Returns flat list of languages with additional depth information, ordered in manner that is then usable by tablesort

Return value

array() Language list

14 calls to language_hierarchy_language_list()
entity_translation_hierarchy_preprocess_entity_translation_overview in modules/entity_translation_hierarchy/entity_translation_hierarchy.module
Implements hook_preprocess_entity_translation_overview().
i18n_menu_hierarchy_form_i18n_string_translate_page_overview_form_alter in modules/i18n_menu_hierarchy/i18n_menu_hierarchy.module
Implements hook_form_FORM_ID_alter().
i18n_menu_hierarchy_form_menu_edit_item_alter in modules/i18n_menu_hierarchy/i18n_menu_hierarchy.module
Implements hook_form_FORM_ID_alter().
i18n_menu_hierarchy_form_menu_overview_form_alter in modules/i18n_menu_hierarchy/i18n_menu_hierarchy.module
Implements hook_form_FORM_ID_alter().
i18n_menu_hierarchy_item_overview in modules/i18n_menu_hierarchy/i18n_menu_hierarchy.module
Callback for menu translation tab overview.

... See full list

2 string references to 'language_hierarchy_language_list'
language_hierarchy_form_submit in ./language_hierarchy_form.inc
Submit callback for the language_hierarchy_form form.
language_hierarchy_language_add_form_submit_callback in ./language_hierarchy.module
An additional submission callback for the add predefined language form.

File

./language_hierarchy.module, line 428

Code

function language_hierarchy_language_list() {
  $languages =& drupal_static(__FUNCTION__);
  if (empty($languages)) {
    $root_languages = language_hierarchy_get_root_languages();
    foreach ($root_languages as $langcode => $language) {
      $language->depth = count(language_hierarchy_get_ancestors($langcode));
      $languages[$langcode] = $language;
      _language_hierarchy_language_list_descendants($langcode, $languages);
    }
  }
  return $languages;
}