Commit da4d9944 authored by dawehner's avatar dawehner Committed by tim.plunkett

by damiankloip: Make some work to get display going on

parent 02ee6ae5
......@@ -19,7 +19,7 @@ function views_views_plugins() {
'default' => array(
'title' => t('Master'),
'help' => t('Default settings for this view.'),
'class' => 'Drupal\views\Plugins\views\display\Default',
'class' => 'Drupal\views\Plugins\views\display\DefaultDisplay',
'theme' => 'views_view',
'no ui' => TRUE,
'no remove' => TRUE,
......
......@@ -2,7 +2,7 @@
/**
* @file
* Definition of Drupal\views\Plugins\views\display\Default.
* Definition of Drupal\views\Plugins\views\display\DefaultDisplay.
*/
namespace Drupal\views\Plugins\views\display;
......@@ -12,7 +12,7 @@
*
* @ingroup views_display_plugins
*/
class Default extends DisplayPluginBase {
class DefaultDisplay extends DisplayPluginBase {
/**
* Determine if this display is the 'default' display which contains
* fallback settings
......
......@@ -9,6 +9,7 @@
use Symfony\Component\HttpFoundation\Response;
use Drupal\views\Plugins\Type\QueryPluginManager;
use Drupal\views\Plugins\Type\DisplayPluginManager;
/**
* @defgroup views_objects Objects that represent a View or part of a view
......@@ -471,7 +472,8 @@ function init_display($reset = FALSE) {
$this->display[$id] = clone $this->display[$id];
unset($this->display[$id]->handler);
}
$this->display[$id]->handler = views_get_plugin('display', $this->display[$id]->display_plugin);
$plugin_manager = new DisplayPluginManager();
$this->display[$id]->handler = $plugin_manager->createInstance($this->display[$id]->display_plugin);
if (!empty($this->display[$id]->handler)) {
$this->display[$id]->handler->localization_keys = array($id);
// Initialize the new display handler with data.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment