annotate ServerMonitor/Controls/TimeUnitsComboBox.cs @ 3:96f0b028176d

File check
author Brad Greco <brad@bgreco.net>
date Fri, 11 Jan 2019 22:34:18 -0500
parents
children 7127d5b5ac75
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
3
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
1 using System;
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
2 using System.Collections.Generic;
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
3 using System.Linq;
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
4 using System.Text;
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
5 using System.Windows.Forms;
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
6
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
7 namespace ServerMonitorApp
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
8 {
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
9 class TimeUnitsComboBox : ComboBox
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
10 {
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
11 protected override void OnCreateControl()
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
12 {
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
13 base.OnCreateControl();
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
14 Items.Clear();
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
15 Items.Add("minutes");
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
16 Items.Add("hours");
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
17 Items.Add("days");
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
18 SelectedIndex = 2;
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
19 }
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
20 }
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
21
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
22 public enum TimeUnits { Minute = 0, Hour = 1, Day = 2 }
96f0b028176d File check
Brad Greco <brad@bgreco.net>
parents:
diff changeset
23 }