forked from qt-creator/qt-creator
use initializer lists
Change-Id: I82b04601f1db52197b3dc625b6b7e0f143c1c8b6 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
This commit is contained in:
@@ -688,7 +688,7 @@ void AppOutputPane::tabChanged(int i)
|
||||
|
||||
void AppOutputPane::contextMenuRequested(const QPoint &pos, int index)
|
||||
{
|
||||
QList<QAction *> actions = QList<QAction *>() << m_closeCurrentTabAction << m_closeAllTabsAction << m_closeOtherTabsAction;
|
||||
const QList<QAction *> actions = {m_closeCurrentTabAction, m_closeAllTabsAction, m_closeOtherTabsAction};
|
||||
QAction *action = QMenu::exec(actions, m_tabWidget->mapToGlobal(pos), nullptr, m_tabWidget);
|
||||
const int currentIdx = index != -1 ? index : currentIndex();
|
||||
if (action == m_closeCurrentTabAction) {
|
||||
|
||||
Reference in New Issue
Block a user