private EditableLookup <string, WeakAction> _ensureListeners() { if (_listeners == null) { _listeners = new EditableLookup <string, WeakAction>(); } return(_listeners); }
public static EditableLookup <K, T> ToEditableLookup <K, T>(this Dictionary <K, List <T> > source) { var res = new EditableLookup <K, T>(); foreach (var k in source.Keys) { res.Reset(k, source[k]); } return(res); }