Remove unnecessary calls to Doc::resetTransformation/generateMaskBoundaries()

This commit is contained in:
David Capello 2019-09-11 15:41:35 -03:00
parent fe42245ed9
commit d588777b40
4 changed files with 3 additions and 11 deletions

View File

@ -155,10 +155,6 @@ protected:
// Copy new mask
api.copyToCurrentMask(new_mask.get());
// Regenerate mask
document()->resetTransformation();
document()->generateMaskBoundaries();
}
// change the sprite's size

View File

@ -142,10 +142,6 @@ protected:
// Copy new mask
api.copyToCurrentMask(new_mask.get());
// Regenerate mask
document()->resetTransformation();
document()->generateMaskBoundaries();
}
// Resize slices

View File

@ -92,8 +92,10 @@ void Transaction::commit()
m_cmds = nullptr;
// Process changes
if (int(m_changes) & int(Changes::kSelection))
if (int(m_changes) & int(Changes::kSelection)) {
m_doc->resetTransformation();
m_doc->generateMaskBoundaries();
}
}
void Transaction::rollbackAndStartAgain()

View File

@ -124,8 +124,6 @@ void select_layer_boundaries(Layer* layer,
tx(new cmd::SetMask(doc, &newMask));
tx.commit();
doc->resetTransformation();
doc->generateMaskBoundaries();
update_screen_for_document(doc);
}
catch (base::Exception& e) {