08e4d2db08
Since any QWidget can have actions since at least Qt 5.0, it makes no sense to keep the addActions(text) etc. convenience functions that have traditionally existed in QMenu and QToolBar only in these two classes, where, to add insult to injury, they were just copies of each other, increasing library size for no real reason. So, add them to QWidget, too. This will allow us to de-duplicate the code between QMenu and QToolBar, too, which will be done in a follow-up patch, subject to BC constraints. [ChangeLog][QtWidgets][QWidget] Added the same addAction(text) overloads that previously existed only on QMenu and QToolBar, with the following two differences: First, the QKeySequence object, if any, is now available on all overloads, not just the ones taking a slot, but has changed position to allow, secondly, passing an optional Qt::ConnectionType parameter which will be passed to the QObject::connect() call. In addition, the function template overloads are now properly constrained so that they exist if and only if the corresponding QObject::connect() call does, too. Change-Id: Ifc3c2789600cf603192de8224fecbf9c88d91970 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io> Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io> |
||
---|---|---|
.github/workflows | ||
bin | ||
cmake | ||
coin | ||
config.tests | ||
dist | ||
doc | ||
examples | ||
lib | ||
libexec | ||
mkspecs | ||
qmake | ||
src | ||
tests | ||
util | ||
.cmake.conf | ||
.gitattributes | ||
.gitignore | ||
.lgtm.yml | ||
.qmake.conf | ||
.tag | ||
CMakeLists.txt | ||
conanfile.py | ||
config_help.txt | ||
configure | ||
configure.bat | ||
configure.cmake | ||
dependencies.yaml | ||
LICENSE.FDL | ||
LICENSE.GPL2 | ||
LICENSE.GPL3 | ||
LICENSE.GPL3-EXCEPT | ||
LICENSE.LGPL3 | ||
LICENSE.LGPLv3 | ||
LICENSE.QT-LICENSE-AGREEMENT | ||
qt_cmdline.cmake | ||
sync.profile |