Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
09/16/10 19:26:24 (14 years ago)
Author:
swagner
Message:

Enabled saving only for some specific items (#1193)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Core/3.3/Collections/ItemCollection.cs

    r3822 r4419  
    3333  [Item("ItemCollection", "Represents a collection of items.")]
    3434  public class ItemCollection<T> : ObservableCollection<T>, IItemCollection<T> where T : class, IItem {
    35     private string filename;
    36     public string Filename {
    37       get { return filename; }
    38       set {
    39         if (value == null) throw new ArgumentNullException();
    40         if ((filename == null) || !filename.Equals(value)) {
    41           filename = value;
    42           OnFilenameChanged();
    43         }
    44       }
    45     }
    46 
    4735    public virtual string ItemName {
    4836      get { return ItemAttribute.GetName(this.GetType()); }
     
    8270    }
    8371
    84     public event EventHandler FilenameChanged;
    85     protected virtual void OnFilenameChanged() {
    86       EventHandler handler = FilenameChanged;
    87       if (handler != null) handler(this, EventArgs.Empty);
    88     }
    8972    public event EventHandler ItemImageChanged;
    9073    protected virtual void OnItemImageChanged() {
Note: See TracChangeset for help on using the changeset viewer.