See [[activeRadioList()]] for details
515213
public static function activeRadioListSmart($model, $attribute, $items, $options = [])
    {
        $options['itemOptions']['labelOptions'] = ['class' => 'radio'];
        return static::activeListInput('radioListSmart', $model, $attribute, $items, $options);
    }
383519
function render() {
      var checked = rgCtrl.getViewValue() == attr.value;

      if (checked === lastChecked) return;

      if (element[0].parentNode.nodeName.toLowerCase() !== 'md-radio-group') {
        // If the radioButton is inside a div, then add class so highlighting will work
        element.parent().toggleClass(CHECKED_CSS, checked);
      }

      if (checked) {
        rgCtrl.setActiveDescendant(element.attr('id'));
      }

      lastChecked = checked;

      element
        .attr('aria-checked', checked)
        .toggleClass(CHECKED_CSS, checked);
    }
1175193
def _active_mounts_freebsd(ret):
    '''
    
    '''
    for line in __salt__['cmd.run_stdout']('mount -p').split('\n'):
        comps = re.sub(r"\s+", " ", line).split()
        ret[comps[1]] = {'device': comps[0],
                         'fstype': comps[2],
                         'opts': _resolve_user_group_names(comps[3].split(','))}
    return ret
824620
def rm_rf(z, path)
      z.get_children(:path => path).tap do |h|
        if h[:rc].zero?
          h[:children].each do |child|
            rm_rf(z, File.join(path, child))
          end
        elsif h[:rc] == ZNONODE
          # no-op
        else
          raise "Oh noes! unexpected return value! #{h.inspect}"
        end
      end

      rv = z.delete(:path => path)

      unless (rv[:rc].zero? or rv[:rc] == ZNONODE)
        raise "oh noes! failed to delete #{path}" 
      end

      path
    end
299380
function mount$2(selector, tagName, opts) {
  var tags = [];
  var elem, allTags;

  function pushTagsTo(root) {
    if (root.tagName) {
      var riotTag = getAttr(root, IS_DIRECTIVE), tag;

      // have tagName? force riot-tag to be the same
      if (tagName && riotTag !== tagName) {
        riotTag = tagName;
        setAttr(root, IS_DIRECTIVE, tagName);
      }

      tag = mountTo(root, riotTag || root.tagName.toLowerCase(), opts);

      if (tag)
        { tags.push(tag); }
    } else if (root.length)
      { each(root, pushTagsTo); } // assume nodeList
  }

  // inject styles into DOM
  styleManager.inject();

  if (isObject(tagName)) {
    opts = tagName;
    tagName = 0;
  }

  // crawl the DOM to find the tag
  if (isString(selector)) {
    selector = selector === '*' ?
      // select all registered tags
      // & tags found with the riot-tag attribute set
      allTags = selectTags() :
      // or just the ones named like the selector
      selector + selectTags(selector.split(/, */));

    // make sure to pass always a selector
    // to the querySelectorAll function
    elem = selector ? $$(selector) : [];
  }
  else
    // probably you have passed already a tag or a NodeList
    { elem = selector; }

  // select all the registered and mount them inside their root elements
  if (tagName === '*') {
    // get all custom tags
    tagName = allTags || selectTags();
    // if the root els it's just a single tag
    if (elem.tagName)
      { elem = $$(tagName, elem); }
    else {
      // select all the children for all the different root elements
      var nodeList = [];

      each(elem, function (_el) { return nodeList.push($$(tagName, _el)); });

      elem = nodeList;
    }
    // get rid of the tagName
    tagName = 0;
  }

  pushTagsTo(elem);

  return tags
}
909816
def rsr(self):
        """"""
        arr = np.array([self.wave.value, self.throughput]).swapaxes(0, 1)

        return arr
512070
def list_ar (archive, compression, cmd, verbosity, interactive):
    """"""
    opts = 't'
    if verbosity > 1:
        opts += 'v'
    return [cmd, opts, archive]
278800
function getAndActive (router, el, isParent, autoTitle) {
  el = getNode(el);

  var links = findAll(el, 'a');
  var hash = router.toURL(router.getCurrentPath());
  var target;

  links
    .sort(function (a, b) { return b.href.length - a.href.length; })
    .forEach(function (a) {
      var href = a.getAttribute('href');
      var node = isParent ? a.parentNode : a;

      if (hash.indexOf(href) === 0 && !target) {
        target = a;
        toggleClass(node, 'add', 'active');
      } else {
        toggleClass(node, 'remove', 'active');
      }
    });

  if (autoTitle) {
    $.title = target ? ((target.innerText) + " - " + title) : title;
  }

  return target
}
938255
function _name_listDirective() {
  return {
    scope: {},
    require: [],
    controller: _name_listController,
    link: postLink
  };

  function postLink(scope, element, attr, ctrls) {

  }
}
1089153
def set_active(self, active):
        """"""
        url = CONST.AUTOMATION_EDIT_URL
        url = url.replace(
            '$AUTOMATIONID$', self.automation_id)

        self._automation['is_active'] = str(int(active))

        response = self._abode.send_request(
            method="put", url=url, data=self._automation)

        response_object = json.loads(response.text)

        if isinstance(response_object, (tuple, list)):
            response_object = response_object[0]

        if (str(response_object['id']) != str(self._automation['id']) or
                response_object['is_active'] != self._automation['is_active']):
            raise AbodeException((ERROR.INVALID_AUTOMATION_EDIT_RESPONSE))

        self.update(response_object)

        return True
