function alpha_get_theme

cis7 alpha.inc alpha_get_theme()
cle7 alpha.inc alpha_get_theme()
elmsmedia7 alpha.inc alpha_get_theme()
icor7 alpha.inc alpha_get_theme()
meedjum_blog7 alpha.inc alpha_get_theme()
mooc7 alpha.inc alpha_get_theme()

Returns the theme container object for the current theme.

Return value

An object representing the current theme.

26 calls to alpha_get_theme()
alpha_alpha_page_structure_alter in sites/all/themes/ulmus/omega/alpha/template.php
Implements hook_alpha_page_alter().
alpha_alpha_preprocess_html in sites/all/themes/ulmus/omega/alpha/template.php
Implements hook_preprocess_html().
alpha_alpha_preprocess_page in sites/all/themes/ulmus/omega/alpha/template.php
Implements hook_preprocess_page().
alpha_alpha_process_page in sites/all/themes/ulmus/omega/alpha/template.php
Implements hook_process_page().
alpha_css_active in sites/all/themes/ulmus/omega/alpha/includes/alpha.inc
Checks wether a custom CSS file is active in the current theme.

... See full list

File

sites/all/themes/ulmus/omega/alpha/includes/alpha.inc, line 216
Helper functions for the Alpha base theme.

Code

function alpha_get_theme() {
  $container = &drupal_static(__FUNCTION__);

  $key = $theme = $GLOBALS['theme_key'];
  $delta = NULL;

  if (module_exists('delta') && $delta = delta_get_current($theme)) {
    $key .= ':' . $delta;
  }

  if (!isset($container[$key])) {
    foreach (array_keys(alpha_theme_trail($theme)) as $item) {
      if (class_exists($item . '_theme_container')) {
        $class = $item . '_theme_container';
      }
    }

    if (isset($class)) {
      $container[$key] = new $class($theme, $delta);
    }
  }

  return $container[$key];
}