public ControlVisibilityElementsOfChatMenuViewModel(IHandlerConnection handlerConnection, IHandlerMessages handlerMessages, IHandlerChats handlerChats) { ControlNavigationChatsViewModel = new ControlNavigationChatsViewModel(handlerConnection, handlerMessages, handlerChats); CreateChat = new CreateChatViewModel(handlerConnection, handlerChats) { VisibilityCreateChat = Visibility.Hidden }; ControlNavigationChatsViewModel.VisibilityNavigationChat = Visibility.Visible; }
public HandlerChats(ITransportClient transportClient, IHandlerConnection handlerConnection, IHandlerResponseFromServer handlerResponseFromServer, IClientInfo clientInfo) { _handlerConnection = handlerConnection; _clientInfo = clientInfo; _transportClient = transportClient; handlerResponseFromServer.AddedChat += OnAddedChat; handlerResponseFromServer.AddedClientsToChat += OnAddedClientsToChat; handlerResponseFromServer.RemovedClientsFromChat += OnRemovedClientsFromChat; handlerResponseFromServer.ResponseNumbersChats += OnResponseNumbersChats; handlerResponseFromServer.ReceivedInfoAboutAllClients += OnReceivedInfoAboutAllClients; handlerResponseFromServer.RemovedChat += OnRemovedChat; }