2013-02-24 141 views
5

简单代码:QT5迁移无法打开包含文件:'QGraphicsWebView'?

#include <QCoreApplication> 
#include <QGraphicsWebView> 

int main(int argc, char *argv[]) 
{ 
    QCoreApplication a(argc, argv); 

    return a.exec(); 
} 

样品的.pro:

QT  += core gui declarative network webkit multimedia 

TARGET = QTTest 
CONFIG += console 
CONFIG -= app_bundle 

TEMPLATE = app 


SOURCES += main.cpp 

和错误,我得到:

C1083: Cannot open include file: 'QGraphicsWebView': No such file or directory 

What the is going on there in QT5? this class shall Be included like this and so I shall see no such error? I do not get some fancy QT5 new feature?

回答

2

在行

QT  += core gui declarative network webkit multimedia 

通过webkitwidgets更换webkit

QT  += core gui declarative network webkitwidgets multimedia 
相关问题