Skip to content

Commit

Permalink
[Fixes bug #772172] Ensure that the active tool has committed its wor…
Browse files Browse the repository at this point in the history
…k before attempting to close the document
  • Loading branch information
cameronwhite committed Sep 13, 2011
1 parent 2fc51c4 commit 479dcef
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Pinta/Actions/File/CloseDocumentAction.cs
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,9 @@ public void Uninitialize ()

private void Activated (object sender, EventArgs e)
{
// Commit any pending changes
PintaCore.Tools.Commit ();

// If it's not dirty, just close it
if (!PintaCore.Workspace.ActiveDocument.IsDirty) {
PintaCore.Workspace.CloseActiveDocument ();
Expand Down

0 comments on commit 479dcef

Please sign in to comment.