Comment 1 for bug 1116059

Revision history for this message
Jacobo Aragunde PĂ©rez (jaragunde) wrote :

This patch replaces the existing dialogs in the library and module editors with the application-wide exit confirmation dialog.

I had to modify LIB_EDIT_FRAME::SaveActiveLibrary to return a boolean value, so we can stop the exit process in case the user wanted to save but an error happens. I added a function called LIB_EDIT_FRAME::OnSaveActiveLibrary to act as the wxWidgets event handler (it must be a function returning void).

I'm not completely satisfied with the solution for the library editor, as there are two types of confirmation dialogs, one for the changes on the component itself and another one for the changes on libraries. I've left the library confirmation dialog as it was, at least for now. A general rework of the saving process would be needed, since it looks too complicated and shows too many confirmation dialogs, but that's work for another day ;)