1 using System;
2 using System.Collections.Generic;
3 using System.ComponentModel;
4 using System.Data;
5 using System.Drawing;
6 using System.Text;
7 using System.Windows.Forms;
8 
9 namespace MogreFramework
10 {
11     internal partial class Splash : Form
12     {
13         #region Constructor
14         /// <summary>
15         /// Constructor.
16         /// </summary>
Splash()17         public Splash()
18         {
19             InitializeComponent();
20         }
21         #endregion
22 
23         #region Public Methods
24         /// <summary>
25         /// Increments the progress bar and sets the string to be displayed.
26         /// </summary>
27         /// <param name="text"></param>
Increment(string text)28         public void Increment(string text)
29         {
30             Progress.Increment(1);
31             LoadingText.Text = text;
32 
33             Update();
34             Application.DoEvents();
35         }
36 
37         /// <summary>
38         /// Does the same as Form.Show, except that it pumps the event queue once after
39         /// showing the dialog.
40         /// </summary>
Show()41         public new void Show()
42         {
43             base.Show();
44             Application.DoEvents();
45         }
46         #endregion
47     }
48 }
49