/// <summary> /// Adds a helper to the KVO system. Helpers "assist" classes with automatic /// KVO notifications. /// </summary> /// <param name="helper">The helper to add.</param> /// <param name="targetType">The type the helper is for.</param> public void RegisterHelperForType(KNKVOHelper helper, Type targetType) { helpers[targetType] = helper; }
public void HelperIsNoLongerNeeded(KNKVOHelper helper) { helper.Release(); if (helper.RetainCount() <= 0 && helperCache.ContainsValue(helper)) { helperCache.Remove(helper); } }