Skip to content

Commit

Permalink
Don't copy the export file name to sprite preferences created from Sa…
Browse files Browse the repository at this point in the history
…ve As or Export (fix aseprite#1964)
  • Loading branch information
Gasparoken committed Mar 29, 2019
1 parent b7b2d46 commit 85ef58a
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/app/commands/cmd_save_file.cpp
@@ -1,4 +1,5 @@
// Aseprite
// Copyright (C) 2019 Igara Studio S.A.
// Copyright (C) 2001-2018 David Capello
//
// This program is distributed under the terms of
Expand Down Expand Up @@ -135,6 +136,7 @@ std::string SaveFileBaseCommand::saveAsDialog(
const std::string& forbiddenFilename)
{
Doc* document = context->activeDocument();
Preferences::instance().save();
std::string filename;

if (!m_filename.empty()) {
Expand Down Expand Up @@ -168,6 +170,13 @@ std::string SaveFileBaseCommand::saveAsDialog(
saveDocumentInBackground(
context, document,
filename, markAsSaved);
Preferences::instance().document(document).saveCopy.filename("");
Preferences::instance().document(document).saveCopy.aniDir(doc::AniDir::FORWARD);
Preferences::instance().document(document).saveCopy.applyPixelRatio(false);
Preferences::instance().document(document).saveCopy.layer("");
Preferences::instance().document(document).saveCopy.forTwitter(false);
Preferences::instance().document(document).saveCopy.resizeScale(1);
Preferences::instance().save();
}

return filename;
Expand Down

0 comments on commit 85ef58a

Please sign in to comment.