Sketcher: Resolve unsafe combination of bool and int in |

This commit is contained in:
Chris Hennes
2024-07-08 11:02:49 -05:00
parent 0bc2717788
commit 4eb57fb50d
2 changed files with 2 additions and 2 deletions
@@ -1772,7 +1772,7 @@ void TaskSketcherConstraints::onFilterListItemChanged(QListWidgetItem* item)
for (int i = filterList->count() - 1; i >= 0; i--) {
bool isChecked = filterList->item(i)->checkState() == Qt::Checked;
filterState = filterState << 1;// we shift left first, else the list is shifted at the end.
filterState = filterState | isChecked;
filterState = filterState | (isChecked ? 1 : 0);
}
ParameterGrp::handle hGrp = App::GetApplication().GetParameterGroupByPath(
"User parameter:BaseApp/Preferences/Mod/Sketcher/General");
@@ -1301,7 +1301,7 @@ void TaskSketcherElements::onListMultiFilterItemChanged(QListWidgetItem* item)
for (int i = filterList->count() - 1; i >= 0; i--) {
bool isChecked = filterList->item(i)->checkState() == Qt::Checked;
filterState = filterState << 1;// we shift left first, else the list is shifted at the end.
filterState = filterState | isChecked;
filterState = filterState | (isChecked ? 1 : 0);
}
ParameterGrp::handle hGrp = App::GetApplication().GetParameterGroupByPath(
"User parameter:BaseApp/Preferences/Mod/Sketcher/General");