public void Remove(INotifyPropertyChanged obj) { var message = new RemoveMessage { ObjectId = Objects[obj] }; Objects.Remove(obj); _transport.Send(Json.Serialize(message)); }
private void Handle(RemoveMessage removeMessage) { var objKey = Objects.FirstOrDefault(kvp => kvp.Value == removeMessage.ObjectId).Key; if (objKey == null || !Objects.ContainsKey(objKey)) { return; } Objects.Remove(objKey); Collection.Remove(objKey); }
private void Handle(RemoveMessage removeMessage) { var objKey = Objects.FirstOrDefault(kvp => kvp.Value == removeMessage.ObjectId).Key; if (objKey == null || !Objects.ContainsKey(objKey)) return; Objects.Remove(objKey); Collection.Remove(objKey); }