private void ListPatriarchs_DblClick(object sender, EventArgs e) { GKListItem item = ListPatriarchs.GetSelectedItem(); if (item == null) { return; } GEDCOMIndividualRecord iRec = item.Data as GEDCOMIndividualRecord; if (iRec == null) { return; } Base.SelectRecordByXRef(iRec.XRef); Close(); }
private void ListChecks_DblClick(object sender, EventArgs e) { GKListItem item = ListChecks.GetSelectedItem(); if (item == null) { return; } GEDCOMIndividualRecord iRec = ((TreeTools.CheckObj)item.Data).Rec as GEDCOMIndividualRecord; if (iRec == null) { return; } Base.SelectRecordByXRef(iRec.XRef); Close(); }
private void ListPlaces_DblClick(object sender, EventArgs e) { GKListItem item = ListPlaces.GetSelectedItem(); if (item == null) { return; } PlaceObj pObj = item.Data as PlaceObj; if (pObj == null) { return; } if (pObj.Name.IndexOf("[*]") == 0) { AppHost.StdDialogs.ShowMessage(LangMan.LS(LSID.LSID_PlaceAlreadyInBook)); } else { GEDCOMLocationRecord loc = fBase.Context.SelectRecord(GEDCOMRecordType.rtLocation, new object[] { pObj.Name }) as GEDCOMLocationRecord; if (loc == null) { return; } int num = pObj.Facts.Count; for (int i = 0; i < num; i++) { GEDCOMCustomEvent evt = pObj.Facts[i]; evt.Place.StringValue = loc.LocationName; evt.Place.Location.Value = loc; } CheckPlaces(); Base.RefreshLists(false); } }