MCPcopy Create free account
hub / github.com/TheRealMJP/DeferredTexturing / AddSetting

Method AddSetting

SampleFramework12/v1.00/Settings.cpp:892–910  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

890
891
892void SettingsContainer::AddSetting(Setting* setting)
893{
894 Assert_(initialized);
895 Assert_(setting != nullptr);
896 Assert_(FindSetting(setting->Name().c_str()) == nullptr);
897
898 for(uint64 groupIdx = 0; groupIdx < groups.Count(); ++groupIdx)
899 {
900 SettingsGroup& group = groups[groupIdx];
901 if(group.Name == setting->Group())
902 {
903 group.Settings.Add(setting);
904 return;
905 }
906 }
907
908 AssertFail_("Tried to add setting '%s' to non-existent group '%s'",
909 setting->Name().c_str(), setting->Group().c_str());
910}
911
912}

Callers 1

InitializeFunction · 0.80

Calls 3

c_strMethod · 0.80
CountMethod · 0.45
AddMethod · 0.45

Tested by

no test coverage detected