function panels_panel_context_edit_move in Panels 6.3
Same name and namespace in other branches
- 7.3 plugins/task_handlers/panel_context.inc \panels_panel_context_edit_move()
When a layout is changed, the user is given the opportunity to move content.
1 string reference to 'panels_panel_context_edit_move'
- panel_context.inc in plugins/
task_handlers/ panel_context.inc - This is the task handler plugin to handle attaching a panel to any task that advertises itself as a 'context' type, which all of the basic page tasks provided by page_manager.module do by default.
File
- plugins/
task_handlers/ panel_context.inc, line 626 - This is the task handler plugin to handle attaching a panel to any task that advertises itself as a 'context' type, which all of the basic page tasks provided by page_manager.module do by default.
Code
function panels_panel_context_edit_move(&$form, &$form_state) {
$form_state['display'] =& panels_panel_context_get_display($form_state['handler']);
$form_state['layout'] = $form_state['handler']->conf['temp_layout'];
ctools_include('common', 'panels');
ctools_include('display-layout', 'panels');
ctools_include('plugins', 'panels');
// Tell the Panels form not to display buttons.
$form_state['no buttons'] = TRUE;
// Change the #id of the form so the CSS applies properly.
$form = array_merge($form, panels_change_layout($form_state));
// Change the 'back' button to just go directly to the previous form
// $task_id = $form_state['task']['name'];
// $handler_id = $form_state['handler']->handler;
// $name = $form_state['handler']->name;
// This form is outside the normal wizard list, so we need to specify the
// previous/next forms.
$form['buttons']['previous']['#next'] = 'layout';
$form['buttons']['next']['#next'] = 'content';
$form_state['form_info']['return path'] = page_manager_edit_url($form_state['page']->task_name, array(
'handlers',
$form_state['handler_id'],
'content',
));
}