forked from qt-creator/qt-creator
QmlJSEditor: Fix compile with Qt5.5
Avoid using functionality introduced with Qt5.6. Change-Id: Icfa4eeb547b651a19aa745b5de1cb413f9b6b4ef Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
@@ -57,8 +57,10 @@ void QmlJSOutlineTreeView::contextMenuEvent(QContextMenuEvent *event)
|
||||
|
||||
QMenu contextMenu;
|
||||
|
||||
contextMenu.addAction(tr("Expand All"), this, [this] { expandAll(); });
|
||||
contextMenu.addAction(tr("Collapse All"), this, [this] { collapseAllExceptRoot(); });
|
||||
QAction *action = contextMenu.addAction(tr("Expand All"));
|
||||
connect(action, &QAction::triggered, this, [this] () { expandAll(); });
|
||||
action = contextMenu.addAction(tr("Collapse All"));
|
||||
connect(action, &QAction::triggered, this, [this] () { collapseAllExceptRoot(); });
|
||||
|
||||
contextMenu.exec(event->globalPos());
|
||||
|
||||
|
Reference in New Issue
Block a user