mirror of
https://hubproxy.babadafafafafa.cn/https://github.com/telegramdesktop/tdesktop
synced 2026-09-21 00:23:56 +08:00
Added showing of error popup service notifications in article window.
This commit is contained in:
@@ -68,6 +68,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
||||
#include "base/unixtime.h"
|
||||
#include "window/window_session_controller.h"
|
||||
#include "window/window_controller.h"
|
||||
#include "iv/editor/iv_editor_session.h"
|
||||
#include "ui/boxes/confirm_box.h"
|
||||
#include "apiwrap.h"
|
||||
#include "ui/text/format_values.h" // Ui::FormatPhone
|
||||
@@ -2295,9 +2296,13 @@ void Updates::feedUpdate(const MTPUpdate &update) {
|
||||
} else if (IsWithdrawalNotification(d)) {
|
||||
return;
|
||||
} else if (d.is_popup()) {
|
||||
const auto &windows = session().windows();
|
||||
if (!windows.empty()) {
|
||||
windows.front()->window().show(Ui::MakeInformBox(text));
|
||||
if (const auto show = Iv::Editor::ActiveWindowShow(&session())) {
|
||||
show->showBox(Ui::MakeInformBox(text));
|
||||
} else {
|
||||
const auto &windows = session().windows();
|
||||
if (!windows.empty()) {
|
||||
windows.front()->window().show(Ui::MakeInformBox(text));
|
||||
}
|
||||
}
|
||||
} else {
|
||||
session().data().serviceNotification(
|
||||
|
||||
Reference in New Issue
Block a user