979334
function(context, args, stack) {
		var xpr = args[0],
			index = args[1],
			templ = args[2],
			val = xpr.__interpolable__ ? xpr.output(context) : xpr,
			rest = new Template(templ._queue.slice(index)),
			instance,
			obj = {
				val: val,
				rest: rest,
				stack: []
			};
		stack.push(obj);
		if (val)
			firstPass(rest, context, obj.stack);
		else if (xpr.__interpolable__)
			instance = xpr.subscribeTo(context, function(value) {
				if (value) {
					obj.val = value;
					instance.destroy();
					firstPass(rest, context, obj.stack);
				}
			});
	}
1355782
function getActiveStepCount() {
            var tourWrapper = jQuery('.cd-tour-wrapper'), //get the wrapper element
                tourSteps = tourWrapper.children('li'); //get all its children with tag 'li'

            var current_index = 0;
            tourSteps.each(function (index, li) {
                if (jQuery(li).hasClass('is-selected'))
                    current_index = index;
            });

            return current_index;
        }
316689
static function active( $asObject = true, $offset, $limit, $sortField = "created", $sortOrder = "asc", $show = eZOrder::SHOW_NORMAL )
    {
        if ( $sortField == "user_name" )
        {
            $db = eZDB::instance();

            $db_params = array();
            $db_params["offset"] =(int) $offset;
            $db_params["limit"] =(int) $limit;
            $sortOrder = $db->escapeString( $sortOrder );

            $query = "SELECT ezorder.*
                      FROM
                            ezorder,
                            ezcontentobject
                      WHERE
                            ".eZOrder::getShowOrdersQuery( $show, "ezorder" )." AND
                            ezorder.is_temporary = '0' AND
                            ezcontentobject.id = ezorder.user_id
                      ORDER BY ezcontentobject.name $sortOrder";
            $orderArray = $db->arrayQuery( $query, $db_params );
            if ( $asObject )
            {
                $retOrders = array();
                foreach ( $orderArray as $order )
                {
                    $order = new eZOrder( $order );
                    $retOrders[] = $order;
                }
                return $retOrders;
            }
            else
            {
                return $orderArray;
            }
        }
        else
        {
            $where['is_temporary'] = 0;
            if ( $show != eZOrder::SHOW_ALL )
            {
                $where['is_archived'] = $show;
            }

            return eZPersistentObject::fetchObjectList( eZOrder::definition(),
                                                        null,
                                                        $where ,
                                                        array( $sortField => $sortOrder ),
                                                        array( 'offset' => $offset,
                                                               'length' => $limit ), $asObject );
        }
    }
977154
def set_active_current(self, axis, amp):
        
        self._smoothie_driver.set_active_current({axis.name: amp})
455636
def _active_mounts_openbsd(ret):
    '''
    
    '''
    for line in __salt__['cmd.run_stdout']('mount -v').split('\n'):
        comps = re.sub(r"\s+", " ", line).split()
        parens = re.findall(r'\((.*?)\)', line, re.DOTALL)
        if len(parens) > 1:
            nod = __salt__['cmd.run_stdout']('ls -l {0}'.format(comps[0]))
            nod = ' '.join(nod.split()).split(" ")
            ret[comps[3]] = {'device': comps[0],
                         'fstype': comps[5],
                         'opts': _resolve_user_group_names(parens[1].split(", ")),
                         'major': six.text_type(nod[4].strip(",")),
                         'minor': six.text_type(nod[5]),
                         'device_uuid': parens[0]}
        else:
            ret[comps[2]] = {'device': comps[0],
                            'fstype': comps[4],
                            'opts': _resolve_user_group_names(parens[0].split(", "))}
    return ret
817511
def element_at(index):
    """"""

    if index < 0:
        raise IndexError("element_at used with illegal index {}".format(index))

    def element_at_transducer(reducer):
        return ElementAt(reducer, index)

    return element_at_transducer
331785
def active(self, date="", page=1, page_size=1000, order_field="email", order_direction="asc", include_tracking_preference=False):
        """"""
        params = {
            "date": date,
            "page": page,
            "pagesize": page_size,
            "orderfield": order_field,
            "orderdirection": order_direction,
            "includetrackingpreference": include_tracking_preference,
        }
        response = self._get(self.uri_for("active"), params=params)
        return json_to_py(response)