function charts_plugin_style_chart::get_parent_chart_display in Charts 7.2
Utility function to check if this chart has a parent display.
2 calls to charts_plugin_style_chart::get_parent_chart_display()
- charts_plugin_style_chart::options_form in views/
charts_plugin_style_chart.inc - Generate a form for setting options.
- charts_plugin_style_chart::validate in views/
charts_plugin_style_chart.inc - Make sure the display and all associated handlers are valid.
File
- views/
charts_plugin_style_chart.inc, line 355 - Contains the Chart style (format) plugin (similar to Table, HTML List, etc.)
Class
- charts_plugin_style_chart
- Style plugin to render view as a chart.
Code
function get_parent_chart_display() {
$parent_display = FALSE;
if ($this->plugin_name === 'chart_extension' && $this->display && $this->display->handler->options['parent_display']) {
$parent_display_name = $this->display->handler
->get_option('parent_display');
if (isset($this->view->display[$parent_display_name])) {
$parent_display = $this->view->display[$parent_display_name];
}
}
// Ensure the parent is a chart.
if ($parent_display && $parent_display->handler
->get_option('style_plugin') !== 'chart') {
$parent_display = FALSE;
}
return $parent_display;
}