mirror of
https://github.com/kotatogram/kotatogram-desktop
synced 2025-08-31 06:35:14 +00:00
Move EmojiPanel bottom controls to Controller.
Open sticker set by click on the name. Add a delete sticker set button.
This commit is contained in:
@@ -527,18 +527,6 @@ enum DBIScale {
|
||||
|
||||
static const int MatrixRowShift = 40000;
|
||||
|
||||
enum DBIEmojiSection {
|
||||
dbiesRecent = -1,
|
||||
dbiesPeople = 0,
|
||||
dbiesNature = 1,
|
||||
dbiesFood = 2,
|
||||
dbiesActivity = 3,
|
||||
dbiesTravel = 4,
|
||||
dbiesObjects = 5,
|
||||
dbiesSymbols = 6,
|
||||
dbiesStickers = 666,
|
||||
};
|
||||
|
||||
enum DBIPlatform {
|
||||
dbipWindows = 0,
|
||||
dbipMac = 1,
|
||||
|
@@ -28,9 +28,22 @@ namespace base {
|
||||
template <typename... Types>
|
||||
using variant = mapbox::util::variant<Types...>;
|
||||
|
||||
template <typename... Types>
|
||||
using optional_variant = variant<std::nullptr_t, Types...>;
|
||||
|
||||
template <typename T, typename... Types>
|
||||
inline T *get_if(variant<Types...> *v) {
|
||||
return (v && v->template is<T>()) ? &v->template get_unchecked<T>() : nullptr;
|
||||
}
|
||||
|
||||
template <typename T, typename... Types>
|
||||
inline const T *get_if(const variant<Types...> *v) {
|
||||
return (v && v->template is<T>()) ? &v->template get_unchecked<T>() : nullptr;
|
||||
}
|
||||
|
||||
template <typename... Types>
|
||||
inline bool is_null_variant(const optional_variant<Types...> &variant) {
|
||||
return get_if<std::nullptr_t>(&variant) != nullptr;
|
||||
}
|
||||
|
||||
} // namespace base
|
||||
|
Reference in New Issue
Block a user