Lines Matching refs:items
25 * If no items in this row are focused, the row can stay active until focus
29 * @param {!Array.<!Element>|!NodeList} items Elements to track focus of.
36 function FocusRow(items, opt_boundary, opt_delegate, opt_observer) {
38 this.items = Array.prototype.slice.call(items);
39 assert(this.items.length > 0);
55 this.items.forEach(function(item) {
67 this.activeIndex_ = this.items.indexOf(document.activeElement);
75 * Called when a key is pressed while an item in |this.items| is focused. If
105 var wasActive = this.items[this.activeIndex_];
109 this.items.forEach(function(item) { assert(item.tabIndex == -1); });
112 if (this.items[index])
113 this.items[index].tabIndex = 0;
118 var isActive = index >= 0 && index < this.items.length;
131 * this.items.length - 1.
134 this.items[index].focus();
148 this.activeIndex = this.items.indexOf(e.target);
156 var item = this.items.indexOf(e.target);
175 index = this.items.length - 1;
177 if (!this.items[index])
190 this.activeIndex = this.items.indexOf(e.currentTarget);