Fixed Valentina crash.

Valentina crashes if creating tool was canceled.

--HG--
branch : develop
This commit is contained in:
Roman Telezhynskyi 2017-10-31 20:01:19 +02:00
parent e9abab4eb2
commit 0ef92f9cba

View file

@ -720,7 +720,10 @@ void MainWindow::ClosedDialogWithApply(int result, VMainGraphicsScene *scene)
}
ArrowTool(true);
ui->view->itemClicked(vtool);// Don't check for nullptr here
vtool->setFocus();
if (vtool)
{
vtool->setFocus();
}
// If insert not to the end of file call lite parse
if (doc->getCursor() > 0)
{