//opens block from closure private void openBlockButton_Click(object sender, EventArgs e) { //Block block = findBlock(blockSelected); //if (currentLineSelection == 2) foreach (Block b in myBlockList) { if ((currentLineSelection == 2) && (b.blockNum == blockSelected - 1)) { TrackControllerModule.openBlock(b.blockId); foreach (ListViewItem item in systemListView.Items) { if (item.Index == (b.blockNum)) { item.SubItems[1] = new ListViewItem.ListViewSubItem() { Text = "Open " }; } } } if ((currentLineSelection == 1) && (b.blockNum == blockSelected - 1)) { TrackControllerModule.openBlock(b.blockId); foreach (ListViewItem item in systemListView2.Items) { if (item.Index == (b.blockNum)) { item.SubItems[1] = new ListViewItem.ListViewSubItem() { Text = "Open " }; } } } } }
//fix track after failure private void fixTrackButton_Click(object sender, EventArgs e) { TrackControllerModule.openBlock(blockSelected); notifLabel.Text = ("Everything is better"); }