mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-15 21:57:10 +02:00
Fixed opening message from media player widget in corresponding window.
This commit is contained in:
parent
86b9d16747
commit
ce596e29c4
1 changed files with 7 additions and 0 deletions
|
@ -811,6 +811,13 @@ void MainWidget::createPlayer() {
|
|||
});
|
||||
_player->entity()->setShowItemCallback([=](
|
||||
not_null<const HistoryItem*> item) {
|
||||
const auto peer = item->history()->peer;
|
||||
if (const auto window = Core::App().windowFor(peer)) {
|
||||
if (const auto controller = window->sessionController()) {
|
||||
controller->showMessage(item);
|
||||
return;
|
||||
}
|
||||
}
|
||||
_controller->showMessage(item);
|
||||
});
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue