diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/display/DisplayPluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/display/DisplayPluginBase.php index ab69132..3068558 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/display/DisplayPluginBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/display/DisplayPluginBase.php @@ -2487,7 +2487,7 @@ public function access($account = NULL) { * overridden on an individual display. */ public function preExecute() { - $this->view->setUsesAJAX($this->isAJAXEnabled()); + $this->view->setAjaxEnabled($this->isAJAXEnabled()); if ($this->usesMore() && !$this->useMoreAlways()) { $this->view->get_total_rows = TRUE; } diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/display/Feed.php b/core/modules/views/lib/Drupal/views/Plugin/views/display/Feed.php index 9599209..495b5ee 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/display/Feed.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/display/Feed.php @@ -33,7 +33,7 @@ class Feed extends PathPluginBase { * * @var bool */ - protected $usesAJAX = FALSE; + protected $ajaxEnabled = FALSE; /** * Whether the display allows the use of a pager or not. diff --git a/core/modules/views/lib/Drupal/views/Tests/Plugin/PagerTest.php b/core/modules/views/lib/Drupal/views/Tests/Plugin/PagerTest.php index 2f75320..6be2dc8 100644 --- a/core/modules/views/lib/Drupal/views/Tests/Plugin/PagerTest.php +++ b/core/modules/views/lib/Drupal/views/Tests/Plugin/PagerTest.php @@ -251,7 +251,7 @@ public function testRenderNullPager() { $view = views_get_view('test_pager_full'); $this->executeView($view); // Force the value again here. - $view->setUsesAJAX(TRUE); + $view->setAjaxEnabled(TRUE); $view->pager = NULL; $output = $view->render(); $output = drupal_render($output); diff --git a/core/modules/views/lib/Drupal/views/Tests/ViewExecutableTest.php b/core/modules/views/lib/Drupal/views/Tests/ViewExecutableTest.php index 5545a38..f975427 100644 --- a/core/modules/views/lib/Drupal/views/Tests/ViewExecutableTest.php +++ b/core/modules/views/lib/Drupal/views/Tests/ViewExecutableTest.php @@ -190,10 +190,10 @@ public function testDisplays() { public function testPropertyMethods() { $view = views_get_view('test_executable_displays'); - // Test the setUsesAJAX() method. - $this->assertFalse($view->usesAJAX()); - $view->setUsesAJAX(TRUE); - $this->assertTrue($view->usesAJAX()); + // Test the setAjaxEnabled() method. + $this->assertFalse($view->ajaxEnabled()); + $view->setAjaxEnabled(TRUE); + $this->assertTrue($view->ajaxEnabled()); $view->setDisplay(); // There should be no pager set initially. diff --git a/core/modules/views/lib/Drupal/views/ViewExecutable.php b/core/modules/views/lib/Drupal/views/ViewExecutable.php index 1e41aed..c6bf2ea 100644 --- a/core/modules/views/lib/Drupal/views/ViewExecutable.php +++ b/core/modules/views/lib/Drupal/views/ViewExecutable.php @@ -67,7 +67,7 @@ class ViewExecutable { * * @var bool */ - protected $usesAJAX = FALSE; + protected $ajaxEnabled = FALSE; /** * Where the results of a query will go. @@ -549,19 +549,19 @@ public function usePager() { * @param bool $use_ajax * TRUE if AJAX should be used, FALSE otherwise. */ - public function setUsesAJAX($uses_ajax) { - $this->usesAJAX = (bool) $uses_ajax; + public function setAjaxEnabled($ajax_enabled) { + $this->ajaxEnabled = (bool) $ajax_enabled; } /** * Whether or not AJAX should be used. * - * @see \Drupal\views\ViewExecutable::setUsesAJAX(). + * @see \Drupal\views\ViewExecutable::setAjaxEnabled(). * * @return bool */ - public function usesAJAX() { - return $this->usesAJAX; + public function ajaxEnabled() { + return $this->ajaxEnabled; } /** diff --git a/core/modules/views/views.theme.inc b/core/modules/views/views.theme.inc index f01c0d4..a1a12a6 100644 --- a/core/modules/views/views.theme.inc +++ b/core/modules/views/views.theme.inc @@ -130,7 +130,7 @@ function template_preprocess_views_view(&$vars) { } // If using AJAX, send identifying data about this view. - if ($view->usesAJAX() && empty($view->is_attachment) && empty($view->live_preview)) { + if ($view->ajaxEnabled() && empty($view->is_attachment) && empty($view->live_preview)) { $settings = array( 'views' => array( 'ajax_path' => url('views/ajax'),