Created
January 19, 2009 19:33
-
-
Save mariusz/49122 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| private Dictionary<Side, double> GetValuesForSecondBoundry() | |
| { | |
| Dictionary<Side, double> dict = new Dictionary<Side, double>(); | |
| List<Side> sides = EnumToList<Side>(); | |
| for (int i = 0; i < this.SideAreaSecondConditionsList.Items.Count; i++) | |
| { | |
| int id = int.Parse(this.SideAreaSecondConditionsList.Items[i].SubItems[2].Text); | |
| dict.Add(sides[id], getValueAsDouble(this.SideAreaSecondConditionsList.Items[i].SubItems[1].Text)); | |
| } | |
| return dict; | |
| } | |
| private void AddSecondConditionFromDict(double[] values, string[] keys) | |
| { | |
| List<Side> sides = EnumToList<Side>(); | |
| this.SideAreaSecondConditionsList.Items.Clear(); | |
| for(int i = 0; i < values.Length; i++) | |
| { | |
| int id = int.Parse(keys[i]); | |
| this.SideAreaSecondConditionsList.Items.Add(new ListViewItem(new string[] { sides[id].ToString(), values[i].ToString(), keys[i].ToString() })); | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment