1 |
torben |
501 |
#include <QApplication> |
2 |
|
|
#include <QtWebKit> |
3 |
|
|
|
4 |
|
|
class MyWebView : public QWebView |
5 |
|
|
{ |
6 |
|
|
public: |
7 |
|
|
MyWebView(QWidget* parent) : QWebView(parent) { |
8 |
|
|
this->setWindowState( Qt::WindowFullScreen ); |
9 |
|
|
} |
10 |
|
|
|
11 |
|
|
}; |
12 |
|
|
|
13 |
|
|
|
14 |
|
|
int main(int argc, char** argv) { |
15 |
|
|
QApplication app(argc,argv); |
16 |
|
|
|
17 |
|
|
|
18 |
|
|
QWebSettings* settings = QWebSettings::globalSettings(); |
19 |
|
|
settings->setAttribute( QWebSettings::JavascriptEnabled, true); |
20 |
|
|
settings->setAttribute( QWebSettings::PluginsEnabled, true); |
21 |
|
|
|
22 |
|
|
MyWebView web(0); |
23 |
|
|
web.load(QUrl("http://10.210.210.200/infoscreens/screen.php?screen_id=1&height=480&width=640")); |
24 |
|
|
web.show(); |
25 |
|
|
|
26 |
|
|
|
27 |
|
|
return app.exec(); |
28 |
|
|
} |