Gui: [skip ci] fix several warnings reported by GH Actions
This commit is contained in:
@@ -26,6 +26,7 @@
|
||||
# include <QAction>
|
||||
# include <QMap>
|
||||
# include <QPointer>
|
||||
# include <QTimer>
|
||||
#endif
|
||||
|
||||
#include "ActionFunction.h"
|
||||
@@ -58,7 +59,7 @@ void ActionFunction::trigger(QAction* action, std::function<void()> func)
|
||||
Q_D(ActionFunction);
|
||||
|
||||
d->triggerMap[action] = func;
|
||||
connect(action, SIGNAL(triggered()), this, SLOT(triggered()));
|
||||
connect(action, &QAction::triggered, this, &ActionFunction::triggered);
|
||||
}
|
||||
|
||||
void ActionFunction::triggered()
|
||||
@@ -177,4 +178,9 @@ void TimerFunction::timeout()
|
||||
deleteLater();
|
||||
}
|
||||
|
||||
void TimerFunction::singleShot(int ms)
|
||||
{
|
||||
QTimer::singleShot(ms, this, &Gui::TimerFunction::timeout);
|
||||
}
|
||||
|
||||
#include "moc_ActionFunction.cpp"
|
||||
|
||||
Reference in New Issue
Block a user