Improve memory allocation.

--HG--
branch : develop
This commit is contained in:
Roman Telezhynskyi 2017-03-02 13:14:19 +02:00
parent 20107a35f8
commit 714a180b31

View File

@ -629,7 +629,7 @@ void DialogSeamAllowance::ShowPinsContextMenu(const QPoint &pos)
return;
}
QMenu *menu = new QMenu(this);
QScopedPointer<QMenu> menu(new QMenu());
QAction *actionDelete = menu->addAction(QIcon::fromTheme("edit-delete"), tr("Delete"));
QAction *selectedAction = menu->exec(ui->listWidgetPins->viewport()->mapToGlobal(pos));