MCPcopy Create free account
hub / github.com/NatronGitHub/Natron / onSelectAllButtonClicked

Method onSelectAllButtonClicked

Gui/MultiInstancePanel.cpp:1052–1075  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1050}
1051
1052void
1053MultiInstancePanel::onSelectAllButtonClicked()
1054{
1055 QItemSelectionModel* selectModel = _imp->view->selectionModel();
1056 QItemSelection sel;
1057
1058 assert(selectModel);
1059 int rc = _imp->model->rowCount();
1060 int cc = _imp->model->columnCount();
1061
1062 for (int i = 0; i < rc; ++i) {
1063 assert( i < (int)_imp->instances.size() );
1064 Nodes::iterator it = _imp->instances.begin();
1065 std::advance(it, i);
1066 bool disabled = it->first.lock()->isNodeDisabled();
1067 if (disabled) {
1068 continue;
1069 }
1070
1071 QItemSelectionRange r( _imp->model->index(i, 0), _imp->model->index(i, cc - 1) );
1072 sel.append(r);
1073 }
1074 selectModel->select(sel, QItemSelectionModel::ClearAndSelect);
1075}
1076
1077bool
1078MultiInstancePanel::isSettingsPanelVisible() const

Callers

nothing calls this directly

Calls 9

isNodeDisabledMethod · 0.80
appendMethod · 0.80
rowCountMethod · 0.45
columnCountMethod · 0.45
sizeMethod · 0.45
beginMethod · 0.45
lockMethod · 0.45
indexMethod · 0.45
selectMethod · 0.45

Tested by

no test coverage detected