Save changes when toggling checkboxes in ExportDialog
authorTim Mayberry <mojofunk@gmail.com>
Sat, 17 Sep 2016 10:28:34 +0000 (20:28 +1000)
committerTim Mayberry <mojofunk@gmail.com>
Sat, 17 Sep 2016 12:03:16 +0000 (22:03 +1000)
commit078889efa89ba2cb4be01108b80861acdc5113cb
tree2e0368f18a582f2099e1847922a4c923a5d07ae4
parentce16b5424fd05a72d1fe086caa3c1dd0a697916b
Save changes when toggling checkboxes in ExportDialog

I used the Widget::on_hide method in the ExportFileDialog to defer the saving
of changes in state of the analysis and soundcloud-upload checkboxes as it was
not possible to save the format xml state directly from the
ToggleButton::toggled() signal as it created a recursive loop and also to
prevent saving the state more than once.

Even though the ExportProfileManager::FormatListChanged signal is no longer
emitted when saving format state and the crash no longer occurs without this
change. I think it is worth saving explicitily from in the toggle callbacks to
reduce the complexity of understanding what is taking place and when even if it
is less efficient.

There is definitely more opportunity for refactoring and redesign.
gtk2_ardour/export_file_notebook.cc
gtk2_ardour/export_file_notebook.h