Improve error handling when loading plugins
Previously, if Archive::create() failed to load a plugin, a QInputDialog was shown where the user could choose the mimetype of the archive. This was not suitable anymore, since mimetype detection is much better now and because we now try all registered plugins for a mimetype. New behavior: When a plugin fails to load, two different error messages can be shown: 1. No suitable plugin was found. 2. All suitable plugins failed to load. Because we (potentially) try to load different plugins, which can fail for different reasons (missing executables, broken plugin, etc.), error message 2 can not be made more specific. This was implemented by adding an alternative constructor for Archive which takes an error code. Part::openFile() then checks if an error message is found before continuing to load the interface, and if that is the case displays one of the the error messages. Differential Revision: D408
parent
dbc392d3
Please register or sign in to comment