MCPcopy Create free account
hub / github.com/FreesmTeam/FreesmLauncher / deleteResources

Method deleteResources

launcher/minecraft/mod/ResourceFolderModel.cpp:175–193  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

173}
174
175bool ResourceFolderModel::deleteResources(const QModelIndexList& indexes)
176{
177 if (indexes.isEmpty())
178 return true;
179
180 for (auto i : indexes) {
181 if (i.column() != 0) {
182 continue;
183 }
184
185 auto& resource = m_resources.at(i.row());
186
187 resource->destroy();
188 }
189
190 update();
191
192 return true;
193}
194
195bool ResourceFolderModel::setResourceEnabled(const QModelIndexList& indexes, EnableAction action)
196{

Callers 1

removeItemsMethod · 0.80

Calls 3

isEmptyMethod · 0.45
atMethod · 0.45
destroyMethod · 0.45

Tested by

no test coverage detected