/// <summary> /// Allows a secondary filter of the already loaded <see cref="Items"/> by the given <paramref name="search"/> term. /// </summary> /// <param name="search">Search term (or key)</param> public virtual void ApplySecondaryFilter(string search) { IItemsFilter filter = _filter; if (filter == null) { return; } // Init backup list if (_originalList == null) { _originalList = new ItemsList(); CollectionUtils.AddAll(_originalList, _items); } filter.Filter(_items, _originalList, search); IsFiltered = filter.IsFiltered; if (IsFiltered) { // Filter defined by class NumItemsStr = filter.Text; } else { // Restore default text NumItemsStr = Utils.BuildNumItemsStr(NumItems, TotalNumItems); } }
protected AbstractScreenData(string screen, string menuItemLabel) { _screen = screen; _menuItemLabel = menuItemLabel; _filter = new RemoteNumpadFilter(); }
protected AbstractScreenData(string screen, string menuItemLabel) { _screen = screen; _menuItemLabel = menuItemLabel; _filter = new RemoteNumpadFilter(); }