예제 #1
0
        public void Dispose()
        {
            if (_isDisposed)
            {
                return;
            }
            _isDisposed = true;

            if (_collection is INotifyCollectionChanged)
            {
                CollectionChangedEventManager.RemoveHandler(_collection as INotifyCollectionChanged, HandleCollectionChange);
                _watcherList?.Dispose();
                _watcherList = null;
                _collection  = null;
                ItemModified = null;
            }
        }