|
|
@@ -22,7 +22,7 @@ namespace entt {
|
|
|
/*! @cond TURN_OFF_DOXYGEN */
|
|
|
namespace internal {
|
|
|
|
|
|
-template<typename Entity, typename OnEntity>
|
|
|
+template<entity_like Entity, typename OnEntity>
|
|
|
static void present_element(const meta_any &obj, OnEntity on_entity) {
|
|
|
for([[maybe_unused]] const auto [id, data]: obj.type().data()) {
|
|
|
const auto elem = data.get(obj);
|
|
|
@@ -133,7 +133,7 @@ static void present_element(const meta_any &obj, OnEntity on_entity) {
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-template<typename Entity, typename Allocator>
|
|
|
+template<entity_like Entity, typename Allocator>
|
|
|
static void present_storage(const meta_ctx &ctx, const basic_sparse_set<Entity, Allocator> &storage) {
|
|
|
if(auto type = resolve(ctx, storage.info()); type) {
|
|
|
for(auto entt: storage) {
|
|
|
@@ -158,7 +158,7 @@ static void present_storage(const meta_ctx &ctx, const basic_sparse_set<Entity,
|
|
|
}
|
|
|
}
|
|
|
|
|
|
-template<typename Entity, typename It>
|
|
|
+template<entity_like Entity, typename It>
|
|
|
static void present_entity(const meta_ctx &ctx, const Entity entt, const It from, const It to) {
|
|
|
for(auto it = from; it != to; ++it) {
|
|
|
if(const auto &storage = it->second; storage.contains(entt)) {
|
|
|
@@ -234,7 +234,7 @@ static void present_view(const meta_ctx &ctx, const basic_view<get_t<Get...>, ex
|
|
|
* @param ctx The context from which to search for meta types.
|
|
|
* @param storage An instance of the storage type.
|
|
|
*/
|
|
|
-template<typename Type, typename Entity, typename Allocator>
|
|
|
+template<typename Type, entity_like Entity, typename Allocator>
|
|
|
void davey(const meta_ctx &ctx, const basic_storage<Type, Entity, Allocator> &storage) {
|
|
|
internal::present_storage(ctx, storage);
|
|
|
}
|
|
|
@@ -246,7 +246,7 @@ void davey(const meta_ctx &ctx, const basic_storage<Type, Entity, Allocator> &st
|
|
|
* @tparam Allocator Storage allocator type.
|
|
|
* @param storage An instance of the storage type.
|
|
|
*/
|
|
|
-template<typename Type, typename Entity, typename Allocator>
|
|
|
+template<typename Type, entity_like Entity, typename Allocator>
|
|
|
void davey(const basic_storage<Type, Entity, Allocator> &storage) {
|
|
|
davey(locator<meta_ctx>::value_or(), storage);
|
|
|
}
|
|
|
@@ -281,7 +281,7 @@ void davey(const basic_view<get_t<Get...>, exclude_t<Exclude...>> &view) {
|
|
|
* @param ctx The context from which to search for meta types.
|
|
|
* @param registry An instance of the registry type.
|
|
|
*/
|
|
|
-template<typename Entity, typename Allocator>
|
|
|
+template<entity_like Entity, typename Allocator>
|
|
|
void davey(const meta_ctx &ctx, const basic_registry<Entity, Allocator> ®istry) {
|
|
|
ImGui::BeginTabBar("#tabs");
|
|
|
|
|
|
@@ -325,7 +325,7 @@ void davey(const meta_ctx &ctx, const basic_registry<Entity, Allocator> ®istr
|
|
|
* @tparam Allocator Registry allocator type.
|
|
|
* @param registry An instance of the registry type.
|
|
|
*/
|
|
|
-template<typename Entity, typename Allocator>
|
|
|
+template<entity_like Entity, typename Allocator>
|
|
|
void davey(const basic_registry<Entity, Allocator> ®istry) {
|
|
|
davey(locator<meta_ctx>::value_or(), registry);
|
|
|
}
|