Example #1
0
        protected MediaSearchModel(ObservableCollection<string> mediaGenres) {
            _genres = new MultiCheckSelection<string>(mediaGenres);
            var orderEnumInfo = Constants.OrderFieldsEnumInfo;
            var orderList = new List<OrderSelection>();
            var titleOrder = new OrderSelection(orderEnumInfo.First(i => i.Item == OrderFields.Title));
            orderList.Add(titleOrder);
            orderList.Add(new OrderSelection(orderEnumInfo.First(i => i.Item == OrderFields.Rating), true));
            orderList.Add(new OrderSelection(orderEnumInfo.First(i => i.Item == OrderFields.Year)));

            _orderList = orderList;
            _selectedOrder = titleOrder;
            _selectedOrder.IsSelected = true;

            _pageSize = 50;
            _page = 1;
        }
Example #2
0
        protected MediaSearchModel(ObservableCollection <string> mediaGenres)
        {
            _genres = new MultiCheckSelection <string>(mediaGenres);
            var orderEnumInfo = Constants.OrderFieldsEnumInfo;
            var orderList     = new List <OrderSelection>();
            var titleOrder    = new OrderSelection(orderEnumInfo.First(i => i.Item == OrderFields.Title));

            orderList.Add(titleOrder);
            orderList.Add(new OrderSelection(orderEnumInfo.First(i => i.Item == OrderFields.Rating), true));
            orderList.Add(new OrderSelection(orderEnumInfo.First(i => i.Item == OrderFields.Year)));

            _orderList                = orderList;
            _selectedOrder            = titleOrder;
            _selectedOrder.IsSelected = true;

            _pageSize = 50;
            _page     = 1;
        }