/[projects]/infoscreen/MainView.h
ViewVC logotype

Contents of /infoscreen/MainView.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 638 - (show annotations) (download)
Wed Apr 7 17:00:07 2010 UTC (14 years, 1 month ago) by torben
File MIME type: text/plain
File size: 1275 byte(s)
Adopt infoscreen to local play mode
1
2 #ifndef MAINVIEW_H
3 #define MAINVIEW_H
4
5 #include <QVector>
6 #include <QWidget>
7 #include "screenmanager.h"
8 #include "screenitem.h"
9 #include "screenxmlhandler.h"
10
11 class VideoView;
12 class MyWebView;
13 class ClientSideRender;
14 class PictureView;
15
16 class QSettings;
17
18 enum Mode {
19 ModeNone,
20 ModeSimpleWeb,
21 ModeXml,
22 ModeLocal
23 };
24
25 class MainView : public QWidget
26 {
27
28 Q_OBJECT
29 public:
30 MainView(QWidget* parent);
31
32 public slots:
33 void onTimer();
34
35 protected:
36 virtual void keyPressEvent ( QKeyEvent * event );
37 virtual void closeEvent ( QCloseEvent * event );
38 private:
39 void loadSettings();
40 bool readXml();
41 void readLocalFiles();
42 void switchScreens();
43 void hideAll();
44 void ensureVisible(QWidget* widget);
45 void errorInfoScreen(QString msg);
46
47 Mode currentMode;
48
49 MyWebView* web;
50 ClientSideRender* render;
51 PictureView* picture;
52 VideoView* video;
53 QWidget* current;
54 ScreenManager screenManager;
55
56 QTimer* timer ;
57 QTime lastXml;
58 QTime lastScreenSwitch;
59 ScreenItem currentItem;
60 int currentItemIdx;
61 QVector<ScreenItem> screenItems;
62
63 ScreenXmlHandler xmlHandler;
64
65 QSettings* settings;
66 QString url;
67 QString screenid;
68 QString xmlUrl;
69 QString path;
70 };
71
72 #endif //MAINVIEW_H

  ViewVC Help
Powered by ViewVC 1.1.20