Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Pencil2D crashes when drawing on vector layer under specific conditions #1096
Okay! I found another crash inducing bug that happens when you delete a camera layer making it so that the current active layer is of vector type. After drawing on the vector layer AND undoing the stroke Pencil2D will crash.
Pencil2D should not crash under any circumstance (hopefully)
Steps to reproduce
Follow along with the attached PCLX file:
Note: I believe this happens because the vector layer becomes active and not because of having 2 cameras otherwise the other layers would crash too (I tested with bitmap layers, and it worked fine, but I have to test with sound layers import though..)
The pencil/pen tools do not draw properly for me with a mouse when I get to step 4. Can reproduce stroke on macOS 10.13.
The issue has to do with not everything getting updated properly when a non-last layer is deleted because the layer id stays the same and the managers are not notified of the change. I have a fix for this, but I don't really like it. Some refactoring should be done instead to, among other things, remove