1 connect问题
使用信号槽机制时,需要满足以下几个条件
(1)继承 QObject
class xx: public QObject
(2)定义Q_OBJECT宏
class xx: public QObject{ Q_OBJECT }
(3)Undefined reference to vtable 错误
问题由于引入了Q_OBJECT宏,构建->执行qmake,重新运行qmake即可解决
来源:oschina
链接:https://my.oschina.net/u/3732258/blog/4393296