diff options
author | Nicolas Werner <nicolas.werner@hotmail.de> | 2020-09-03 19:34:17 +0200 |
---|---|---|
committer | Nicolas Werner <nicolas.werner@hotmail.de> | 2020-09-16 23:49:17 +0200 |
commit | 77e241b9e57a3248e2efb16e6cb081a19a666db7 (patch) | |
tree | e1f44e5b252ce2931d41dc57b10671efee58e58c /src/timeline | |
parent | Port top bar to Qml (diff) | |
download | nheko-77e241b9e57a3248e2efb16e6cb081a19a666db7.tar.xz |
Reenable top bar room settings menus on avatar or title clicks
Also fixes a bug with an empty room settings window introduced in the port.
Diffstat (limited to 'src/timeline')
-rw-r--r-- | src/timeline/TimelineModel.h | 1 | ||||
-rw-r--r-- | src/timeline/TimelineViewManager.cpp | 6 |
2 files changed, 4 insertions, 3 deletions
diff --git a/src/timeline/TimelineModel.h b/src/timeline/TimelineModel.h index 34f2f78a..1e482be2 100644 --- a/src/timeline/TimelineModel.h +++ b/src/timeline/TimelineModel.h @@ -260,6 +260,7 @@ public slots: QString roomName() const; QString roomTopic() const; QString roomAvatarUrl() const; + QString roomId() const { return room_id_; } private slots: void addPendingMessage(mtx::events::collections::TimelineEvents event); diff --git a/src/timeline/TimelineViewManager.cpp b/src/timeline/TimelineViewManager.cpp index 32d8b0b2..06f0fa3d 100644 --- a/src/timeline/TimelineViewManager.cpp +++ b/src/timeline/TimelineViewManager.cpp @@ -253,17 +253,17 @@ TimelineViewManager::openInviteUsersDialog() void TimelineViewManager::openMemberListDialog() const { - MainWindow::instance()->openMemberListDialog(); + MainWindow::instance()->openMemberListDialog(timeline_->roomId()); } void TimelineViewManager::openLeaveRoomDialog() const { - MainWindow::instance()->openLeaveRoomDialog(); + MainWindow::instance()->openLeaveRoomDialog(timeline_->roomId()); } void TimelineViewManager::openRoomSettings() const { - MainWindow::instance()->openRoomSettings(); + MainWindow::instance()->openRoomSettings(timeline_->roomId()); } void |