
Originally Posted by
Al_
I prefer to use the more modern signal/slot connect() version as it is typesafe at run-time.
Even the old connects are typesafe at runtime. What you probably meant is typesafe/typechecked at compile time.

Originally Posted by
Al_
Examples:
- "connect(camera, &QCamera::error, this, &CaptureDialog::errorSlot);" does not compile because there are two QCamera::error functions: the signal "QCamera::error(QCamera::Error)" and the regular function "QCamera::error() const"
- "connect(camera, &QCamera::lockStatusChanged, this, &CaptureDialog::lockStatusChangedSlot);" does not compile because there are two signals QCamera::lockStatusChanged with different parameters
You need to provide disambiguation through casting
connect(camera, static_cast<void(QCamera::*)(QCamera::Error)>(&QCamera::error), this, &CaptureDialog::errorSlot);
connect(camera, static_cast<void(QCamera::*)(QCamera::Error)>(&QCamera::error), this, &CaptureDialog::errorSlot);
To copy to clipboard, switch view to plain text mode
Cheers,
_
Bookmarks