Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

2242 quit dont ask me again #2294

Merged
merged 6 commits into from
Oct 28, 2022
Merged

2242 quit dont ask me again #2294

merged 6 commits into from
Oct 28, 2022

Conversation

lucas-wilkins
Copy link
Contributor

Are you sure want to quit SasView?

I'm always sure.


An ask me again box on exit dialog

@lucas-wilkins lucas-wilkins linked an issue Oct 27, 2022 that may be closed by this pull request
@lucas-wilkins lucas-wilkins added Main GUI Window Issues that concern the main window Enhancement Feature requests and/or general improvements labels Oct 27, 2022
Copy link
Contributor

@pbeaucage pbeaucage left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does what it says on the tin. Working well on my machine. Would be nice to have a GUI preference pane so that users can reset the dialog, but I don't see that as a blocker for this esp given that the preference API isn't merged yet.

if answer.result:

# Only set ask again on accepted quit, otherwise the user might
# never be able to leave SasView (@butlerpd might prefer this behaviour though)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LOL

@pkienzle
Copy link
Contributor

One can make a social engineering argument: The exit dialog is annoying but necessary since state isn't preserved on exit and reloaded on startup. By allowing developers to avoid the annoyance they are less motivated to do the correct fix. Therefore it may be in the best interest of the users to reject the PR.

We already have save/load project on the menu. How about we automatically save the project before quit and restore it on restart? Add a menu item to clear the project if you want to start afresh. Then we can eliminate the save dialog for everyone.

If we have written the project save correctly then no information will be lost, and accidentally hitting quit will merely be an annoyance of resetting the plots. If we have not saving everything then that's a bug that needs to be addressed. For example, if the fit uncertainty table only appears in the console log then we should be sure to include the log in the project save file and restore it on load.

@lucas-wilkins
Copy link
Contributor Author

@pkienzle When that's done we can migrate the quit dialog with a don't ask me again, to a save changes on exit dialog with a don't ask me again.

@pbeaucage pbeaucage self-requested a review October 27, 2022 20:28
@pkienzle
Copy link
Contributor

@lucas-wilkins not needing any dialog is the best state; configuration options should be few and far between

Disabling safety features because they are too annoying should be a last resort, not a temporary fix.

@lucas-wilkins
Copy link
Contributor Author

I, and I suspect many others, don't want things to save everything automatically when a program exists. Nor do I want it to hold me up every time it exits.

Usually, when I quit a program, I want it to forget everything I have not explicitly told it to.

This is why on many applications you have an "unsaved data" prompt, which can be disabled - because I know I have unsaved data, and its often why I'm exiting.

@lucas-wilkins
Copy link
Contributor Author

Disabling safety features because they are too annoying should be a last resort

@pkienzle Is this your way of offering to implement the changes you want, because I don't have the bandwidth.

@lucas-wilkins
Copy link
Contributor Author

THIS DISABLES GUI TEST

@lucas-wilkins lucas-wilkins merged commit 9e33462 into main Oct 28, 2022
llimeht added a commit to llimeht/sasview that referenced this pull request Oct 29, 2022
@pkienzle pkienzle deleted the 2242-quit-dont-ask-me-again branch November 4, 2022 20:26
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Enhancement Feature requests and/or general improvements Main GUI Window Issues that concern the main window
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Quit: Don't ask me again
3 participants