Message ID | 20230415201056.31080-10-ps.report@gmx.net |
---|---|
State | New |
Headers | show |
Series | [v4l-utils,v1,01/11] qv4l2: remove leagcy alsa_stream.h include (ENABLE_ALSA protected) | expand |
diff --git a/utils/qv4l2/qv4l2.cpp b/utils/qv4l2/qv4l2.cpp index bcba88f5..d4a06171 100644 --- a/utils/qv4l2/qv4l2.cpp +++ b/utils/qv4l2/qv4l2.cpp @@ -324,7 +324,11 @@ ApplicationWindow::ApplicationWindow() : #endif QMenu *helpMenu = menuBar()->addMenu("&Help"); +#if QT_VERSION < 0x060000 helpMenu->addAction("&About", this, SLOT(about()), Qt::Key_F1); +#else + helpMenu->addAction("&About", Qt::Key_F1, this, SLOT(about())); +#endif QAction *whatAct = QWhatsThis::createAction(this); helpMenu->addAction(whatAct);
Fixes: ../qv4l2/qv4l2.cpp:327:28: warning: ‘QAction* QMenu::addAction(const QString&, const QObject*, const char*, const QKeySequence&)’ is deprecated: Use addAction(text, shortcut, receiver, member) instead. [-Wdeprecated-declarations] 327 | helpMenu->addAction("&About", this, SLOT(about()), Qt::Key_F1); | ~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Signed-off-by: Peter Seiderer <ps.report@gmx.net> --- utils/qv4l2/qv4l2.cpp | 4 ++++ 1 file changed, 4 insertions(+)