这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@MrStevns
Copy link
Member

Fixes #950

- updated isKeyframeSane with check to verify draw_on_empty_frame_action
Copy link
Member

@scribblemaniac scribblemaniac left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR currently introduces a bug with the automatic create new keyframe behavior that needs to be addressed before merging. There may need to be further discussion about how the automatic duplicate frame option should behave when there is no explicit previous keyframe.

@scribblemaniac scribblemaniac mentioned this pull request Apr 19, 2019
- This reworks the whole handleDrawingOnEmptyFrame by always making sure there's a frame to paint on. No matter which frame frame is selected, the user can always expect to draw on the canvas. If the first frame is empty and the action is "draw on previous keyframe" then a keyframe will be created. The same will happen for "duplicate previous keyframe" in case there's none. This should also eliminate other checks that requires there to be a keyframe because there will always be one now.
@MrStevns MrStevns requested a review from scribblemaniac April 19, 2019 18:19
@MrStevns
Copy link
Member Author

MrStevns commented Apr 19, 2019

I've reworked the PR... basically based on what you said @scribblemaniac , I agree that it's better if we always allow the user to draw on the canvas instead of ignoring their input.

The new logic makes sure that if you draw on the canvas while there is no previous keyframe, then one will be created for you. This is true for both "drawing on previous keyframe" and "duplicate previous keyframe"

@MrStevns MrStevns changed the title #950 - ignore input with drawing tools when keyframe is not sane #950 - always make sure there's a keyframe when drawing Apr 19, 2019
Copy link
Member

@scribblemaniac scribblemaniac left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made a small suggestion, but overall this is good now. I like the new solution, it simplifies many things!

@scribblemaniac scribblemaniac added this to the 0.6.4 milestone May 2, 2019
@scribblemaniac
Copy link
Member

I am merging this now with only one reviewer due to our current limited resources and imminent v0.6.4 release.

@scribblemaniac scribblemaniac merged commit 858bae7 into pencil2d:master May 2, 2019
@MrStevns MrStevns deleted the #950-fix-noframe-crash branch October 31, 2023 06:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Pencil2D crashes when attempting to modify a non-existing first (key)frame

2 participants