谢谢dbzhang800的解说。
但小弟程度不好,只加了几行就出现:
undefined reference to `vtable for QSplashScreen2'及
collect2: ld returned 1 exit status之错误信息。
我不知该如何解决。有前辈可帮忙看看看吗?
以下程序码我加在int main(int argc, char *argv[])前面。
- class QSplashScreen2 : public QSplashScreen
- {
- Q_OBJECT
- public:
- QSplashScreen2(const QPixmap & pixmap = QPixmap(), Qt::WindowFlags f = 0);
- ~QSplashScreen2();
- };
- QSplashScreen2::QSplashScreen2(const QPixmap & pixmap, Qt::WindowFlags f)
- {
- }
- QSplashScreen2::~QSplashScreen2()
- {
- }