User:Jongfeli

From mediawiki.org
Jump to navigation Jump to search
    OO.ui.StackLayout.prototype.updateHiddenState = function (items, selectedItem) {
      var i,
      len;
      if (!this.continuous) {
        for (i = 0, len = items.length; i < len; i++) {
          if (!selectedItem || selectedItem !== items[i]) {
            items[i].toggle(false);
            items[i].$element.attr('aria-hidden', 'true');
          }
        }
        if (selectedItem) {
          selectedItem.toggle(true);
          selectedItem.$element.removeAttr('aria-hidden');
        }
      }
    };