mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-09-04 08:35:21 +00:00
Pass reply info to Window::PeerMenu.
This commit is contained in:
@@ -1817,20 +1817,21 @@ void InnerWidget::contextMenuEvent(QContextMenuEvent *e) {
|
||||
} else if (const auto history = row.key.history()) {
|
||||
Window::FillPeerMenu(
|
||||
_controller,
|
||||
history->peer,
|
||||
_filterId,
|
||||
Window::PeerMenuRequest{
|
||||
.peer = history->peer,
|
||||
.source = Window::PeerMenuRequest::Source::ChatsList,
|
||||
.filterId = _filterId,
|
||||
},
|
||||
[&](const QString &text, Fn<void()> callback) {
|
||||
return _menu->addAction(text, std::move(callback));
|
||||
},
|
||||
Window::PeerMenuSource::ChatsList);
|
||||
});
|
||||
} else if (const auto folder = row.key.folder()) {
|
||||
Window::FillFolderMenu(
|
||||
_controller,
|
||||
folder,
|
||||
Window::FolderMenuRequest{ folder },
|
||||
[&](const QString &text, Fn<void()> callback) {
|
||||
return _menu->addAction(text, std::move(callback));
|
||||
},
|
||||
Window::PeerMenuSource::ChatsList);
|
||||
});
|
||||
}
|
||||
connect(_menu.get(), &QObject::destroyed, [=] {
|
||||
if (_menuRow.key) {
|
||||
|
Reference in New Issue
Block a user