Improve #2270 by moving mehtod to cpp file
This commit is contained in:
@@ -198,6 +198,12 @@ void ContentService::Dispose()
|
||||
Graphics::DisposeDevice();
|
||||
}
|
||||
|
||||
IAssetFactory::Collection& IAssetFactory::Get()
|
||||
{
|
||||
static Collection Factories(1024);
|
||||
return Factories;
|
||||
}
|
||||
|
||||
AssetsCache* Content::GetRegistry()
|
||||
{
|
||||
return &Cache;
|
||||
@@ -912,8 +918,6 @@ bool Content::IsAssetTypeIdInvalid(const ScriptingTypeHandle& type, const Script
|
||||
return true;
|
||||
}
|
||||
|
||||
Dictionary<StringView, IAssetFactory*> IAssetFactory::Factories;
|
||||
|
||||
Asset* Content::LoadAsync(const Guid& id, const ScriptingTypeHandle& type)
|
||||
{
|
||||
if (!id.IsValid())
|
||||
|
||||
@@ -16,15 +16,11 @@ class FLAXENGINE_API IAssetFactory
|
||||
{
|
||||
public:
|
||||
typedef Dictionary<StringView, IAssetFactory*> Collection;
|
||||
static Collection Factories;
|
||||
|
||||
/// <summary>
|
||||
/// Gets the all registered assets factories. Key is asset typename, value is the factory object.
|
||||
/// </summary>
|
||||
static Collection& Get()
|
||||
{
|
||||
return Factories;
|
||||
}
|
||||
static Collection& Get();
|
||||
|
||||
public:
|
||||
/// <summary>
|
||||
|
||||
Reference in New Issue
Block a user