fix dangeling allActivitiesGroup pointer crash
CCBUG: 334152 Forward port of d3fe2391f6b36398ac671fe3cadef667919cc0e5 from kde-workspace
This commit is contained in:
parent
d6ea601005
commit
00bb767291
1 changed files with 2 additions and 1 deletions
|
@ -57,6 +57,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|||
#include <QAction>
|
||||
#include <QCheckBox>
|
||||
#include <QtConcurrentRun>
|
||||
#include <QPointer>
|
||||
#include <QPushButton>
|
||||
|
||||
#include <KGlobalAccel>
|
||||
|
@ -677,7 +678,7 @@ void UserActionsMenu::activityPopupAboutToShow()
|
|||
QAction *action = m_activityMenu->addAction(i18n("&All Activities"));
|
||||
action->setData(QString());
|
||||
action->setCheckable(true);
|
||||
static QActionGroup *allActivitiesGroup = NULL;
|
||||
static QPointer<QActionGroup> allActivitiesGroup;
|
||||
if (!allActivitiesGroup) {
|
||||
allActivitiesGroup = new QActionGroup(m_activityMenu);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue