void ChatClient::updatePresence(int presence) { auto chatee = chatroom_->getChatee(clientName_); if(chatee != nullptr) { auto userChange = std::make_unique<UserChange>(); userChange->mutable_user()->CopyFrom(chatee->user()); userChange->set_presence(static_cast<UserPresence>(presence)); sendAnyMessage(MessageBuilder::build(std::move(userChange))); } }
void Gmconf::PersonalDetails::set_presence_info (const std::string _presence, const std::string _note) { presence = _presence; note = _note; set_presence (_presence); set_note (_note); updated (); }