]> git.vomp.tv Git - vompclient.git/blob - vepglistadvanced.h
Fixes for Windows
[vompclient.git] / vepglistadvanced.h
1 /*
2     Copyright 2004-2020 Chris Tallon, 2014 Marten Richter
3
4     This file is part of VOMP.
5
6     VOMP is free software; you can redistribute it and/or modify
7     it under the terms of the GNU General Public License as published by
8     the Free Software Foundation; either version 2 of the License, or
9     (at your option) any later version.
10
11     VOMP is distributed in the hope that it will be useful,
12     but WITHOUT ANY WARRANTY; without even the implied warranty of
13     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14     GNU General Public License for more details.
15
16     You should have received a copy of the GNU General Public License
17     along with VOMP.  If not, see <https://www.gnu.org/licenses/>.
18 */
19
20 #ifndef VEPGLIST_ADVANCED_H
21 #define VEPGLIST_ADVANCED_H
22
23 #include <stack>
24
25 #include "tbboxx.h"
26 #include "wtextbox.h"
27 #include "wselectlist.h"
28 #include "wtvmedia.h"
29
30 class BoxStack;
31 class VVideoLiveTV;
32
33 class VEpgListAdvanced : public TBBoxx
34 {
35   public:
36     VEpgListAdvanced(VVideoLiveTV* tvideolive, ChannelList* tchanList, ULONG initialChannelNumber);
37     virtual ~VEpgListAdvanced();
38
39     void draw() { draw(false); }
40     void draw(bool);
41     bool load();
42     void drawData(bool doIndexPop = false);
43
44   protected:
45
46     enum EpgMode
47     {
48       OneChannel,
49       Now,
50       Next
51     };
52
53     enum EpgMode mode;
54
55     void quickUpdate();
56     void updateSelection();
57
58     void setButtonText();
59
60     void clearEventList();
61
62     void updateEpgData();
63     void updateEpgDataChannel();
64     void updateEpgDataNowNext(bool changestate);
65     void drawDataChannel(bool doIndexPop);
66     void drawDataNowNext(bool next, bool doIndexPop);
67
68     int handleCommand(int command);
69     void processMessage(Message* m);
70
71     void doRed();
72     void doGreen();
73     void doYellow();
74     void doBlue();
75
76     void doNext();
77     void doNow();
78     void doProgramm();
79     void doSwitch();
80     void doRecord();
81     void doGrid();
82
83     WTextbox epg;
84     WTVMedia epgTVmedia;
85
86     BoxStack* boxstack;
87     bool loading;
88
89     WSelectList sl;
90
91     Event* getCurrentOptionEvent(ULONG& channel);
92
93     ChannelList* chanList;
94     ULONG channelNumber;
95     VVideoLiveTV* videolive;
96
97     Boxx boxRed;
98     Boxx boxGreen;
99     Boxx boxYellow;
100     Boxx boxBlue;
101
102     WTextbox textRed;
103     WTextbox textGreen;
104     WTextbox textYellow;
105     WTextbox textBlue;
106
107     std::vector<EventList*> eventLista;
108 };
109
110 #endif