This commit is contained in:
Charles Kerr 2022-06-10 10:49:59 -04:00
parent c22b0d7ed5
commit d22d554f02
12 changed files with 247 additions and 302 deletions

View file

@ -692,21 +692,16 @@ cHTMLTemplates::~cHTMLTemplates()
//o-----------------------------------------------------------------------------------------------o
//| Purpose - Loads the HTML Templates from the scripts
//o-----------------------------------------------------------------------------------------------o
void cHTMLTemplates::Load( void )
{
for( Script *toCheck = FileLookup->FirstScript( html_def ); !FileLookup->FinishedScripts( html_def ); toCheck = FileLookup->NextScript( html_def ) )
{
if( toCheck != nullptr )
{
auto cHTMLTemplates::Load()->void {
for (auto &toCheck : FileLookup->ScriptListings[html_def]){
if(toCheck) {
size_t NumEntries = toCheck->NumEntries();
if( NumEntries == 0 )
continue;
for( ScriptSection *found = toCheck->FirstEntry(); found != nullptr; found = toCheck->NextEntry() )
{
cHTMLTemplate *Template = new cHTMLTemplate();
Template->Load( found );
Templates.push_back( Template );
if( NumEntries != 0 ){
for (auto &[entryName, found]: toCheck->collection()){
cHTMLTemplate *Template = new cHTMLTemplate();
Template->Load( found );
Templates.push_back( Template );
}
}
}
}