MCPcopy Create free account
hub / github.com/danoon2/Boxedwine / loadApps

Method loadApps

source/ui/data/boxedContainer.cpp:118–134  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

116}
117
118void BoxedContainer::loadApps() {
119 BString appDirPath = GlobalSettings::getAppFolder(this);
120
121 this->apps.clear();
122
123 Fs::iterateAllNativeFiles(appDirPath, true, false, [this] (BString filepath, bool isDir)->U32 {
124 if (filepath.endsWith(".ini", true)) {
125 BoxedApp* app = new BoxedApp();
126 if (app->load(this, filepath)) {
127 this->apps.push_back(app);
128 } else {
129 delete app;
130 }
131 }
132 return 0;
133 });
134}
135
136void BoxedContainer::deleteApp(BoxedApp* app) {
137 std::vector<BoxedApp*>::iterator position = std::find(this->apps.begin(), this->apps.end(), app);

Callers 2

loadMethod · 0.95
reloadMethod · 0.95

Calls 4

endsWithMethod · 0.80
clearMethod · 0.45
loadMethod · 0.45
push_backMethod · 0.45

Tested by

no test coverage detected