Sketcher: Resolve unsafe combination of bool and int in |
This commit is contained in:
@@ -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");
|
||||
|
||||
Reference in New Issue
Block a user