mirror of
https://hubproxy.babadafafafafa.cn/https://github.com/telegramdesktop/tdesktop
synced 2026-09-20 08:03:45 +08:00
Hide gift value details tooltips on click.
This commit is contained in:
@@ -10,6 +10,7 @@ https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
|
||||
#include "api/api_premium.h"
|
||||
#include "api/api_premium_option.h"
|
||||
#include "apiwrap.h"
|
||||
#include "base/event_filter.h"
|
||||
#include "base/timer_rpl.h"
|
||||
#include "base/unixtime.h"
|
||||
#include "base/weak_ptr.h"
|
||||
@@ -106,6 +107,13 @@ void ShowInfoTooltip(
|
||||
st::defaultImportantTooltip);
|
||||
tooltip->toggleFast(false);
|
||||
|
||||
base::install_event_filter(tooltip, qApp, [=](not_null<QEvent*> e) {
|
||||
if (e->type() == QEvent::MouseButtonPress) {
|
||||
tooltip->toggleAnimated(false);
|
||||
}
|
||||
return base::EventFilterResult::Continue;
|
||||
});
|
||||
|
||||
const auto update = [=] {
|
||||
const auto geometry = Ui::MapFrom(parent, target, target->rect());
|
||||
const auto countPosition = [=](QSize size) {
|
||||
|
||||
Submodule Telegram/lib_ui updated: 92f7e78d2d...114fd95c75
Reference in New Issue
Block a user