예제 #1
0
 private void OnFilteringItem(ItemFilteringEventArgs e)
 {
     if (FilteringItem != null)
     {
         FilteringItem(this, e);
     }
 }
예제 #2
0
 void _searchBox_TextChanged(object sender, EventArgs e)
 {
     if (_searchBox.Text.Length == 0)
     {
         this.Items.EndFilter();
     }
     else
     {
         this._items.Filter(o =>
         {
             ItemFilteringEventArgs args = new ItemFilteringEventArgs(o, _searchBox.Text);
             OnFilteringItem(args);
             return(!args.ShouldBeRemoved);
         });
     }
 }
예제 #3
0
 private void OnFilteringItem(ItemFilteringEventArgs e)
 {
     if (FilteringItem != null)
         FilteringItem(this, e);
 }
예제 #4
0
        void _searchBox_TextChanged(object sender, EventArgs e)
        {
            if (_searchBox.Text.Length == 0)
            {
                this.Items.EndFilter();

            }
            else
            {
                this._items.Filter(o =>
                {
                    ItemFilteringEventArgs args = new ItemFilteringEventArgs(o, _searchBox.Text);
                    OnFilteringItem(args);
                    return !args.ShouldBeRemoved;
                });
            }
        }