mirror of
https://github.com/aseprite/aseprite.git
synced 2025-01-06 06:58:15 +00:00
Fix crash using Edit > Cut after pasting the clipboard content on an empty cel
This commit is contained in:
parent
5eb3119877
commit
559c3df6de
@ -251,8 +251,12 @@ void PixelsMovement::trim()
|
||||
}
|
||||
m_tx(new cmd::ClearMask(cel));
|
||||
}
|
||||
if (cel->layer()->isTransparent())
|
||||
// Current cel (m_site.cel()) can be nullptr when we paste in an
|
||||
// empty cel (Ctrl+V) and cut (Ctrl+X) the floating pixels.
|
||||
if (cel &&
|
||||
cel->layer()->isTransparent()) {
|
||||
m_tx(new cmd::TrimCel(cel));
|
||||
}
|
||||
}
|
||||
|
||||
if (restoreMask)
|
||||
|
Loading…
Reference in New Issue
Block a user