Skip to content

Commit

Permalink
Merge pull request #199 from namecheap/bugfix/crash-on-draw
Browse files Browse the repository at this point in the history
fix - crash on draw (rollback optimisation)
  • Loading branch information
panpuchkov authored May 20, 2021
2 parents 4d391b9 + 2769c45 commit b832717
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/widgets/capture/capturewidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1071,8 +1071,11 @@ void CaptureWidget::loadDrawThickness()

void CaptureWidget::processTool(CaptureTool* t)
{
auto backup = m_activeTool;
// The tool is active during the pressed().
m_activeTool = t;
m_activeTool->pressed(m_context);
t->pressed(m_context);
m_activeTool = backup;
}

void CaptureWidget::handleButtonSignal(CaptureTool::Request r)
Expand Down

0 comments on commit b832717

Please sign in to comment.