diff --git a/src/Gui/DlgParameterImp.cpp b/src/Gui/DlgParameterImp.cpp index 0d87d383f4..4374362fa3 100644 --- a/src/Gui/DlgParameterImp.cpp +++ b/src/Gui/DlgParameterImp.cpp @@ -408,7 +408,7 @@ void DlgParameterImp::onChangeParameterSet(int index) } while (parent && !paths.empty()) { - paramGroup->setItemExpanded(parent, true); + parent->setExpanded(true); QTreeWidgetItem* item = parent; parent = 0; for (int index=0; index < item->childCount(); index++) { @@ -540,9 +540,9 @@ void ParameterGroup::onToggleSelectedItem() if (isItemSelected(sel)) { if ( isItemExpanded(sel) ) - setItemExpanded(sel, false); + sel->setExpanded(false); else if ( sel->childCount() > 0 ) - setItemExpanded(sel, true); + sel->setExpanded(true); } } @@ -618,7 +618,7 @@ void ParameterGroup::onImportFromFile() new ParameterGroupItem(para,*it); } - setItemExpanded(para, para->childCount()); + para->setExpanded(para->childCount()); } catch( const Base::Exception& ) { diff --git a/src/Gui/DlgToolbarsImp.cpp b/src/Gui/DlgToolbarsImp.cpp index 9aee12cdaf..8715f23069 100644 --- a/src/Gui/DlgToolbarsImp.cpp +++ b/src/Gui/DlgToolbarsImp.cpp @@ -503,7 +503,7 @@ void DlgCustomToolbars::on_newButton_clicked() QTreeWidgetItem* item = new QTreeWidgetItem(ui->toolbarTreeWidget); item->setText(0, text); item->setCheckState(0, Qt::Checked); - ui->toolbarTreeWidget->setItemExpanded(item, true); + item->setExpanded(true); QVariant data = ui->workbenchBox->itemData(ui->workbenchBox->currentIndex(), Qt::UserRole); QString workbench = data.toString();