mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Cleanup: use pointer-to-member-function in addAction() calls
Since requiring Qt >= 5.9.1, we can use the pointer-to-member-function overloads of addAction (introduced in Qt 5.6). This has the advantage of compile-time checking of the signal/slot parameters. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
39c36af808
commit
fdfcbd0315
5 changed files with 33 additions and 33 deletions
|
@ -57,7 +57,7 @@ bool LocationInformationWidget::eventFilter(QObject *object, QEvent *ev)
|
|||
if (ev->type() == QEvent::ContextMenu) {
|
||||
QContextMenuEvent *ctx = (QContextMenuEvent *)ev;
|
||||
QMenu contextMenu;
|
||||
contextMenu.addAction(tr("Merge into current site"), this, SLOT(mergeSelectedDiveSites()));
|
||||
contextMenu.addAction(tr("Merge into current site"), this, &LocationInformationWidget::mergeSelectedDiveSites);
|
||||
contextMenu.exec(ctx->globalPos());
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue