Free cookie consent management tool by TermsFeed Policy Generator

Changeset 2338 for trunk


Ignore:
Timestamp:
09/07/09 15:51:34 (15 years ago)
Author:
mkommend
Message:

corrected setter for icon, title and cursor to use asynchronous methods (ticket #716)

Location:
trunk/sources/HeuristicLab.MainForm/3.2
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.MainForm/3.2/Interfaces/IMainForm.cs

    r2334 r2338  
    3333    bool StatusStripProgressBarVisible { get; set; }
    3434
    35     Icon Icon { get; set; }
     35    Icon Icon { get; set; }
     36    Cursor Cursor { get; set; }
    3637
    3738    IView ActiveView { get; }
  • trunk/sources/HeuristicLab.MainForm/3.2/MainFormBase.cs

    r2336 r2338  
    7272    }
    7373
    74     public bool StatusStripProgressBarVisible  {
     74    public bool StatusStripProgressBarVisible {
    7575      get { return this.toolStripProgressBar.Visible; }
    7676      set {
     
    8080        } else
    8181          this.toolStripProgressBar.Visible = value;
     82      }
     83    }
     84
     85    Cursor IMainForm.Cursor {
     86      get { return base.Cursor; }
     87      set {
     88        if (InvokeRequired) {
     89          Action<Cursor> action = delegate(Cursor c) { this.Cursor = c; };
     90          Invoke(action, new object[] { value });
     91        } else
     92          base.Cursor = value;
     93      }
     94    }
     95
     96    Icon IMainForm.Icon {
     97      get { return base.Icon; }
     98      set {
     99        if (InvokeRequired) {
     100          Action<Icon> action = delegate(Icon i) { this.Icon = i; };
     101          Invoke(action, new object[] { value });
     102        } else
     103          base.Icon = value;
    82104      }
    83105    }
Note: See TracChangeset for help on using the changeset viewer.