mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-08-30 22:16:14 +00:00
Added initial implementation of cancel of media uploading for editing.
This commit is contained in:
@@ -842,11 +842,16 @@ void MainWidget::cancelUploadLayer(not_null<HistoryItem*> item) {
|
||||
Ui::hideLayer();
|
||||
if (const auto item = App::histItemById(itemId)) {
|
||||
const auto history = item->history();
|
||||
//item->destroy();
|
||||
history->requestChatListMessage();
|
||||
if (!item->isEditingMedia()) {
|
||||
item->destroy();
|
||||
history->requestChatListMessage();
|
||||
} else {
|
||||
item->returnSavedMedia();
|
||||
session().uploader().cancel(item->fullId());
|
||||
}
|
||||
session().data().sendHistoryChangeNotifications();
|
||||
}
|
||||
//session().uploader().unpause();
|
||||
session().uploader().unpause();
|
||||
};
|
||||
const auto continueUpload = [=] {
|
||||
session().uploader().unpause();
|
||||
|
Reference in New Issue
Block a user