From cde524b88f9db46588773d20bf5c36b4e31d234a Mon Sep 17 00:00:00 2001 From: Alessandro Portale Date: Sat, 30 May 2009 18:49:53 +0200 Subject: Make sure that the QKeyEventSoftKey gets deleted when the action gets deleted. --- src/gui/widgets/qsoftkeystack.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gui/widgets/qsoftkeystack.cpp b/src/gui/widgets/qsoftkeystack.cpp index 494471e..7946f4a 100644 --- a/src/gui/widgets/qsoftkeystack.cpp +++ b/src/gui/widgets/qsoftkeystack.cpp @@ -286,6 +286,7 @@ void QKeyEventSoftKey::addSoftKey(QSoftKeyAction::StandardRole standardRole, Qt: QSoftKeyAction *action = new QSoftKeyAction(standardRole, actionWidget); QKeyEventSoftKey *softKey = new QKeyEventSoftKey(action, key, actionWidget); connect(action, SIGNAL(triggered()), softKey, SLOT(sendKeyEvent())); + connect(action, SIGNAL(destroyed()), softKey, SLOT(deleteLater())); stack->popandPush(action); } -- cgit v0.12