- for extensions also trying an extension-specific template-name

- fixed not correct set template after a type change
This commit is contained in:
Ralf Becker 2006-10-05 08:49:09 +00:00
parent f3ea79899e
commit c1b1453108

View File

@ -1189,6 +1189,10 @@
$msg .= $this->column_actions($action,$parent,$child_id);
break;
case '': // reload, eg. by changing the type
$widget = $content['cell'];
break;
default:
// all menu's are (only) working on the parent, referencing widget is unnecessary
// and gives unexpected results, if parent is changed (eg. content gets copied)
@ -1310,7 +1314,10 @@
$editor =& new etemplate('etemplate.editor.widget');
$type_tmpl =& new etemplate;
if ($type_tmpl->read('etemplate.editor.widget.'.$widget['type']))
list($ext_type) = explode('-',$widget['type']);
if ($type_tmpl->read('etemplate.editor.widget.'.$widget['type']) ||
$type_tmpl->read('etemplate.editor.widget.'.$ext_type))
{
$editor->set_cell_attribute('etemplate.editor.widget.generic','obj',$type_tmpl);
}