Cogs.Core
Extensions
Gui
Source
GuiManager.h
1
#pragma once
2
3
#include "Resources/ResourceManager.h"
4
5
#include "GuiDocument.h"
6
7
namespace
Cogs
8
{
9
namespace
Core
10
{
11
struct
GuiLoadInfo
:
public
ResourceLoadInfoBase
12
{
13
14
};
15
16
class
GuiManager
:
public
ResourceManager
<GuiDocument, GuiLoadInfo>,
public
IValueTypeManager
17
{
18
public
:
19
GuiManager
(
Context
* context) :
ResourceManager
(context) {
20
this->resourceType = ResourceTypes::Gui;
21
}
22
~GuiManager
()
override
;
23
24
void
initialize()
override
;
25
26
GuiDocumentHandle
load(
const
StringView
& source, ResourceId resourceId);
27
28
void
handleLoad
(
GuiLoadInfo
* loadInfo)
override
;
29
30
bool
doesManage(
DefaultValueType
valueType)
override
;
31
32
void
readSource(
Context
* ctx,
ResourceDefinition
& definition,
const
void
* jsonResource)
override
;
33
34
void
applyFieldValue(
void
*
object
,
const
Reflection::Field
* field,
const
FieldValue
& fieldValue)
override
;
35
};
36
}
37
}
Cogs::Core::Context
A Context instance contains all the services, systems and runtime components needed to use Cogs.
Definition:
Context.h:83
Cogs::Core::GuiManager
Definition:
GuiManager.h:17
Cogs::Core::GuiManager::handleLoad
void handleLoad(GuiLoadInfo *loadInfo) override
Handler for resource loading.
Definition:
GuiManager.cpp:26
Cogs::Core::IValueTypeManager
Definition:
ResourceManager.h:36
Cogs::Core::ResourceManager
The generic resource manager provides a base implementation for specialized resource managers to buil...
Definition:
ResourceManager.h:76
Cogs::Reflection::Field
Field definition describing a single data member of a data structure.
Definition:
Field.h:68
Cogs::StringView
Provides a weakly referenced view over the contents of a string.
Definition:
StringView.h:24
Cogs::Core::DefaultValueType
DefaultValueType
Defines value types for default values.
Definition:
EntityDefinition.h:35
Cogs
Contains all Cogs related functionality.
Definition:
FieldSetter.h:23
Cogs::Core::FieldValue
Defines a value to apply to a field.
Definition:
EntityDefinition.h:76
Cogs::Core::GuiLoadInfo
Definition:
GuiManager.h:12
Cogs::Core::ResourceDefinition
Definition:
AssetDefinition.h:234
Cogs::Core::ResourceHandle_t< GuiDocument >
Cogs::Core::ResourceLoadInfoBase
Definition:
ResourceLoadInfo.h:17
Generated by
1.9.6