#14573 broke < Qt5.6 compatibility due to calling the lambda version of addAction
that was added in Qt5.6.
This PR re-enables < Qt5.6 compatibility.
#14573 broke < Qt5.6 compatibility due to calling the lambda version of addAction
that was added in Qt5.6.
This PR re-enables < Qt5.6 compatibility.
For reference a failed build is here, with log:
0bitcoingui.o `test -f 'qt/bitcoingui.cpp' || echo './'`qt/bitcoingui.cpp
1qt/bitcoingui.cpp:403:45: error: no matching member function for call to 'addAction'
2 QAction* minimize_action = window_menu->addAction(tr("Minimize"), [] {
3 ~~~~~~~~~~~~~^~~~~~~~~
4/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:78:14: note: candidate function not viable: no known conversion from '(lambda at qt/bitcoingui.cpp:403:71)' to 'const QObject *' for 2nd argument
5 QAction *addAction(const QString &text, const QObject *receiver, const char* member, const QKeySequence &shortcut = 0);
6 ^
7/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:77:14: note: candidate function not viable: requires 2 arguments, but 3 were provided
8 QAction *addAction(const QIcon &icon, const QString &text);
9 ^
10/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qwidget.h:538:10: note: candidate function not viable: requires single argument 'action', but 3 arguments were provided
11 void addAction(QAction *action);
12 ^
13/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:76:14: note: candidate function not viable: requires single argument 'text', but 3 arguments were provided
14 QAction *addAction(const QString &text);
15 ^
16/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:79:14: note: candidate function not viable: requires at least 4 arguments, but 3 were provided
17 QAction *addAction(const QIcon &icon, const QString &text, const QObject *receiver, const char* member, const QKeySequence &shortcut = 0);
18 ^
19qt/bitcoingui.cpp:425:44: error: no matching member function for call to 'addAction'
20 QAction* restore_action = window_menu->addAction(tr("Restore"), [] {
21 ~~~~~~~~~~~~~^~~~~~~~~
22/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:77:14: note: candidate function not viable: no known conversion from 'QString' to 'const QIcon' for 1st argument
23 QAction *addAction(const QIcon &icon, const QString &text);
24 ^
25/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qwidget.h:538:10: note: candidate function not viable: requires single argument 'action', but 2 arguments were provided
26 void addAction(QAction *action);
27 ^
28/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:76:14: note: candidate function not viable: requires single argument 'text', but 2 arguments were provided
29 QAction *addAction(const QString &text);
30 ^
31/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:78:14: note: candidate function not viable: requires at least 3 arguments, but 2 were provided
32 QAction *addAction(const QString &text, const QObject *receiver, const char* member, const QKeySequence &shortcut = 0);
33 ^
34/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:79:14: note: candidate function not viable: requires at least 4 arguments, but 2 were provided
35 QAction *addAction(const QIcon &icon, const QString &text, const QObject *receiver, const char* member, const QKeySequence &shortcut = 0);
36 ^
37qt/bitcoingui.cpp:436:22: error: no matching member function for call to 'addAction'
38 window_menu->addAction(tr("Main Window"), [this] {
39 ~~~~~~~~~~~~~^~~~~~~~~
40/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:77:14: note: candidate function not viable: no known conversion from 'QString' to 'const QIcon' for 1st argument
41 QAction *addAction(const QIcon &icon, const QString &text);
42 ^
43/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qwidget.h:538:10: note: candidate function not viable: requires single argument 'action', but 2 arguments were provided
44 void addAction(QAction *action);
45 ^
46/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:76:14: note: candidate function not viable: requires single argument 'text', but 2 arguments were provided
47 QAction *addAction(const QString &text);
48 ^
49/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:78:14: note: candidate function not viable: requires at least 3 arguments, but 2 were provided
50 QAction *addAction(const QString &text, const QObject *receiver, const char* member, const QKeySequence &shortcut = 0);
51 ^
52/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:79:14: note: candidate function not viable: requires at least 4 arguments, but 2 were provided
53 QAction *addAction(const QIcon &icon, const QString &text, const QObject *receiver, const char* member, const QKeySequence &shortcut = 0);
54 ^
55qt/bitcoingui.cpp:447:22: error: no matching member function for call to 'addAction'
56 window_menu->addAction(rpcConsole->tabTitle(tab_type), [this, tab_type] {
57 ~~~~~~~~~~~~~^~~~~~~~~
58/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:77:14: note: candidate function not viable: no known conversion from 'QString' to 'const QIcon' for 1st argument
59 QAction *addAction(const QIcon &icon, const QString &text);
60 ^
61/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qwidget.h:538:10: note: candidate function not viable: requires single argument 'action', but 2 arguments were provided
62 void addAction(QAction *action);
63 ^
64/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:76:14: note: candidate function not viable: requires single argument 'text', but 2 arguments were provided
65 QAction *addAction(const QString &text);
66 ^
67/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:78:14: note: candidate function not viable: requires at least 3 arguments, but 2 were provided
68 QAction *addAction(const QString &text, const QObject *receiver, const char* member, const QKeySequence &shortcut = 0);
69 ^
70/usr/include/x86_64-linux-gnu/qt5/QtWidgets/qmenu.h:79:14: note: candidate function not viable: requires at least 4 arguments, but 2 were provided
71 QAction *addAction(const QIcon &icon, const QString &text, const QObject *receiver, const char* member, const QKeySequence &shortcut = 0);
72 ^
734 errors generated.
74make[2]: *** [qt/qt_libbitcoinqt_a-bitcoingui.o] Error 1
jonasschnelli
fanquake
promag
laanwj
Labels
GUI