/[projects]/infoscreen/mainview.cpp
ViewVC logotype

Annotation of /infoscreen/mainview.cpp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 515 - (hide annotations) (download)
Tue Dec 15 20:36:26 2009 UTC (14 years, 5 months ago) by torben
Original Path: infoscreen/MainView.cpp
File size: 1193 byte(s)
code sync. start on client side render
1 torben 509 #include "MainView.h"
2 torben 512 #include <QApplication>
3 torben 510 #include <QPushButton>
4 torben 512 #include <QLabel>
5 torben 510 #include <QVBoxLayout>
6 torben 509
7 torben 510 #include <QTimer>
8    
9 torben 515 //#include <VideoPlayer> //Phonon
10     //#include <MediaSource> //Phonon
11 torben 511
12 torben 512 #include "MyWebView.h"
13 torben 515 #include "clientsiderender.h"
14 torben 511
15 torben 512
16 torben 509 MainView::MainView(QWidget* parent)
17     : QWidget(parent)
18     {
19 torben 512 this->setWindowState( Qt::WindowFullScreen );
20 torben 515 // qApp->setOverrideCursor( QCursor( Qt::BlankCursor) );
21 torben 510
22 torben 511
23 torben 512 //Phonon::VideoPlayer* video;
24     //video = new Phonon::VideoPlayer(Phonon::VideoCategory, this);
25     //video->load( Phonon::MediaSource("http://todic.dk/ps3cache/Inglourious_Basterds_2009.avi") );
26     //layout->addWidget(video,1);
27     //video->play();
28 torben 510
29 torben 515 render = new ClientSideRender(this);
30     web = new MyWebView(this);
31     web->setVisible( false );
32 torben 511
33 torben 510 QVBoxLayout* layout = new QVBoxLayout();
34 torben 515 layout->addWidget(web,1);
35     layout->addWidget(render,1);
36 torben 510 layout->addStretch();
37     layout->setContentsMargins(0,0,0,0);
38 torben 515 setLayout(layout);
39 torben 510
40     QTimer* timer = new QTimer(this);
41     connect(timer, SIGNAL(timeout() ), this, SLOT(onTimer() ));
42 torben 511 timer->start(1000);
43 torben 512
44    
45 torben 515 web->start();
46 torben 509 }
47    
48    
49     void MainView::onTimer()
50     {
51 torben 512 screenManager.timerTick();
52 torben 509 }

  ViewVC Help
Powered by ViewVC 1.1.20