mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-11 00:39:59 +00:00
42 lines
1.5 KiB
C++
42 lines
1.5 KiB
C++
|
|
#include "subviews.hpp"
|
|
|
|
#include "../doc/subviewfactoryimp.hpp"
|
|
|
|
#include "tablesubview.hpp"
|
|
#include "dialoguesubview.hpp"
|
|
#include "scriptsubview.hpp"
|
|
|
|
void CSVWorld::addSubViewFactories (CSVDoc::SubViewFactoryManager& manager)
|
|
{
|
|
manager.add (CSMWorld::UniversalId::Type_Gmsts,
|
|
new CSVDoc::SubViewFactoryWithCreateFlag<TableSubView> (false));
|
|
|
|
manager.add (CSMWorld::UniversalId::Type_Skills,
|
|
new CSVDoc::SubViewFactoryWithCreateFlag<TableSubView> (false));
|
|
|
|
static const CSMWorld::UniversalId::Type sTableTypes[] =
|
|
{
|
|
CSMWorld::UniversalId::Type_Globals,
|
|
CSMWorld::UniversalId::Type_Classes,
|
|
CSMWorld::UniversalId::Type_Factions,
|
|
CSMWorld::UniversalId::Type_Races,
|
|
CSMWorld::UniversalId::Type_Sounds,
|
|
CSMWorld::UniversalId::Type_Scripts,
|
|
CSMWorld::UniversalId::Type_Regions,
|
|
CSMWorld::UniversalId::Type_Birthsigns,
|
|
CSMWorld::UniversalId::Type_Spells,
|
|
CSMWorld::UniversalId::Type_Cells,
|
|
CSMWorld::UniversalId::Type_Referenceables,
|
|
|
|
CSMWorld::UniversalId::Type_None // end marker
|
|
};
|
|
|
|
for (int i=0; sTableTypes[i]!=CSMWorld::UniversalId::Type_None; ++i)
|
|
manager.add (sTableTypes[i], new CSVDoc::SubViewFactoryWithCreateFlag<TableSubView> (true));
|
|
|
|
manager.add (CSMWorld::UniversalId::Type_Script, new CSVDoc::SubViewFactory<ScriptSubView>);
|
|
|
|
// manager.add (CSMWorld::UniversalId::Type_Global,
|
|
// new CSVDoc::SubViewFactoryWithCreateFlag<DialogueSubView> (true));
|
|
} |