You are here

function _language_sections_context in Language Sections 7.2

Same name and namespace in other branches
  1. 6.2 language_sections.module \_language_sections_context()
3 calls to _language_sections_context()
_filter_language_sections in ./language_sections.module
_language_sections_build_triggers in ./language_sections.module
_language_sections_settings in ./language_sections.module

File

./language_sections.module, line 232

Code

function _language_sections_context($topic = FALSE) {
  $context = array(
    // Elements of $language that we use as possible triggers.
    'elements' => array(
      'language',
      'name',
      'prefix',
    ),
    // "Special" triggers and descriptions.
    'specials' => array(
      'all' => t('all languages'),
      'other' => t('other languages'),
    ),
    'match_types' => array(
      'current_language' => 1,
      'all_languages' => 2,
      'other_languages' => 3,
    ),
  );
  return $topic ? $context[$topic] : $context;
}