More work on unsaved profile confirmation dialogs. Related to issue #66.