function panels_display::add_pane in Panels 8.3
Same name and namespace in other branches
- 5.2 panels.module \panels_display::add_pane()
- 6.3 panels.module \panels_display::add_pane()
- 6.2 panels.module \panels_display::add_pane()
- 7.3 panels.module \panels_display::add_pane()
1 call to panels_display::add_pane()
File
- ./
panels.module, line 404 - panels.module
Class
- panels_display
- Forms the basis of a panel display
Code
function add_pane(&$pane, $location = NULL) {
// If no location specified, use what's set in the pane.
if (empty($location)) {
$location = $pane->panel;
}
else {
$pane->panel = $location;
}
// Generate a permanent uuid for this pane, and use
// it as a temporary pid.
$pane->uuid = ctools_uuid_generate();
$pane->pid = 'new-' . $pane->uuid;
// Add the pane to the approprate spots.
$this->content[$pane->pid] =& $pane;
$this->panels[$location][] = $pane->pid;
}