/**
* Method to get the list of template chrome style options
* grouped by template.
*
* @return array The field option objects as a nested array in groups.
*
* @since 3.0
*/
protected function getGroups()
{
$groups = array();
// Add Module Style Field
$tmp = '---' . Text::_('JLIB_FORM_VALUE_FROM_TEMPLATE') . '---';
$groups[$tmp][] = HTMLHelper::_('select.option', '0', Text::_('JLIB_FORM_VALUE_INHERITED'));
$templateStyles = $this->getTemplateModuleStyles();
// Create one new option object for each available style, grouped by templates
foreach ($templateStyles as $template => $styles) {
$template = ucfirst($template);
$groups[$template] = array();
foreach ($styles as $style) {
$tmp = HTMLHelper::_('select.option', $template . '-' . $style, $style);
$groups[$template][] = $tmp;
}
}
reset($groups);
return $groups;
}