I try to use Qts Signal/Slot mechanism with private implementation (PIMPL).
My header file is build like:
{
Q_OBJECT
public:
...
private:
class FooPrivate;
FooPrivate *d;
}
class Foo : public QWidget
{
Q_OBJECT
public:
...
private:
class FooPrivate;
FooPrivate *d;
}
To copy to clipboard, switch view to plain text mode
My source file is build like:
{
public:
...
public slots:
void doSomething();
signals:
void emitSomething();
}
Foo::FooPrivate : public QWidget
{
public:
...
public slots:
void doSomething();
signals:
void emitSomething();
}
To copy to clipboard, switch view to plain text mode
Due to this private implementation, the private signals and slots are declared inside the source file and not recognized by Q_OBJECT.
Is there an other way to use the signal/slot mechanism inside a local class?
Thanks
Kai
Bookmarks