Files
futpib ec7c76b8d2 Cache Webview::Availability() result for startup checks
Iv::ShowButton() and LocationPicker::Available() each called
Webview::Availability() separately (~200ms each on Linux). Replace
the per-caller static caches with a single shared cache in
Core::CachedWebviewAvailability(), reducing startup from two
~200ms calls to one.
2026-03-05 16:13:38 +04:00

20 lines
481 B
C++

/*
This file is part of Telegram Desktop,
the official desktop application for the Telegram messaging service.
For license and copyright information please follow this link:
https://github.com/telegramdesktop/tdesktop/blob/master/LEGAL
*/
#pragma once
#include "webview/webview_interface.h"
namespace Core {
[[nodiscard]] inline const Webview::Available &CachedWebviewAvailability() {
static const auto result = Webview::Availability();
return result;
}
} // namespace Core