Free cookie consent management tool by TermsFeed Policy Generator

Changeset 2334


Ignore:
Timestamp:
09/04/09 15:35:28 (15 years ago)
Author:
mkommend
Message:

added progressBar to the status strip (ticket #716)

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

Legend:

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

    r2305 r2334  
    2525using System.Text;
    2626using System.Drawing;
     27using System.Windows.Forms;
    2728
    2829namespace HeuristicLab.MainForm {
     
    3031    string Title { get; set; }
    3132    string StatusStripText { get; set; }
     33    bool StatusStripProgressBarVisible { get; set; }
     34
    3235    Icon Icon { get; set; }
    3336
  • trunk/sources/HeuristicLab.MainForm/3.2/MainFormBase.Designer.cs

    r2268 r2334  
    2727      this.toolStrip = new System.Windows.Forms.ToolStrip();
    2828      this.statusStrip = new System.Windows.Forms.StatusStrip();
    29       this.statusStripLabel = new System.Windows.Forms.ToolStripStatusLabel();
     29      this.toolStripProgressBar = new System.Windows.Forms.ToolStripProgressBar();
     30      this.toolStripStatusLabel = new System.Windows.Forms.ToolStripStatusLabel();
    3031      this.statusStrip.SuspendLayout();
    3132      this.SuspendLayout();
     
    4950      //
    5051      this.statusStrip.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
    51             this.statusStripLabel});
     52            this.toolStripProgressBar,
     53            this.toolStripStatusLabel});
    5254      this.statusStrip.Location = new System.Drawing.Point(0, 390);
    5355      this.statusStrip.Name = "statusStrip";
     
    5658      this.statusStrip.Text = "statusStrip";
    5759      //
    58       // statusStripLabel
     60      // toolStripProgressBar
    5961      //
    60       this.statusStripLabel.Name = "statusStripLabel";
    61       this.statusStripLabel.Size = new System.Drawing.Size(0, 17);
     62      this.toolStripProgressBar.Name = "toolStripProgressBar";
     63      this.toolStripProgressBar.Size = new System.Drawing.Size(100, 16);
     64      this.toolStripProgressBar.Style = System.Windows.Forms.ProgressBarStyle.Marquee;
     65      this.toolStripProgressBar.Visible = false;
     66      //
     67      // toolStripStatusLabel
     68      //
     69      this.toolStripStatusLabel.Name = "toolStripStatusLabel";
     70      this.toolStripStatusLabel.Size = new System.Drawing.Size(112, 17);
     71      this.toolStripStatusLabel.Text = "toolStripStatusLabel";
    6272      //
    6373      // MainFormBase
     
    8292    private System.Windows.Forms.ToolStrip toolStrip;
    8393    private System.Windows.Forms.StatusStrip statusStrip;
    84     private System.Windows.Forms.ToolStripStatusLabel statusStripLabel;
    8594    protected System.Windows.Forms.MenuStrip menuStrip;
     95    private System.Windows.Forms.ToolStripProgressBar toolStripProgressBar;
     96    private System.Windows.Forms.ToolStripStatusLabel toolStripStatusLabel;
    8697  }
    8798}
  • trunk/sources/HeuristicLab.MainForm/3.2/MainFormBase.cs

    r2309 r2334  
    3838      views = new List<IView>();
    3939      toolStripItems = new List<IToolStripItem>();
     40      this.StatusStripText = "";
    4041    }
    4142
     
    6162
    6263    public string StatusStripText {
    63       get { return this.statusStripLabel.Text; }
     64      get { return this.toolStripStatusLabel.Text; }
    6465      set {
    6566        if (InvokeRequired) {
     
    6768          Invoke(action, new object[] { value });
    6869        } else
    69           this.statusStripLabel.Text = value;
     70          this.toolStripStatusLabel.Text = value;
     71      }
     72    }
     73
     74    public bool StatusStripProgressBarVisible  {
     75      get { return this.toolStripProgressBar.Visible; }
     76      set {
     77        if (InvokeRequired) {
     78          Action<bool> action = delegate(bool b) { this.toolStripProgressBar.Visible = b; };
     79          Invoke(action, new object[] { value });
     80        } else
     81          this.toolStripProgressBar.Visible = value;
    7082      }
    7183    }
Note: See TracChangeset for help on using the changeset viewer.