add comps root private and group

This commit is contained in:
Green Sky 2024-04-18 15:16:12 +02:00
parent e40271670b
commit 7710da6c89
No known key found for this signature in database
2 changed files with 14 additions and 0 deletions

View File

@ -12,8 +12,17 @@ namespace Contact::Components {
struct TagSelfWeak {}; struct TagSelfWeak {};
struct TagSelfStrong {}; struct TagSelfStrong {};
// root node contact (like an account)
struct TagRoot {};
// hint to display this contact in the contact list
struct TagBig {}; struct TagBig {};
// indicates to the UI, that this should be displayed like a 1to1 chat
struct TagPrivate {};
// indicates to the UI to show the subs list by default (overwritten by TagPrivate)
struct TagGroup {};
struct RequestIncoming { struct RequestIncoming {
bool name = false; bool name = false;
bool password = false; bool password = false;
@ -31,6 +40,8 @@ namespace Contact::Components {
}; };
// TODO: maybe rename to children // TODO: maybe rename to children
// subs are not exclusive (only is some protocols)
// this is not an indicator of a groupchat
struct ParentOf { struct ParentOf {
std::vector<Contact3> subs; std::vector<Contact3> subs;
}; };

View File

@ -20,7 +20,10 @@ constexpr std::string_view entt::type_name<x>::value() noexcept { \
DEFINE_COMP_ID(Contact::Components::TagSelfWeak) DEFINE_COMP_ID(Contact::Components::TagSelfWeak)
DEFINE_COMP_ID(Contact::Components::TagSelfStrong) DEFINE_COMP_ID(Contact::Components::TagSelfStrong)
DEFINE_COMP_ID(Contact::Components::TagRoot)
DEFINE_COMP_ID(Contact::Components::TagBig) DEFINE_COMP_ID(Contact::Components::TagBig)
DEFINE_COMP_ID(Contact::Components::TagPrivate)
DEFINE_COMP_ID(Contact::Components::TagGroup)
DEFINE_COMP_ID(Contact::Components::RequestIncoming) DEFINE_COMP_ID(Contact::Components::RequestIncoming)
DEFINE_COMP_ID(Contact::Components::TagRequestOutgoing) DEFINE_COMP_ID(Contact::Components::TagRequestOutgoing)
DEFINE_COMP_ID(Contact::Components::Self) DEFINE_COMP_ID(Contact::Components::Self)