I have a C++ class defined with a method which has a member method as argument:
MyClass : public QDialog, private Ui::MyClassBase
{
Q_OBJECT
public:
MyClass( QWidget *parent = nullptr );
void connectValueChanged( QWidget* widget, void ( MyClass::*slot )() );
}
and
void MyClass::connectValueChanged( QWidget* widget, void ( MyClass::*slot )() )
{
connect( w, &QWidget::signal, this, slot );
}
The connectValueChanged cannot be used as defined in the SIP file, I get a syntax error. What shall I do to define a method with a member method as argument in SIP?
Aucun commentaire:
Enregistrer un commentaire