MCPcopy Create free account
hub / github.com/OneMoreGres/ScreenTranslator / selectAllUpdates

Method selectAllUpdates

src/service/updates.cpp:379–397  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

377}
378
379void Model::selectAllUpdates()
380{
381 if (!root_)
382 return;
383
384 const auto visitor = [this](Component &component, auto v) -> void {
385 if (component.checkOnly)
386 return;
387
388 if (component.state == State::UpdateAvailable)
389 updater_.applyAction(Action::Install, component.files);
390
391 if (!component.children.empty()) {
392 for (auto &child : component.children) v(*child, v);
393 }
394 };
395
396 visitor(*root_, visitor);
397}
398
399void Model::tryAction(Action action, const QModelIndex &index)
400{

Callers 1

showModelContextMenuMethod · 0.80

Calls 1

applyActionMethod · 0.80

Tested by

no test coverage detected