mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-19 07:37:11 +02:00
Close media viewer when photo message is deleted.
This commit is contained in:
parent
3d54a263b8
commit
f064692e57
1 changed files with 2 additions and 1 deletions
|
@ -3676,7 +3676,8 @@ void OverlayWidget::setSession(not_null<Main::Session*> session) {
|
|||
|
||||
session->data().itemRemoved(
|
||||
) | rpl::filter([=](not_null<const HistoryItem*> item) {
|
||||
return (_document != nullptr) && (item->fullId() == _msgid);
|
||||
return (_document != nullptr || _photo != nullptr)
|
||||
&& (item->fullId() == _msgid);
|
||||
}) | rpl::start_with_next([=] {
|
||||
close();
|
||||
}, _sessionLifetime);
|
||||
|
|
Loading…
Add table
Reference in a new issue