mirror of
https://github.com/fralx/LimeReport.git
synced 2025-01-12 09:31:04 +03:00
Fix crash when cutting an item using the context menu
page->cut() is deleting the object, which means that "this" is no longer valid, and then we're trying to call `processPopUpAction()` on it.
This commit is contained in:
parent
010db431b1
commit
8ee7fc01e5
@ -1180,7 +1180,10 @@ void BaseDesignIntf::contextMenuEvent(QGraphicsSceneContextMenuEvent *event)
|
|||||||
QAction* a = menu.exec(event->screenPos());
|
QAction* a = menu.exec(event->screenPos());
|
||||||
if (a){
|
if (a){
|
||||||
if (a == cutAction)
|
if (a == cutAction)
|
||||||
|
{
|
||||||
page->cut();
|
page->cut();
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (a == copyAction)
|
if (a == copyAction)
|
||||||
page->copy();
|
page->copy();
|
||||||
if (a == pasteAction)
|
if (a == pasteAction)
|
||||||
|
Loading…
Reference in New Issue
Block a user