change main and singleapplication class for clean exit with qt5
fix shutdown procedure with respect to new version of ExtentionSystem that no longer invoke 'shutdown' method