protected function context_layouts_reaction_block::get_layout_options in Context 7.3
Same name and namespace in other branches
- 6.3 context_layouts/plugins/context_layouts_reaction_block.inc \context_layouts_reaction_block::get_layout_options()
- 6 context_layouts/plugins/context_layouts_reaction_block.inc \context_layouts_reaction_block::get_layout_options()
Get layout options for the given theme.
2 calls to context_layouts_reaction_block::get_layout_options()
- context_layouts_reaction_block::editor_form in context_layouts/
plugins/ context_layouts_reaction_block.inc - Override of editor form.
- context_layouts_reaction_block::options_form in context_layouts/
plugins/ context_layouts_reaction_block.inc - Override of options form.
File
- context_layouts/
plugins/ context_layouts_reaction_block.inc, line 179
Class
Code
protected function get_layout_options($theme_key = NULL) {
$theme_key = !isset($theme_key) ? variable_get('theme_default', 'garland') : $theme_key;
$layouts = context_layouts_get_layouts($theme_key);
$layout_options = array();
if (!empty($layouts)) {
foreach ($layouts as $layout => $info) {
$layout_options[$layout] = isset($info['name']) ? $info['name'] : $layout_options;
}
}
return $layout_options;
}