mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-11-29 22:28:49 +03:00
Fix all rooms being opened on startup
This commit is contained in:
parent
995b62122a
commit
5287ba38f9
2 changed files with 3 additions and 1 deletions
|
@ -140,7 +140,7 @@ ChatPage::ChatPage(QSharedPointer<UserSettings> userSettings, QWidget *parent)
|
||||||
});
|
});
|
||||||
|
|
||||||
connect(this, &ChatPage::leftRoom, this, &ChatPage::removeRoom);
|
connect(this, &ChatPage::leftRoom, this, &ChatPage::removeRoom);
|
||||||
connect(this, &ChatPage::newRoom, this, &ChatPage::changeRoom, Qt::QueuedConnection);
|
connect(this, &ChatPage::changeToRoom, this, &ChatPage::changeRoom, Qt::QueuedConnection);
|
||||||
connect(this, &ChatPage::notificationsRetrieved, this, &ChatPage::sendNotifications);
|
connect(this, &ChatPage::notificationsRetrieved, this, &ChatPage::sendNotifications);
|
||||||
connect(this,
|
connect(this,
|
||||||
&ChatPage::highlightedNotifsRetrieved,
|
&ChatPage::highlightedNotifsRetrieved,
|
||||||
|
@ -751,6 +751,7 @@ ChatPage::createRoom(const mtx::requests::CreateRoom &req)
|
||||||
QString newRoomId = QString::fromStdString(res.room_id.to_string());
|
QString newRoomId = QString::fromStdString(res.room_id.to_string());
|
||||||
emit showNotification(tr("Room %1 created.").arg(newRoomId));
|
emit showNotification(tr("Room %1 created.").arg(newRoomId));
|
||||||
emit newRoom(newRoomId);
|
emit newRoom(newRoomId);
|
||||||
|
emit changeToRoom(newRoomId);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -125,6 +125,7 @@ signals:
|
||||||
void newSyncResponse(const mtx::responses::Sync &res, const std::string &prev_batch_token);
|
void newSyncResponse(const mtx::responses::Sync &res, const std::string &prev_batch_token);
|
||||||
void leftRoom(const QString &room_id);
|
void leftRoom(const QString &room_id);
|
||||||
void newRoom(const QString &room_id);
|
void newRoom(const QString &room_id);
|
||||||
|
void changeToRoom(const QString &room_id);
|
||||||
|
|
||||||
void initializeViews(const mtx::responses::Rooms &rooms);
|
void initializeViews(const mtx::responses::Rooms &rooms);
|
||||||
void initializeEmptyViews();
|
void initializeEmptyViews();
|
||||||
|
|
Loading…
Reference in a new issue