Commit 90dba138 authored by tim.plunkett's avatar tim.plunkett

Finish converting all "use *" to "use_*" options.

parent 2aa84d21
......@@ -336,7 +336,7 @@ function displays_exposed() {
* Does the display use AJAX?
*/
function use_ajax() {
if (!empty($this->definition['use ajax'])) {
if (!empty($this->definition['use_ajax'])) {
return $this->get_option('use_ajax');
}
return FALSE;
......@@ -356,7 +356,7 @@ function use_pager() {
* Does the display have a more link enabled?
*/
function use_more() {
if (!empty($this->definition['use more'])) {
if (!empty($this->definition['use_more'])) {
return $this->get_option('use_more');
}
return FALSE;
......@@ -373,7 +373,7 @@ function use_group_by() {
* Should the enabled display more link be shown when no more items?
*/
function use_more_always() {
if (!empty($this->definition['use more'])) {
if (!empty($this->definition['use_more'])) {
return $this->get_option('use_more_always');
}
return FALSE;
......@@ -383,7 +383,7 @@ function use_more_always() {
* Does the display have custom link text?
*/
function use_more_text() {
if (!empty($this->definition['use more'])) {
if (!empty($this->definition['use_more'])) {
return $this->get_option('use_more_text');
}
return FALSE;
......@@ -458,7 +458,7 @@ function defaultable_sections($section = NULL) {
);
// If the display cannot use a pager, then we cannot default it.
if (empty($this->definition['use pager'])) {
if (empty($this->definition['use_pager'])) {
unset($sections['pager']);
unset($sections['items_per_page']);
}
......@@ -713,7 +713,7 @@ function option_definition() {
),
);
if (empty($this->definition['use pager'])) {
if (empty($this->definition['use_pager'])) {
$options['defaults']['default']['use_pager'] = FALSE;
$options['defaults']['default']['items_per_page'] = FALSE;
$options['defaults']['default']['offset'] = FALSE;
......@@ -1231,7 +1231,7 @@ function options_summary(&$categories, &$options) {
$options['row_plugin']['links']['row_options'] = t('Change settings for this style');
}
}
if (!empty($this->definition['use ajax'])) {
if (!empty($this->definition['use_ajax'])) {
$options['use_ajax'] = array(
'category' => 'other',
'title' => t('Use AJAX'),
......@@ -1273,7 +1273,7 @@ function options_summary(&$categories, &$options) {
);
// If pagers aren't allowed, change the text of the item:
if (empty($this->definition['use pager'])) {
if (empty($this->definition['use_pager'])) {
$options['pager']['title'] = t('Items to display');
}
......@@ -1281,7 +1281,7 @@ function options_summary(&$categories, &$options) {
$options['pager']['links']['pager_options'] = t('Change settings for this pager type.');
}
if (!empty($this->definition['use more'])) {
if (!empty($this->definition['use_more'])) {
$options['use_more'] = array(
'category' => 'pager',
'title' => t('More link'),
......@@ -2168,7 +2168,7 @@ function options_form(&$form, &$form_state) {
$pager = $this->get_option('pager');
$form['pager']['type'] = array(
'#type' => 'radios',
'#options' => views_fetch_plugin_names('pager', empty($this->definition['use pager']) ? 'basic' : NULL, array($this->view->base_table)),
'#options' => views_fetch_plugin_names('pager', empty($this->definition['use_pager']) ? 'basic' : NULL, array($this->view->base_table)),
'#default_value' => $pager['type'],
);
......
......@@ -20,7 +20,7 @@
* - on-off: On/Off
* - enabled-disabled: Enabled/Disabled
* - accept null: Treat a NULL value as false.
* - use equal: If you use this flag the query will use = 1 instead of <> 0.
* - use_equal: If you use this flag the query will use = 1 instead of <> 0.
* This might be helpful for performance reasons.
*
* @ingroup views_filter_handlers
......@@ -176,7 +176,7 @@ function query() {
}
}
else {
if (!empty($this->definition['use equal'])) {
if (!empty($this->definition['use_equal'])) {
$this->query->add_where($this->options['group'], $field, 1, '=');
}
else {
......
......@@ -159,7 +159,7 @@ function node_views_data() {
'id' => 'boolean',
'label' => t('Published'),
'type' => 'yes-no',
'use equal' => TRUE, // Use status = 1 instead of status <> 0 in WHERE statment
'use_equal' => TRUE, // Use status = 1 instead of status <> 0 in WHERE statment
),
'sort' => array(
'id' => 'standard',
......
......@@ -261,8 +261,8 @@
* 'help' => t('Display the view as a feed, such as an RSS feed.'),
* 'handler' => 'views_plugin_display_feed',
* 'uses_hook_menu' => TRUE,
* 'use ajax' => FALSE,
* 'use pager' => FALSE,
* 'use_ajax' => FALSE,
* 'use_pager' => FALSE,
* 'accept_attachments' => FALSE,
* 'admin' => t('Feed'),
* 'help topic' => 'display-feed',
......@@ -429,7 +429,7 @@ function hook_views_data() {
// This setting is used by the boolean filter handler, as possible option.
'type' => 'yes-no',
// use boolean_field = 1 instead of boolean_field <> 0 in WHERE statment.
'use equal' => TRUE,
'use_equal' => TRUE,
),
'sort' => array(
'id' => 'standard',
......@@ -556,10 +556,10 @@ function hook_views_data_alter(&$data) {
* t().
* - no remove: Set to TRUE to make the display non-removable. (Basically
* only used for the master/default display.)
* - use ajax: Set to TRUE to allow AJAX loads in the display. If it's
* - use_ajax: Set to TRUE to allow AJAX loads in the display. If it's
* disabled there will be no ajax option in the ui.
* - use pager: Set to TRUE to allow paging in the display.
* - use more: Set to TRUE to allow the 'use more' setting in the display.
* - use_pager: Set to TRUE to allow paging in the display.
* - use_more: Set to TRUE to allow the 'use_more' setting in the display.
* - accept_attachments: Set to TRUE to allow attachment displays to be
* attached to this display type.
* - contextual_links_locations: An array with places where contextual links
......
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