summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEarl Miles2013-02-01 17:49:11 (GMT)
committer Earl Miles2013-02-01 17:49:11 (GMT)
commit9846b92bfb5452c97ece7306d5dd2554551b4cef (patch)
tree164a40a2db95da9f25bd91ae9cf94f9aceaafd07
parentdc64a472c2aafcff463c819ba5db54fec64c0b74 (diff)
Issue #1836716 by grndlvl: Allow selection of default pipeline for new pages.
-rw-r--r--includes/callbacks.inc16
-rw-r--r--plugins/task_handlers/panel_context.inc2
2 files changed, 17 insertions, 1 deletions
diff --git a/includes/callbacks.inc b/includes/callbacks.inc
index 5188394..255a3cd 100644
--- a/includes/callbacks.inc
+++ b/includes/callbacks.inc
@@ -172,6 +172,22 @@ function panels_admin_settings_page() {
}
}
+ ctools_include('plugins', 'panels');
+ $pipelines = panels_get_renderer_pipelines();
+ $options = array();
+ foreach ($pipelines as $key => $value) {
+ $options[$key] = $value->admin_title;
+ }
+ if (count($options) > 1) {
+ $form['panels_renderer_default'] = array(
+ '#type' => 'select',
+ '#title' => t('Default renderer'),
+ '#options' => $options,
+ '#default_value' => variable_get('panels_renderer_default', 'standard'),
+ '#description' => t('The default renderer for new panel pages.'),
+ );
+ }
+
if (empty($form)) {
return array('#value' => t('There are currently no settings to change, but additional plugins or modules may provide them in the future.'));
}
diff --git a/plugins/task_handlers/panel_context.inc b/plugins/task_handlers/panel_context.inc
index 619c86e..06af824 100644
--- a/plugins/task_handlers/panel_context.inc
+++ b/plugins/task_handlers/panel_context.inc
@@ -184,7 +184,7 @@ $plugin = array(
'default conf' => array(
'title' => t('Panel'),
'no_blocks' => FALSE,
- 'pipeline' => 'standard',
+ 'pipeline' => variable_get('panels_renderer_default', 'standard'),
'body_classes_to_remove' => '',
'body_classes_to_add' => '',
'css_id' => '',