public void GoToStateEvent(KeyValuePair <int, BioStateEvent> targetEvent) { if ((bool)ConsequenceMapControl?.StateEvents.Contains(targetEvent)) { MainTabControl.SelectedValue = ConsequenceMapControl; ConsequenceMapControl.SelectStateEvent(targetEvent); } else { MainTabControl.SelectedValue = StateEventMapControl; StateEventMapControl.SelectStateEvent(targetEvent); } }