internal void RefreshFeatureInteractors() { var selectedFeaturesWithLayer = SelectedFeatureInteractors.Select(fe => new { Feature = fe.SourceFeature, fe.Layer }).ToList(); SelectedFeatureInteractors.Clear(); selectedFeaturesWithLayer.ForEach(fl => SelectedFeatureInteractors.Add(GetFeatureInteractor(fl.Layer, fl.Feature))); SynchronizeTrackers(); }
public void AddSelection(ILayer layer, IFeature feature, bool synchronizeUI = true) { if (!layer.Visible) { return; } var featureInteractor = GetFeatureInteractor(layer, feature); if (null == featureInteractor) { return; } SelectedFeatureInteractors.Add(featureInteractor); if (synchronizeUI) { UpdateMapControlSelection(); } }
private bool StartSelection(ILayer layer, IFeature feature) { var featureInteractor = GetFeatureInteractor(layer, feature); if (null == featureInteractor) { return(false); } if (featureInteractor.AllowSingleClickAndMove()) { // do not yet select, but allow MltiSelect SelectedFeatureInteractors.Add(featureInteractor); SynchronizeTrackers(); UpdateMapControlSelection(); return(true); } return(false); }