function panels_ipe_change_to_default in Panelizer 7.3
Submit handler to save the panelizer default instead of customizing the entity.
2 string references to 'panels_ipe_change_to_default'
- panelizer_form_panels_change_layout_alter in ./
panelizer.module - Implements hook_form_FORM_ID_alter() for panels_change_layout().
- panelizer_form_panels_ipe_edit_control_form_alter in ./
panelizer.module - Implements hook_form_FORM_ID_alter() for panels_ipe_edit_control_form().
File
- ./
panelizer.module, line 1998 - The Panelizer module attaches panels to entities, providing default panels and allowing each panel to be configured independently by privileged users.
Code
function panels_ipe_change_to_default($form, &$form_state) {
// Change the cache key so that it saves to the default instead of the
// entity. This works because we're actually editing the original display
// anyway, and everything else keys off the cache key.
$form_state['display']->swap_cache_key = $form_state['triggering_element']['#cache_key'];
}