diff options
author | Ben Boeckel <MathStuf@gmail.com> | 2009-03-26 20:44:18 -0400 |
---|---|---|
committer | Ben Boeckel <MathStuf@gmail.com> | 2009-03-26 20:44:18 -0400 |
commit | 9d4236dd320d8e71ab201da5fcc1d71a2fcffd50 (patch) | |
tree | 84217a20c05fc9c5ff44599690682e15226986c5 /sigmodr | |
parent | eee72ffe493c1ea92a16383a59c78db698d3440c (diff) | |
download | sigen-9d4236dd320d8e71ab201da5fcc1d71a2fcffd50.tar.gz sigen-9d4236dd320d8e71ab201da5fcc1d71a2fcffd50.tar.xz sigen-9d4236dd320d8e71ab201da5fcc1d71a2fcffd50.zip |
Clean up more than just the widget
Diffstat (limited to 'sigmodr')
-rw-r--r-- | sigmodr/SigmodrUI.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/sigmodr/SigmodrUI.cpp b/sigmodr/SigmodrUI.cpp index c3049896..7d048b79 100644 --- a/sigmodr/SigmodrUI.cpp +++ b/sigmodr/SigmodrUI.cpp @@ -373,7 +373,11 @@ bool SigmodrUI::closeWidget() } } if (closed) + { delete formPanel->takeWidget(); + formPanel->setWidget(NULL); + boxButtons->setEnabled(false); + } return closed; } @@ -472,7 +476,6 @@ void Sigmodr::SigmodrUI::on_treeSigmod_clicked(const QModelIndex& index) ObjectUI* widget = treeSigmod->editorWidget(index); if (widget && closeWidget()) { - boxButtons->setEnabled(false); connect(widget, SIGNAL(changed(bool)), boxButtons, SLOT(setEnabled(bool))); connect(widget, SIGNAL(saved()), this, SLOT(setDirty())); connect(buttonApply, SIGNAL(clicked()), widget, SLOT(apply())); |