function views_plugin_style::uses_tokens

Same name in other branches
  1. 7.x-3.x plugins/views_plugin_style.inc \views_plugin_style::uses_tokens()

Return TRUE if this style uses tokens.

Used to ensure we don't fetch tokens when not needed for performance.

File

plugins/views_plugin_style.inc, line 103

Class

views_plugin_style
Base class to define a style plugin handler.

Code

function uses_tokens() {
    if ($this->uses_row_class()) {
        $class = $this->options['row_class'];
        if (strpos($class, '[') !== FALSE || strpos($class, '!') !== FALSE || strpos($class, '%') !== FALSE) {
            return TRUE;
        }
    }
}