private void DgFacts_CellDoubleClick(object sender, DataGridViewCellEventArgs e) { if (e.RowIndex >= 0 && e.ColumnIndex >= 0) { this.Cursor = Cursors.WaitCursor; IDisplayFact fact = (IDisplayFact)dgFacts.CurrentRow.DataBoundItem; mh.OpenGeoLocations(fact.Location, outputText); this.Cursor = Cursors.Default; } }
public static bool ContainsFact(this SortableBindingList <IDisplayFact> list, IDisplayFact fact) { if (list != null) { for (int i = 0; i < list.Count; i++) { if (list[i] == fact) { return(true); } } } return(false); }