Attached patch solves two TOC dialog bugs 3528 and 3534. Can smb review (Abdel?, Juergen?, John?) and commit it (Jose?)
ugras
Index: frontends/qt4/TocWidget.cpp =================================================================== --- frontends/qt4/TocWidget.cpp (revision 18237) +++ frontends/qt4/TocWidget.cpp (working copy) @@ -91,9 +91,13 @@ void TocWidget::on_updateTB_clicked() { + int currentIndex = typeCO->currentIndex(); form_->updateBackend(); form_->update(); - update(); + if(currentIndex == typeCO->currentIndex()) + update(); + else + typeCO->setCurrentIndex(currentIndex); } /* FIXME (Ugras 17/11/06): @@ -139,10 +143,10 @@ } } - -void TocWidget::on_typeCO_activated(int value) +void TocWidget::on_typeCO_currentIndexChanged(int value) { setTocModel(value); + update(); } @@ -250,12 +254,14 @@ } QString current_text = typeCO->currentText(); + typeCO->blockSignals(true); typeCO->setModel(type_model); int const current_type = typeCO->findText(current_text); if (current_type != -1) typeCO->setCurrentIndex(current_type); else typeCO->setCurrentIndex(form_->selectedType()); + typeCO->blockSignals(false); setTocModel(typeCO->currentIndex()); } Index: frontends/qt4/TocWidget.h =================================================================== --- frontends/qt4/TocWidget.h (revision 18237) +++ frontends/qt4/TocWidget.h (working copy) @@ -43,7 +43,7 @@ void on_updateTB_clicked(); void on_depthSL_valueChanged(int depth); - void on_typeCO_activated(int value); + void on_typeCO_currentIndexChanged(int value); void on_moveUpTB_clicked(); void on_moveDownTB_clicked(); void on_moveInTB_clicked();