mirror of
https://github.com/aseprite/aseprite.git
synced 2024-10-03 21:46:20 +00:00
Fix problem using Shift+Pencil tool to draw a straight line with pixel-perfect mode
This commit is contained in:
parent
a517ed2fff
commit
028fb19b4e
@ -239,6 +239,14 @@ public:
|
||||
}
|
||||
|
||||
void joinStroke(ToolLoop* loop, const Stroke& stroke) override {
|
||||
// Required for LineFreehand controller in the first stage, when
|
||||
// we are drawing the line and the trace policy is "Last". Each
|
||||
// new joinStroke() is like a fresh start. Without this fix, the
|
||||
// first stage on LineFreehand will draw a "star" like pattern
|
||||
// with lines from the first point to the last point.
|
||||
if (loop->getTracePolicy() == TracePolicy::Last)
|
||||
m_pts.reset();
|
||||
|
||||
if (stroke.size() == 0)
|
||||
return;
|
||||
else if (m_pts.empty() && stroke.size() == 1) {
|
||||
|
Loading…
Reference in New Issue
Block a user