diff --git a/core/modules/comment/lib/Drupal/comment/Plugin/views/field/NodeNewComments.php b/core/modules/comment/lib/Drupal/comment/Plugin/views/field/NodeNewComments.php index e8e7d67..c19b84c 100644 --- a/core/modules/comment/lib/Drupal/comment/Plugin/views/field/NodeNewComments.php +++ b/core/modules/comment/lib/Drupal/comment/Plugin/views/field/NodeNewComments.php @@ -91,7 +91,7 @@ public function query() { $this->field_alias = $this->table . '_' . $this->field; } - function pre_render(&$values) { + public function preRender(&$values) { global $user; if (!$user->uid || empty($values)) { return; diff --git a/core/modules/comment/lib/Drupal/comment/Plugin/views/row/Rss.php b/core/modules/comment/lib/Drupal/comment/Plugin/views/row/Rss.php index 2e18fa9..a363bab 100644 --- a/core/modules/comment/lib/Drupal/comment/Plugin/views/row/Rss.php +++ b/core/modules/comment/lib/Drupal/comment/Plugin/views/row/Rss.php @@ -54,7 +54,7 @@ public function buildOptionsForm(&$form, &$form_state) { ); } - function pre_render($result) { + public function preRender($result) { $cids = array(); $nids = array(); diff --git a/core/modules/contextual/lib/Drupal/contextual/Plugin/views/field/ContextualLinks.php b/core/modules/contextual/lib/Drupal/contextual/Plugin/views/field/ContextualLinks.php index 8a3b4bb..7409dbb 100644 --- a/core/modules/contextual/lib/Drupal/contextual/Plugin/views/field/ContextualLinks.php +++ b/core/modules/contextual/lib/Drupal/contextual/Plugin/views/field/ContextualLinks.php @@ -51,7 +51,7 @@ public function buildOptionsForm(&$form, &$form_state) { ); } - function pre_render(&$values) { + public function preRender(&$values) { // Add a row plugin css class for the contextual link. $class = 'contextual-region'; if (!empty($this->view->style_plugin->options['row_class'])) { diff --git a/core/modules/entity_reference/lib/Drupal/entity_reference/Plugin/views/row/EntityReference.php b/core/modules/entity_reference/lib/Drupal/entity_reference/Plugin/views/row/EntityReference.php index 3091519..0696896 100644 --- a/core/modules/entity_reference/lib/Drupal/entity_reference/Plugin/views/row/EntityReference.php +++ b/core/modules/entity_reference/lib/Drupal/entity_reference/Plugin/views/row/EntityReference.php @@ -47,15 +47,15 @@ public function buildOptionsForm(&$form, &$form_state) { } /** - * Overrides \Drupal\views\Plugin\views\row\Fields::pre_render(). + * {@inheritdoc} */ - public function pre_render($row) { + public function preRender($row) { // Force all fields to be inline by default. if (empty($this->options['inline'])) { $fields = $this->view->getItems('field', $this->displayHandler->display['id']); $this->options['inline'] = drupal_map_assoc(array_keys($fields)); } - return parent::pre_render($row); + return parent::preRender($row); } } diff --git a/core/modules/node/lib/Drupal/node/Plugin/views/row/Rss.php b/core/modules/node/lib/Drupal/node/Plugin/views/row/Rss.php index fbdbbf7..49cc52a 100644 --- a/core/modules/node/lib/Drupal/node/Plugin/views/row/Rss.php +++ b/core/modules/node/lib/Drupal/node/Plugin/views/row/Rss.php @@ -32,7 +32,7 @@ class Rss extends RowPluginBase { var $base_field = 'nid'; - // Stores the nodes loaded with pre_render. + // Stores the nodes loaded with preRender. var $nodes = array(); protected function defineOptions() { @@ -79,7 +79,7 @@ public function summaryTitle() { return check_plain($options[$this->options['item_length']]); } - function pre_render($values) { + public function preRender($values) { $nids = array(); foreach ($values as $row) { $nids[] = $row->{$this->field_alias}; diff --git a/core/modules/system/lib/Drupal/system/Plugin/views/field/BulkFormBase.php b/core/modules/system/lib/Drupal/system/Plugin/views/field/BulkFormBase.php index bca1e8c..9d21660 100644 --- a/core/modules/system/lib/Drupal/system/Plugin/views/field/BulkFormBase.php +++ b/core/modules/system/lib/Drupal/system/Plugin/views/field/BulkFormBase.php @@ -57,10 +57,10 @@ public function render($values) { } /** - * Overrides \Drupal\views\Plugin\views\Plugin\field\FieldPluginBase::pre_render(). + * {@inheritdoc} */ - public function pre_render(&$values) { - parent::pre_render($values); + public function preRender(&$values) { + parent::preRender($values); // If the view is using a table style, provide a placeholder for a // "select all" checkbox. diff --git a/core/modules/taxonomy/lib/Drupal/taxonomy/Plugin/views/field/TaxonomyIndexTid.php b/core/modules/taxonomy/lib/Drupal/taxonomy/Plugin/views/field/TaxonomyIndexTid.php index 45f8d69..8cbb9fb 100644 --- a/core/modules/taxonomy/lib/Drupal/taxonomy/Plugin/views/field/TaxonomyIndexTid.php +++ b/core/modules/taxonomy/lib/Drupal/taxonomy/Plugin/views/field/TaxonomyIndexTid.php @@ -91,7 +91,7 @@ public function query() { $this->addAdditionalFields(); } - function pre_render(&$values) { + public function preRender(&$values) { $vocabularies = entity_load_multiple('taxonomy_vocabulary'); $this->field_alias = $this->aliases['nid']; $nids = array(); diff --git a/core/modules/user/lib/Drupal/user/Plugin/views/field/Permissions.php b/core/modules/user/lib/Drupal/user/Plugin/views/field/Permissions.php index 96e3609..34bedd8 100644 --- a/core/modules/user/lib/Drupal/user/Plugin/views/field/Permissions.php +++ b/core/modules/user/lib/Drupal/user/Plugin/views/field/Permissions.php @@ -69,7 +69,7 @@ public function query() { $this->field_alias = $this->aliases['uid']; } - function pre_render(&$values) { + public function preRender(&$values) { $uids = array(); $this->items = array(); diff --git a/core/modules/user/lib/Drupal/user/Plugin/views/field/Roles.php b/core/modules/user/lib/Drupal/user/Plugin/views/field/Roles.php index 298a39e..22c2819 100644 --- a/core/modules/user/lib/Drupal/user/Plugin/views/field/Roles.php +++ b/core/modules/user/lib/Drupal/user/Plugin/views/field/Roles.php @@ -69,7 +69,7 @@ public function query() { $this->field_alias = $this->aliases['uid']; } - function pre_render(&$values) { + public function preRender(&$values) { $uids = array(); $this->items = array(); diff --git a/core/modules/user/lib/Drupal/user/Tests/Views/HandlerFieldRoleTest.php b/core/modules/user/lib/Drupal/user/Tests/Views/HandlerFieldRoleTest.php index 476b5cd..28e9983 100644 --- a/core/modules/user/lib/Drupal/user/Tests/Views/HandlerFieldRoleTest.php +++ b/core/modules/user/lib/Drupal/user/Tests/Views/HandlerFieldRoleTest.php @@ -49,8 +49,8 @@ public function testRole() { $view = views_get_view('test_views_handler_field_role'); $this->executeView($view); $view->row_index = 0; - // The role field is populated during pre_render. - $view->field['rid']->pre_render($view->result); + // The role field is populated during preRender. + $view->field['rid']->preRender($view->result); $render = $view->field['rid']->advancedRender($view->result[0]); $this->assertEqual($rolename_b . $rolename_a, $render, 'View test_views_handler_field_role renders role assigned to user in the correct order.'); diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/HandlerBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/HandlerBase.php index cd7bb42..bceb076 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/HandlerBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/HandlerBase.php @@ -274,7 +274,7 @@ public function buildOptionsForm(&$form, &$form_state) { // Some form elements belong in a fieldset for presentation, but can't // be moved into one because of the form_state['values'] hierarchy. Those // elements can add a #fieldset => 'fieldset_name' property, and they'll - // be moved to their fieldset during pre_render. + // be moved to their fieldset during preRender. $form['#pre_render'][] = 'views_ui_pre_render_add_fieldset_markup'; $form['admin_label'] = array( diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/PluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/PluginBase.php index 7fc2c86..bc8769e 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/PluginBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/PluginBase.php @@ -184,7 +184,7 @@ public function buildOptionsForm(&$form, &$form_state) { // Some form elements belong in a fieldset for presentation, but can't // be moved into one because of the form_state['values'] hierarchy. Those // elements can add a #fieldset => 'fieldset_name' property, and they'll - // be moved to their fieldset during pre_render. + // be moved to their fieldset during preRender. $form['#pre_render'][] = 'views_ui_pre_render_add_fieldset_markup'; } diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/exposed_form/ExposedFormPluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/exposed_form/ExposedFormPluginBase.php index c58c582f..625a2bf 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/exposed_form/ExposedFormPluginBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/exposed_form/ExposedFormPluginBase.php @@ -173,7 +173,7 @@ public function query() { } } - function pre_render($values) { } + public function preRender($values) { } public function postRender(&$output) { } diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/exposed_form/InputRequired.php b/core/modules/views/lib/Drupal/views/Plugin/views/exposed_form/InputRequired.php index 2376f56..38eebee 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/exposed_form/InputRequired.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/exposed_form/InputRequired.php @@ -71,7 +71,7 @@ protected function exposedFilterApplied() { return $cache; } - function pre_render($values) { + public function preRender($values) { if (!$this->exposedFilterApplied()) { $options = array( 'id' => 'area', diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/field/Custom.php b/core/modules/views/lib/Drupal/views/Plugin/views/field/Custom.php index c95913d..38982ee 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/field/Custom.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/field/Custom.php @@ -38,7 +38,7 @@ public function buildOptionsForm(&$form, &$form_state) { unset($form['alter']['alter_text']); unset($form['alter']['text']['#states']); unset($form['alter']['help']['#states']); - $form['#pre_render'][] = array($this, 'preRender'); + $form['#pre_render'][] = array($this, 'preRenderCustomForm'); } function render($values) { @@ -55,7 +55,7 @@ function render($values) { * @return array * The modified form build array. */ - public function preRender($form) { + public function preRenderCustomForm($form) { $form['text'] = $form['alter']['text']; $form['help'] = $form['alter']['help']; unset($form['alter']['text']); diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/field/FieldPluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/field/FieldPluginBase.php index 631d109..9b770cc 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/field/FieldPluginBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/field/FieldPluginBase.php @@ -1090,7 +1090,7 @@ public function adminSummary() { * @param $values * An array of all objects returned from the query. */ - function pre_render(&$values) { } + public function preRender(&$values) { } /** * Render the field. diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/field/MachineName.php b/core/modules/views/lib/Drupal/views/Plugin/views/field/MachineName.php index 86d8d02..6632da4 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/field/MachineName.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/field/MachineName.php @@ -62,7 +62,7 @@ public function buildOptionsForm(&$form, &$form_state) { ); } - function pre_render(&$values) { + public function preRender(&$values) { $this->getValueOptions(); } diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/field/PrerenderList.php b/core/modules/views/lib/Drupal/views/Plugin/views/field/PrerenderList.php index accd78e..01ee041 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/field/PrerenderList.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/field/PrerenderList.php @@ -12,7 +12,7 @@ /** * Field handler to provide a list of items. * - * The items are expected to be loaded by a child object during pre_render, + * The items are expected to be loaded by a child object during preRender, * and 'my field' is expected to be the pointer to the items in the list. * * Items to render should be in a list in $this->items diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/filter/FilterPluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/filter/FilterPluginBase.php index cac71ea..9455174 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/filter/FilterPluginBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/filter/FilterPluginBase.php @@ -493,8 +493,8 @@ public function showExposeButton(&$form, &$form_state) { public function buildExposeForm(&$form, &$form_state) { $form['#theme'] = 'views_ui_expose_filter_form'; // #flatten will move everything from $form['expose'][$key] to $form[$key] - // prior to rendering. That's why the pre_render for it needs to run first, - // so that when the next pre_render (the one for fieldsets) runs, it gets + // prior to rendering. That's why the preRender for it needs to run first, + // so that when the next preRender (the one for fieldsets) runs, it gets // the flattened data. array_unshift($form['#pre_render'], 'views_ui_pre_render_flatten_data'); $form['expose']['#flatten'] = TRUE; @@ -836,8 +836,8 @@ protected function buildExposedFiltersGroupForm(&$form, &$form_state) { $form['#theme'] = 'views_ui_build_group_filter_form'; // #flatten will move everything from $form['group_info'][$key] to $form[$key] - // prior to rendering. That's why the pre_render for it needs to run first, - // so that when the next pre_render (the one for fieldsets) runs, it gets + // prior to rendering. That's why the preRender for it needs to run first, + // so that when the next preRender (the one for fieldsets) runs, it gets // the flattened data. array_unshift($form['#pre_render'], 'views_ui_pre_render_flatten_data'); $form['group_info']['#flatten'] = TRUE; diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/pager/PagerPluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/pager/PagerPluginBase.php index 316eb88..9994cf5 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/pager/PagerPluginBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/pager/PagerPluginBase.php @@ -215,7 +215,7 @@ public function postExecute(&$result) { } /** * Perform any needed actions just before rendering. */ - function pre_render(&$result) { } + public function preRender(&$result) { } /** * Render the pager. diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/row/EntityRow.php b/core/modules/views/lib/Drupal/views/Plugin/views/row/EntityRow.php index ef28d0d..10ae792 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/row/EntityRow.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/row/EntityRow.php @@ -142,10 +142,10 @@ public function summaryTitle() { } /** - * Overrides Drupal\views\Plugin\views\row\RowPluginBase::pre_render(). + * {@inheritdoc} */ - public function pre_render($result) { - parent::pre_render($result); + public function preRender($result) { + parent::preRender($result); if ($result) { // Get all entities which will be used to render in rows. diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/row/RowPluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/row/RowPluginBase.php index 81b559f..44df69f 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/row/RowPluginBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/row/RowPluginBase.php @@ -135,7 +135,7 @@ public function query() { * @param $result * The full array of results from the query. */ - function pre_render($result) { } + public function preRender($result) { } /** * Render a row object. This usually passes through to a theme template diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/sort/SortPluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/sort/SortPluginBase.php index fc2bf8f..ddd022c 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/sort/SortPluginBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/sort/SortPluginBase.php @@ -188,8 +188,8 @@ protected function sortOptions() { public function buildExposeForm(&$form, &$form_state) { // #flatten will move everything from $form['expose'][$key] to $form[$key] - // prior to rendering. That's why the pre_render for it needs to run first, - // so that when the next pre_render (the one for fieldsets) runs, it gets + // prior to rendering. That's why the preRender for it needs to run first, + // so that when the next preRender (the one for fieldsets) runs, it gets // the flattened data. array_unshift($form['#pre_render'], 'views_ui_pre_render_flatten_data'); $form['expose']['#flatten'] = TRUE; diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/style/StylePluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/style/StylePluginBase.php index d0a76db..032c823 100644 --- a/core/modules/views/lib/Drupal/views/Plugin/views/style/StylePluginBase.php +++ b/core/modules/views/lib/Drupal/views/Plugin/views/style/StylePluginBase.php @@ -399,9 +399,9 @@ public function buildSortPost() { } * @param $result * The full array of results from the query. */ - function pre_render($result) { + public function preRender($result) { if (!empty($this->view->rowPlugin)) { - $this->view->rowPlugin->pre_render($result); + $this->view->rowPlugin->preRender($result); } } diff --git a/core/modules/views/lib/Drupal/views/ViewExecutable.php b/core/modules/views/lib/Drupal/views/ViewExecutable.php index 68027f4..76acf8a 100644 --- a/core/modules/views/lib/Drupal/views/ViewExecutable.php +++ b/core/modules/views/lib/Drupal/views/ViewExecutable.php @@ -1227,7 +1227,7 @@ public function render($display_id = NULL) { $config = config('views.settings'); $exposed_form = $this->display_handler->getPlugin('exposed_form'); - $exposed_form->pre_render($this->result); + $exposed_form->preRender($this->result); $module_handler = \Drupal::moduleHandler(); @@ -1246,9 +1246,9 @@ public function render($display_id = NULL) { $cache->cacheStart(); } - // Run pre_render for the pager as it might change the result. + // Run preRender for the pager as it might change the result. if (!empty($this->pager)) { - $this->pager->pre_render($this->result); + $this->pager->preRender($this->result); } // Initialize the style plugin. @@ -1264,12 +1264,12 @@ public function render($display_id = NULL) { if ($this->style_plugin->usesFields()) { foreach ($this->field as $id => $handler) { if (!empty($this->field[$id])) { - $this->field[$id]->pre_render($this->result); + $this->field[$id]->preRender($this->result); } } } - $this->style_plugin->pre_render($this->result); + $this->style_plugin->preRender($this->result); // Let each area handler have access to the result set. $areas = array('header', 'footer'); diff --git a/core/modules/views/views.api.php b/core/modules/views/views.api.php index f61ece2..6f46a96 100644 --- a/core/modules/views/views.api.php +++ b/core/modules/views/views.api.php @@ -431,7 +431,7 @@ function hook_views_pre_execute(ViewExecutable &$view) { /** * Act on the view immediately after the query has been executed. * - * At this point the query has been executed, but the pre_render() phase has + * At this point the query has been executed, but the preRender() phase has * not yet happened for handlers. * * Output can be added to the view by setting $view->attachment_before @@ -455,7 +455,7 @@ function hook_views_post_execute(ViewExecutable &$view) { /** * Act on the view immediately before rendering it. * - * At this point the query has been executed, and the pre_render() phase has + * At this point the query has been executed, and the preRender() phase has * already happened for handlers, so all data should be available. This hook * can be utilized by themes. * diff --git a/core/modules/views_ui/admin.inc b/core/modules/views_ui/admin.inc index a723854..02c62d8 100644 --- a/core/modules/views_ui/admin.inc +++ b/core/modules/views_ui/admin.inc @@ -258,7 +258,7 @@ function views_ui_taxonomy_autocomplete_validate($element, &$form_state) { * * Many views forms use #tree = TRUE to keep their values in a hierarchy for * easier storage. Moving the form elements into fieldsets during form building - * would break up that hierarchy. Therefore, we wait until the pre_render stage, + * would break up that hierarchy. Therefore, we wait until the preRender stage, * where any changes we make affect presentation only and aren't reflected in * $form_state['values']. */