Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Add OPEN_PANEL_CANCELLED and SAVE_PANEL_CANCELLED commands #1061

Merged
merged 1 commit into from
Jul 26, 2020

Conversation

cmyr
Copy link
Member

@cmyr cmyr commented Jun 25, 2020

This lets the user take special action if needed in either of
these cases.

I needed this in order to implement a "you have unsaved changes" prompt in Runebender, while testing out #1039. I think that we may want to further modify the general alerts API, and I think that we should try and make the open and save panels use a similar API to whatever we come up with for alerts, more generally, in which case this might be a stop-gap solution.

@luleyleo
Copy link
Collaborator

Yeah, I've been thinking about adding context methods for file dialogs similarly to those for windows, menus and future alerts.
I guess we will probably want to use the same pattern for this as with alerts.

It's probably okish to add those as long as they go into no release. Did you leave of the changelog intentionally? I think it should be included temporarily, even if they are going to be removed again.

@cmyr
Copy link
Member Author

cmyr commented Jun 26, 2020

oops changelog was an oversight, updated.

@cmyr cmyr force-pushed the cancel-dialog-commands branch 2 times, most recently from 1b3981e to fc835a2 Compare June 26, 2020 14:07
CHANGELOG.md Outdated Show resolved Hide resolved
CHANGELOG.md Outdated Show resolved Hide resolved
druid/src/command.rs Outdated Show resolved Hide resolved
@luleyleo luleyleo added the S-waiting-on-author waits for changes from the submitter label Jun 26, 2020
druid/src/command.rs Outdated Show resolved Hide resolved
@cmyr cmyr added S-needs-review waits for review and removed S-waiting-on-author waits for changes from the submitter labels Jun 26, 2020
Copy link
Collaborator

@luleyleo luleyleo left a comment

Choose a reason for hiding this comment

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

Looks good!

This lets the user take special action if needed in either of
these cases.
@cmyr cmyr merged commit 14c4958 into master Jul 26, 2020
@cmyr cmyr deleted the cancel-dialog-commands branch July 26, 2020 16:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants