mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-10-01 11:22:00 +00:00
Isolate lib_base library. Use crl::time in getms.
This commit is contained in:
@@ -25,3 +25,14 @@ inline constexpr size_t array_size(const Type(&)[Size]) {
|
||||
}
|
||||
|
||||
} // namespace base
|
||||
|
||||
template <typename T>
|
||||
inline void accumulate_max(T &a, const T &b) { if (a < b) a = b; }
|
||||
|
||||
template <typename T>
|
||||
inline void accumulate_min(T &a, const T &b) { if (a > b) a = b; }
|
||||
|
||||
template <size_t Size>
|
||||
QLatin1String qstr(const char(&string)[Size]) {
|
||||
return QLatin1String(string, Size - 1);
|
||||
}
|
||||
|
Reference in New Issue
Block a user