/// <summary> /// Occurs when setting symbology to a new scheme and allows adding event handlers /// </summary> /// <param name="scheme"> /// </param> protected virtual void OnIncludeScheme(IFeatureScheme scheme) { if (scheme == null) { return; } scheme.ItemChanged += SchemeItemChanged; scheme.SetParentItem(this); scheme.SelectFeatures += OnSelectFeatures; scheme.DeselectFeatures += OnDeselectFeatures; }
/// <summary> /// Occurs when setting the symbology to a new scheme and allows removing event handlers /// </summary> /// <param name="scheme"></param> protected virtual void OnExcludeScheme(IFeatureScheme scheme) { if (scheme == null) return; scheme.ItemChanged -= SchemeItemChanged; scheme.SetParentItem(null); scheme.SelectFeatures -= OnSelectFeatures; }