Esempio n. 1
0
        /// <summary>
        /// Handles the <see cref="E:TextInput" /> event.
        /// </summary>
        /// <param name="e">The <see cref="TextInputEventArgs" /> instance containing the event data.</param>
        protected override void OnTextInput(TextInputEventArgs e)
        {
            if (searchSelect == null)
            {
                searchSelect = new SearchSelect();
            }
            var index = searchSelect.FindMatch(e, IsTextSearchEnabled, ItemContainerGenerator, Items as IEnumerable <IQueryableModel>);

            if (index.HasValue)
            {
                SelectedIndex = index.GetValueOrDefault();
            }
            base.OnTextInput(e);
        }
Esempio n. 2
0
 private PropertyType GetSearchPropertyType(GridColumnBase gridColumn)
 {
     if (SearchProperty != null)
     {
         PropertyType searchType = gridColumn.PropertyType;
         if (searchType != PropertyType.datetime && SearchSelect != null && SearchSelect.Any())
         {
             SearchText = SearchSelect.OrderBy(x => x).FirstOrDefault();
             searchType = PropertyType.list;
         }
         return(searchType);
     }
     return(PropertyType.noType);
 }