update rate limit indicator on failed message send

this happens when you start the client while already rate-limited
This commit is contained in:
ouwou
2021-04-14 02:11:36 -04:00
parent 9a7a468607
commit 9733ae54c3
8 changed files with 45 additions and 5 deletions

View File

@@ -365,7 +365,7 @@ void ChatWindow::ScrollToBottom() {
x->set_value(x->get_upper());
}
void ChatWindow::OnMessageSendFail(const std::string &nonce) {
void ChatWindow::OnMessageSendFail(const std::string &nonce, float retry_after) {
for (auto [id, widget] : m_id_to_widget) {
if (auto *container = dynamic_cast<ChatMessageItemContainer *>(widget); container->Nonce == nonce) {
container->SetFailed();