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); ArrowTool(true);
ui->view->itemClicked(vtool);// Don't check for nullptr here ui->view->itemClicked(vtool);// Don't check for nullptr here
if (vtool)
{
vtool->setFocus(); vtool->setFocus();
}
// If insert not to the end of file call lite parse // If insert not to the end of file call lite parse
if (doc->getCursor() > 0) if (doc->getCursor() > 0)
{ {