Example #1
0
 private void OnFilterApplied(PropertyFilter filter)
 {
     if (this.FilterApplied != null)
     {
         this.FilterApplied(this, new PropertyFilterAppliedEventArgs(filter));
     }
 }
        // TODO: Optimize performance
        public override void ApplyFilter(PropertyFilter filter)
        {
            foreach (PropertyItem property in properties)
            {
                if (PropertyMatchesFilter(filter, property))
                {
                    foreach (FrameworkElement element in Children)
                    {
                        if (!object.Equals(element.Tag, property.Name))
                        {
                            continue;
                        }
                        element.Visibility = Visibility.Visible;
                    }
                    continue;
                }

                foreach (FrameworkElement element in Children)
                {
                    if (!object.Equals(element.Tag, property.Name))
                    {
                        continue;
                    }
                    element.Visibility = Visibility.Collapsed;
                }
            }
        }
        // TODO: Optimize performance
        public override void ApplyFilter(PropertyFilter filter)
        {
            foreach (PropertyItem property in properties)
              {
            if (PropertyMatchesFilter(filter, property))
            {
              foreach (FrameworkElement element in Children)
              {
            if (!object.Equals(element.Tag, property.Name)) continue;
            element.Visibility = Visibility.Visible;
              }
              continue;
            }

            foreach (FrameworkElement element in Children)
            {
              if (!object.Equals(element.Tag, property.Name)) continue;
              element.Visibility = Visibility.Collapsed;
            }
              }
        }
Example #4
0
 public void ApplyFilter(PropertyFilter filter)
 {
     this.MatchesFilter = (filter == null) || filter.Match(this);
     this.OnFilterApplied(filter);
 }
 public override void ApplyFilter(PropertyFilter filter)
 {
     //throw new NotImplementedException();
 }
 public override void ApplyFilter(PropertyFilter filter)
 {
     //throw new NotImplementedException();
 }
 private bool PropertyMatchesFilter(PropertyFilter filter, PropertyItem entry)
 {
     entry.ApplyFilter(filter);
     return(entry.MatchesFilter);
 }
Example #8
0
 public abstract void ApplyFilter(PropertyFilter filter);
 private bool PropertyMatchesFilter(PropertyFilter filter, PropertyItem entry)
 {
     entry.ApplyFilter(filter);
       return entry.MatchesFilter;
 }
Example #10
0
 public abstract void ApplyFilter(PropertyFilter filter);