-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMeterForm.cs
57 lines (50 loc) · 1010 Bytes
/
MeterForm.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
using System;
using System.ComponentModel;
using System.Drawing;
using System.Windows.Forms;
using AODPSo.Properties;
namespace AODPSo
{
public partial class MeterForm : Form
{
public string labelText
{
get
{
return this._labelText;
}
set
{
this._labelText = value;
this.updateLabelText(this._labelText);
}
}
public Label pubLabel
{
get { return label1; }
}
public MeterForm()
{
this.InitializeComponent();
label1.Text = "just passing";
}
private void Mload(object sender, EventArgs e)
{
}
private void updateLabelText(string newText)
{
if (this.label1.InvokeRequired)
{
MeterForm.updateLabelTextDelegate del = new MeterForm.updateLabelTextDelegate(this.updateLabelText);
this.label1.Invoke(del, new object[]
{
newText
});
return;
}
this.label1.Text = newText;
}
private string _labelText;
private delegate void updateLabelTextDelegate(string newText);
}
}