dialog: fix button order of ConfirmSaveDialog#12559
dialog: fix button order of ConfirmSaveDialog#12559msujew merged 4 commits intoeclipse-theia:masterfrom
ConfirmSaveDialog#12559Conversation
msujew
left a comment
There was a problem hiding this comment.
I'm not really sure that this is the correct approach to this issue. First off, we have some regressions with this:
I believe a refactoring of the ConfirmSaveDialog is in order. I'm not perfectly sure that the dialog should be in charge of actually executing the change. Instead, I would like to see it being decoupled from ConfirmDialog and returning some sort of enum:
enum ConfirmSaveResult {
Cancel,
Save,
DontSave
}That way we can actually save outside of the dialog and also make it easier to order the buttons, without needing to touch the ConfirmDialog at all.
|
Yeah, you are right, refactoring ConfirmSaveDialog is the better approach. I'll get on it. |
msujew
left a comment
There was a problem hiding this comment.
I think I led you down the wrong path. I've refactored this a bit more to reduce some of the duplication. Looks good to me now 👍
|
Thanks for the changes Mark, I realize how much I overcomplicated some stuff. |

What it does
This PR fixes #12246 by making changes to the UI as per the defined conventions. It reorders the dialog buttons in the
ConfirmSaveDialogto followCancel>Don't save>Save allsequence. This PR also makes sure that only one primary button is highlighted, which is theSave allbutton.How to test
File->AutoSaveCancel>Don't save>Save all)Review checklist
Reminder for reviewers