main
 1using System.Windows.Forms;
 2using momoney.presentation.views;
 3using MoMoney.Presentation.Views;
 4using MoMoney.Presentation.Winforms.Resources;
 5
 6namespace MoMoney.Presentation.Winforms.Views
 7{
 8    public class StatusBarView : IStatusBarView
 9    {
10        readonly IRegionManager shell;
11
12        public StatusBarView(IRegionManager shell)
13        {
14            this.shell = shell;
15        }
16
17        public void display(HybridIcon icon_to_display, string text_to_display)
18        {
19            shell.region<ToolStripStatusLabel>(x =>
20                                                   {
21                                                       x.Text = text_to_display;
22                                                       x.Image = icon_to_display;
23                                                   });
24        }
25
26        public void reset_progress_bar()
27        {
28            shell.region<ToolStripProgressBar>(x => { x.ProgressBar.Value = 0; });
29        }
30
31        public void notify()
32        {
33            shell.region<ToolStripProgressBar>(x => { x.Increment(10); });
34        }
35    }
36}