Export Sprite Sheet: Select old sprite tab when the preview is unchecked

This commit is contained in:
David Capello 2019-10-25 14:40:21 -03:00
parent ae9a8128be
commit ad12ec4a0d

View File

@ -870,9 +870,12 @@ private:
if (!preview()->isSelected()) { if (!preview()->isSelected()) {
if (m_spriteSheet) { if (m_spriteSheet) {
DocDestroyer destroyer(UIContext::instance(), m_spriteSheet.release(), 100); auto ctx = UIContext::instance();
DocDestroyer destroyer(ctx, m_spriteSheet.release(), 100);
destroyer.destroyDocument(); destroyer.destroyDocument();
m_editor = nullptr; m_editor = nullptr;
ctx->setActiveDocument(m_site.document());
} }
return; return;
} }