function ctools_content_type_new
Create callback for creating a new CTools custom content type.
This ensures we get proper defaults from the plugin for its settings.
1 string reference to 'ctools_content_type_new'
- ctools_custom_content_schema_1 in ctools_custom_content/
ctools_custom_content.install
File
-
ctools_custom_content/
ctools_custom_content.module, line 64
Code
function ctools_content_type_new($set_defaults) {
$item = ctools_export_new_object('ctools_custom_content', $set_defaults);
ctools_include('content');
$plugin = ctools_get_content_type('custom');
$item->settings = ctools_content_get_defaults($plugin, array());
return $item;
}