add view cursers and small refactor

This commit is contained in:
Green Sky 2024-04-14 11:09:55 +02:00
parent 7c28b232a4
commit f9f70a05b1
No known key found for this signature in database
4 changed files with 28 additions and 4 deletions

View File

@ -5,6 +5,7 @@ add_library(solanaceae_message3
./solanaceae/message3/file_w_file.hpp
./solanaceae/message3/file_rw_file.hpp
./solanaceae/message3/message.hpp
./solanaceae/message3/components.hpp
./solanaceae/message3/components_id.inl

View File

@ -2,6 +2,8 @@
#include <solanaceae/contact/contact_model3.hpp>
#include "./message.hpp"
//fwd
struct FileI;
@ -14,11 +16,11 @@ struct FileI;
namespace Message::Components {
struct ContactFrom {
Contact3 c;
Contact3 c{entt::null};
};
struct ContactTo {
Contact3 c;
Contact3 c{entt::null};
};
// best guess as to how this should be displayed in the global order
@ -152,6 +154,21 @@ namespace Message::Components {
} // Transfer
// points to the front/newer message
// together they define a range that is,
// eg the first(end) and last(begin) message being eg. rendered
// MFS requires there to be atleast one other fragment after/before,
// if not loaded fragment with fitting tsrange(direction) available
// uses fragmentAfter/Before()
// they can exist standalone (wip)
// if they are a pair, the inside is filled first
struct ViewCurserBegin {
Message3 curser_end{entt::null};
};
struct ViewCurserEnd {
Message3 curser_begin{entt::null};
};
} // Message::Components
#include "./components_id.inl"

View File

@ -0,0 +1,7 @@
#pragma once
#include <cstdint>
// strong typing
enum class Message3 : uint32_t {};

View File

@ -2,6 +2,7 @@
#include <solanaceae/util/event_provider.hpp>
#include "./message.hpp"
#include "./message_model3.hpp"
#include <entt/entity/registry.hpp>
@ -10,8 +11,6 @@
#include <memory>
// strong typing
enum class Message3 : uint32_t {};
using Message3Registry = entt::basic_registry<Message3>;
using Message3Handle = entt::basic_handle<Message3Registry>;