| 1472 | } |
| 1473 | |
| 1474 | void addEntry(const QString& before, |
| 1475 | const QString& after, |
| 1476 | const QString& description, |
| 1477 | const QString& realBefore = QString(), |
| 1478 | const QString& realAfter = QString()) { |
| 1479 | if (!m_menu) |
| 1480 | return; |
| 1481 | |
| 1482 | auto* const action = m_menu->addAction(before + after + QLatin1Char('\t') + description); |
| 1483 | m_insertBefore[m_indexWalker] = QString(realBefore.isEmpty() ? before : realBefore); |
| 1484 | m_insertAfter[m_indexWalker] = QString(realAfter.isEmpty() ? after : realAfter); |
| 1485 | action->setData(QVariant(m_indexWalker++)); |
| 1486 | m_actionPointers.insert(action); |
| 1487 | } |
| 1488 | |
| 1489 | void addSeparator() { |
| 1490 | if (!m_menu) |
no test coverage detected